diff options
author | irungentoo <irungentoo@gmail.com> | 2015-02-03 13:15:36 -0500 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2015-02-03 13:15:36 -0500 |
commit | e5644bbd58539982c6484e6f155410838ad1a8e9 (patch) | |
tree | 5462c1d5cb3e98ae4aa920d8c14fdfabf707e26d /other/osx_build_script_toxcore.sh | |
parent | 16c0736968886369bfbcd0e01cc86d1a279001cc (diff) | |
parent | 47cac28df4065c52fb54a732759d551d79e45af7 (diff) |
Merge branch 'urras-master'
Diffstat (limited to 'other/osx_build_script_toxcore.sh')
-rw-r--r-- | other/osx_build_script_toxcore.sh | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/other/osx_build_script_toxcore.sh b/other/osx_build_script_toxcore.sh new file mode 100644 index 00000000..8aea0d1c --- /dev/null +++ b/other/osx_build_script_toxcore.sh | |||
@@ -0,0 +1,38 @@ | |||
1 | #!/usr/bin/env bash | ||
2 | # written by Lubo Diakov | ||
3 | # hard coded toxcore directory, replace with other path or variable as needed | ||
4 | cd ~/Downloads/toxcore | ||
5 | echo "Now working in:"`pwd` | ||
6 | |||
7 | # must have working git binary, and have done git clone at least once before | ||
8 | git pull | ||
9 | echo "If git pull responds: Already up-to-date. you can cancel the build" | ||
10 | echo "by typing anything except y or Y below" | ||
11 | read -p "Continue with build? (enter y to continue): " Last_Chance | ||
12 | |||
13 | # blah blah | ||
14 | if [[ $Last_Chance = [Yy] ]]; then echo "Continuing!"; | ||
15 | else echo "Aborted!"; exit | ||
16 | fi | ||
17 | sleep 3 | ||
18 | |||
19 | # if libsodium is built with macports, link it from /opt/local/ to /usr/local | ||
20 | if [ ! -L "/usr/local/lib/libsodium.dylib" ]; then | ||
21 | # Control will enter here if $DIRECTORY doesn't exist. | ||
22 | ln -s /opt/local/lib/libsodium.dylib /usr/local/lib/libsodium.dylib | ||
23 | fi | ||
24 | echo "The symlink /usr/local/lib/libsodium.dylib exists." | ||
25 | sleep 3 | ||
26 | |||
27 | # replace ppc, i386 as needed. | ||
28 | ./configure CC="gcc -arch ppc -arch i386" CXX="g++ -arch ppc -arch i386" CPP="gcc -E" CXXCPP="g++ -E" | ||
29 | |||
30 | # get rid of prior builds, start clean | ||
31 | make clean | ||
32 | make | ||
33 | echo "" | ||
34 | echo "Sudo is required for make install only, all other steps run without it." | ||
35 | echo "Please type your sudo password below for make install:" | ||
36 | sudo make install | ||
37 | |||
38 | exit | ||