Added sys/asan.sh and honor LDFLAGS in sys/build.sh

This commit is contained in:
pancake 2014-11-04 10:58:40 +01:00
parent 1eccc191e0
commit 07f8439020
2 changed files with 5 additions and 1 deletions

4
sys/asan.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/sh
export CFLAGS="-fsanitize=address -lasan"
export LDFLAGS="-lasan"
sys/install.sh

View File

@ -38,7 +38,7 @@ ${MAKE} mrproper > /dev/null 2>&1
if [ -d shlr/capstone/.git ]; then
( cd shlr/capstone ; git clean -xdf )
fi
[ "`uname`" = Linux ] && export LDFLAGS="-Wl,--as-needed"
[ "`uname`" = Linux ] && export LDFLAGS="-Wl,--as-needed ${LDFLAGS}"
rm -f plugins.cfg
./configure ${CFGARG} --prefix=${PREFIX} || exit 1
exec ${MAKE} -s -j${MAKE_JOBS} MAKE_JOBS=${MAKE_JOBS}