summaryrefslogtreecommitdiff
path: root/other
diff options
context:
space:
mode:
Diffstat (limited to 'other')
-rw-r--r--other/osx_build_script_toxcore.sh38
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
4cd ~/Downloads/toxcore
5echo "Now working in:"`pwd`
6
7# must have working git binary, and have done git clone at least once before
8git pull
9echo "If git pull responds: Already up-to-date. you can cancel the build"
10echo "by typing anything except y or Y below"
11read -p "Continue with build? (enter y to continue): " Last_Chance
12
13# blah blah
14if [[ $Last_Chance = [Yy] ]]; then echo "Continuing!";
15else echo "Aborted!"; exit
16fi
17sleep 3
18
19# if libsodium is built with macports, link it from /opt/local/ to /usr/local
20if [ ! -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
23fi
24echo "The symlink /usr/local/lib/libsodium.dylib exists."
25sleep 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
31make clean
32make
33echo ""
34echo "Sudo is required for make install only, all other steps run without it."
35echo "Please type your sudo password below for make install:"
36sudo make install
37
38exit