aboutsummaryrefslogtreecommitdiff
blob: c3b5c89eeac298694e014665dded3cd02e26d7e6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
--- a/src/c
+++ b/src/c
@@ -156,8 +156,8 @@
 #
 case "$($CCNAME --version)" in
 *gcc*|*GCC*)
-    [ -z "$BOOM_MODEL_NOOPT" ] && CCDEBUG="-O2"
-    [ -z "$BOOM_MODEL_NOOPT" ] && CCNODEBUG="$CCNODEBUG -O2"
+    [ -z "$BOOM_MODEL_NOOPT" ] && CCDEBUG="${CFLAGS}"
+    [ -z "$BOOM_MODEL_NOOPT" ] && CCNODEBUG="$CCNODEBUG ${CFLAGS}"
     CCOPTS="-D_REENTRANT -D_GNU_SOURCE -Wall -Wno-unused -fno-strict-aliasing"
     #  We assume the following standard libraries are all present.
     #  If your build is failing because of missing libraries then
@@ -334,9 +334,9 @@
                 AR_CREATE_OPT="c"
             fi
             if [ "$RANLIB" = "1" ]; then
-                COMMAND="ar ${AR_CREATE_OPT}r $LIBNAME.a $OBJECT"
+                COMMAND="${AR} ${AR_CREATE_OPT}r $LIBNAME.a $OBJECT"
             else
-                COMMAND="ar ${AR_CREATE_OPT}rs $LIBNAME.a $OBJECT"
+                COMMAND="${AR} ${AR_CREATE_OPT}rs $LIBNAME.a $OBJECT"
             fi
             if [ "$QUIET" = "no" ]; then
                 if [ "$VERBOSE" = "no" ]; then