From 799a428671bfac627fa8866dee2144bec07c206c Mon Sep 17 00:00:00 2001 From: Adam Harrison Date: Mon, 16 Jan 2023 22:22:07 -0500 Subject: Putting CFLAGS in the right order. --- build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.sh b/build.sh index d8e4b3c..80fbf88 100755 --- a/build.sh +++ b/build.sh @@ -18,7 +18,7 @@ CMAKE_DEFAULT_FLAGS=" $CMAKE_DEFAULT_FLAGS -DCMAKE_BUILD_TYPE=Release -DCMAKE_PR mkdir -p lib/prefix/include lib/prefix/lib if [[ "$@" != *"-lz"* ]]; then [ ! -e "lib/zlib" ] && echo "Make sure you've cloned submodules. (git submodule update --init --depth=1)" && exit -1 - [[ ! -e "lib/zlib/build" && $OSTYPE != 'msys'* ]] && cd lib/zlib && mkdir build && cd build && CFLAGS="$CFLAGS" $CC -O3 -D_LARGEFILE64_SOURCE -I.. ../*.c -c && $AR rc libz.a *.o && cp libz.a ../../prefix/lib && cp ../*.h ../../prefix/include && cd ../../../ + [[ ! -e "lib/zlib/build" && $OSTYPE != 'msys'* ]] && cd lib/zlib && mkdir build && cd build && $CC $CFLAGS -O3 -D_LARGEFILE64_SOURCE -I.. ../*.c -c && $AR rc libz.a *.o && cp libz.a ../../prefix/lib && cp ../*.h ../../prefix/include && cd ../../../ LDFLAGS="$LDFLAGS -lz" fi if [[ "$@" != *"-lmbedtls"* && "$@" != *"-lmbedcrypto"* ]]; then -- cgit v1.2.3