]> Zhao Yanbai Git Server - minix.git/commitdiff
Support BUILDVARS from cmd line in configure.llvm 37/3137/1
authorLionel Sambuc <lionel@minix3.org>
Wed, 28 Jan 2015 14:04:27 +0000 (15:04 +0100)
committerDavid van Moolenbroek <david@minix3.org>
Thu, 17 Sep 2015 13:53:18 +0000 (13:53 +0000)
Change-Id: I59527c60cb34c12fd2bed449b37bb812a83c4e42

minix/llvm/configure.llvm
share/mk/sys.mk

index 5397a5c933860ab5b37e5d6b48659ef95a0f3c6c..8e0bf07fb1234d043065ec64fcaf887662b6abe1 100755 (executable)
@@ -105,15 +105,18 @@ fi
 ########################
 # Build Minix
 ########################
+export BUILDVARS=$(echo "${BUILDVARS} -V MKBITCODE=yes"| sed -e 's,-V MKMAGIC=yes,-V DBG=-g -V STRIPFLAG=-s -V CPPFLAGS=-D_MINIX_MAGIC=1,')
+
 if [ "${REBUILD_MINIX}" == "yes" ]; then
 
        echo "Building Minix..."
        echo "CC:$CC"
        echo "CXX:$CXX"
        echo "JOBS:$JOBS"
+       echo "BUILDVARS:$BUILDVARS"
        echo 
        cd ${MINIX_ROOT}
-       BUILDVARS="-V MKBITCODE=yes" ./releasetools/x86_hdimage.sh || EXITCODE=1
+       ./releasetools/x86_hdimage.sh || EXITCODE=1
        cd ${MYPWD}
        if [ "$EXITCODE" != "0" ]; then
                echo "Error: Failed building Minix source code."
index ae407b1bbbb0bbd038807891f826c4df6cc7c192..c06bebb5efaf628cd81da434e095fbbae0f2444e 100644 (file)
@@ -61,7 +61,11 @@ DBG?=        -O1 -fgcse -fstrength-reduce -fgcse-after-reload
 .else
 DBG?=  -O2
 .endif
+.if !defined(__MINIX)
 CFLAGS?=       ${DBG}
+.else
+CFLAGS+=       ${DBG}
+.endif # !defined(__MINIX)
 LDFLAGS?=
 COMPILE.c?=    ${CC} ${CFLAGS} ${CPPFLAGS} -c
 LINK.c?=       ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}