Browse code

Changes for mulle-build

Nat! authored on 13/06/2017 10:52:06
Showing 2 changed files
... ...
@@ -4,16 +4,26 @@ set -e
4 4
 
5 5
 TESTDIR="`pwd -P`"
6 6
 
7
-mulle-bootstrap build -c Debug -k "$@"
7
+mulle-bootstrap build -c Debug -k
8 8
 
9
-if [ -d ../build ]
9
+cd ..
10
+
11
+
12
+if [ -f .CC ]
13
+then
14
+   OPTIONS="-DCMAKE_C_COMPILER=`cat .CC` -DCMAKE_CXX_COMPILER=`cat .CXX`"
15
+fi
16
+
17
+if [ -d build ]
10 18
 then
11
-   rm -rf ../build
19
+   rm -rf build
12 20
 fi
21
+mkdir build
22
+
13 23
 
14
-mkdir ../build
15
-cd ../build
16
-   cmake -DCMAKE_OSX_SYSROOT=macosx \
17
-         -DCMAKE_INSTALL_PREFIX="${TESTDIR}" \
18
-         -DCMAKE_BUILD_TYPE=Debug ..
19
-   make -j 4 install
24
+cd build
25
+   eval cmake -DCMAKE_OSX_SYSROOT=macosx \
26
+              -DCMAKE_INSTALL_PREFIX="'${TESTDIR}'" \
27
+              ${OPTIONS} \
28
+              -DCMAKE_BUILD_TYPE=Debug ..
29
+   make -j 4 "$@" install
... ...
@@ -360,7 +360,7 @@ main()
360 360
    #
361 361
    # find executable
362 362
    #
363
-   exe=`ls -1 ../bin/mulle-scion 2> /dev/null | tail -1`
363
+   exe=`ls -1 ./bin/mulle-scion 2> /dev/null | tail -1`
364 364
    if [ ! -x "${exe}" ]
365 365
    then
366 366
       exe=`ls -1 ../?uild/Products/*/mulle-scion 2> /dev/null | tail -1`
... ...
@@ -397,11 +397,13 @@ main()
397 397
          Darwin)
398 398
             DYLD_FALLBACK_FRAMEWORK_PATH="${DEPENDENCIES}/Frameworks"
399 399
             export DYLD_FALLBACK_FRAMEWORK_PATH
400
+            echo "DYLD_FALLBACK_FRAMEWORK_PATH='${DEPENDENCIES}/Frameworks'" >&2
400 401
             ;;
401 402
 
402 403
          *)
403 404
             LD_LIBRARY_PATH="${DEPENDENCIES}/lib:${LD_LIBRARY_PATH}"
404 405
             export LD_LIBRARY_PATH
406
+            echo "LD_LIBRARY_PATH='${DEPENDENCIES}/lib:${LD_LIBRARY_PATH}'" >&2
405 407
             ;;
406 408
       esac
407 409
    fi