]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
Remove sanitizer support from configure since it is better supported in cmake. Anybod...
authorNathan Moinvaziri <nathan@nathanm.com>
Sat, 2 Apr 2022 21:49:28 +0000 (14:49 -0700)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Tue, 5 Apr 2022 11:43:48 +0000 (13:43 +0200)
.github/workflows/configure.yml
README.md
configure

index ce367493ee7d53c6e867929742a09f9f534f2926..25d9b875c6bee4fdfa0433e4f0eec04c5f201483 100644 (file)
@@ -30,21 +30,6 @@ jobs:
             compiler: gcc
             configure-args: --warn --zlib-compat --without-optimizations --without-new-strategies
 
-          - name: Ubuntu GCC ASAN
-            os: ubuntu-latest
-            compiler: gcc
-            configure-args: --warn --with-sanitizer=address
-
-          - name: Ubuntu GCC MSAN
-            os: ubuntu-latest
-            compiler: gcc
-            configure-args: --warn --with-sanitizer=memory
-
-          - name: Ubuntu GCC No Unaligned UBSAN
-            os: ubuntu-latest
-            compiler: gcc
-            configure-args: --warn --without-unaligned --with-sanitizer=undefined
-
           - name: Ubuntu GCC ARM SF
             os: ubuntu-latest
             compiler: arm-linux-gnueabi-gcc
index 5df00579f39b9cb8f4f04e1168b7353a7eac958f..e02e04b3161fbb58b92cae8116a5b5f70f94e865 100644 (file)
--- a/README.md
+++ b/README.md
@@ -119,7 +119,7 @@ Build Options
 | WITH_OPTIM               | --without-optimizations  | Build with optimisations                                                              | ON      |
 | WITH_NEW_STRATEGIES      | --without-new-strategies | Use new strategies                                                                    | ON      |
 | WITH_NATIVE_INSTRUCTIONS | --native                 | Compiles with full instruction set supported on this host (gcc/clang -march=native)   | OFF     |
-| WITH_SANITIZER           | --with-sanitizer         | Build with sanitizer (memory, address, undefined)                                     | OFF     |
+| WITH_SANITIZER           |                          | Build with sanitizer (memory, address, undefined)                                     | OFF     |
 | WITH_FUZZERS             |                          | Build test/fuzz                                                                       | OFF     |
 | WITH_BENCHMARKS          |                          | Build test/benchmarks                                                                 | OFF     |
 | WITH_MAINTAINER_WARNINGS |                          | Build with project maintainer warnings                                                | OFF     |
index bf64ae35d135198d171ea647055a6ef6f17062a3..aed1909ccb7461e787e0c7adfac4150f37e290ff 100755 (executable)
--- a/configure
+++ b/configure
@@ -99,7 +99,6 @@ buildneon=1
 builddfltccdeflate=0
 builddfltccinflate=0
 buildcrc32vx=1
-with_sanitizer=""
 floatabi=
 native=0
 forcesse2=0
@@ -176,7 +175,6 @@ case "$1" in
       echo '    [--with-reduced-mem]        Reduced memory usage for special cases (reduces performance)' | tee -a configure.log
       echo '    [--force-sse2]              Assume SSE2 instructions are always available (disabled by default on x86, enabled on x86_64)' | tee -a configure.log
       echo '    [--force-tzcnt]             Assume TZCNT instructions are always available (disabled by default)' | tee -a configure.log
-      echo '    [--with-sanitizer]          Build with sanitizer (memory, address, undefined)' | tee -a configure.log
       echo '    [--native]                  Compiles with full instruction set supported on this host' | tee -a configure.log
         exit 0 ;;
     -p*=* | --prefix=*) prefix=$(echo $1 | sed 's/.*=//'); shift ;;
@@ -218,7 +216,6 @@ case "$1" in
     -oldstrat | --without-new-strategies) without_new_strategies=1; shift;;
     -w* | --warn) warn=1; shift ;;
     -d* | --debug) debug=1; shift ;;
-    --with-sanitizer=*) with_sanitizer=$(echo $1 | sed 's/.*=//'); shift ;;
 
     *)
       echo "unknown option: $1" | tee -a configure.log
@@ -622,80 +619,6 @@ fi
 
 echo >> configure.log
 
-if test "$with_sanitizer" = "address"; then
-    echo -n "Checking for address sanitizer... " | tee -a configure.log
-    sanitizers=""
-    for san in address pointer-compare pointer-subtract; do
-        if try $CC -c $CFLAGS $test.c -fsanitize=$san ; then
-            if test -n "$sanitizers"; then
-                sanitizers="$sanitizers,$san"
-            else
-                sanitizers="$san"
-            fi
-        fi
-    done
-
-    if test -n "$sanitizers"; then
-        echo "-fsanitize=$sanitizers" | tee -a configure.log
-        CFLAGS="$CFLAGS -fsanitize=$sanitizers"
-        SFLAGS="$SFLAGS -fsanitize=$sanitizers"
-        LDFLAGS="$LDFLAGS -fsanitize=$sanitizers"
-    else
-        echo No | tee -a configure.log
-    fi
-
-    echo -n "Checking for leak sanitizer... " | tee -a configure.log
-    if try $CC -c $CFLAGS $test.c -fsanitize=leak; then
-        echo "-fsanitize=leak" | tee -a configure.log
-        CFLAGS="$CFLAGS -fsanitize=leak"
-        SFLAGS="$SFLAGS -fsanitize=leak"
-        LDFLAGS="$LDFLAGS -fsanitize=leak"
-    else
-        echo No | tee -a configure.log
-    fi
-
-    echo >> configure.log
-fi
-
-if test "$with_sanitizer" = "memory"; then
-    echo -n "Checking for memory sanitizer... " | tee -a configure.log
-    if try $CC -c $CFLAGS $test.c -fsanitize=memory ; then
-        echo "-fsanitize=memory" | tee -a configure.log
-        CFLAGS="$CFLAGS -fsanitize=memory"
-        SFLAGS="$SFLAGS -fsanitize=memory"
-        LDFLAGS="$LDFLAGS -fsanitize=memory"
-    else
-        echo No | tee -a configure.log
-    fi
-
-    echo >> configure.log
-fi
-
-if test "$with_sanitizer" = "undefined"; then
-    echo -n "Checking for undefined behavior sanitizer... " | tee -a configure.log
-    sanitizers=""
-    for san in array-bounds bool bounds builtin enum float-cast-overflow float-divide-by-zero function integer-divide-by-zero local-bounds null nonnull-attribute object-size pointer-overflow return returns-nonnull-attribute shift shift-base shift-exponent signed-integer-overflow undefined unsigned-integer-overflow unsigned-shift-base vla-bound vptr; do
-        if try $CC -c $CFLAGS $test.c -fsanitize=$san; then
-            if test -n "$sanitizers"; then
-                sanitizers="$sanitizers,$san"
-            else
-                sanitizers="$san"
-            fi
-        fi
-    done
-
-    if test -n "$sanitizers"; then
-        echo "-fsanitize=$sanitizers" | tee -a configure.log
-        CFLAGS="$CFLAGS -fsanitize=$sanitizers"
-        SFLAGS="$SFLAGS -fsanitize=$sanitizers"
-        LDFLAGS="$LDFLAGS -fsanitize=$sanitizers"
-    else
-        echo No | tee -a configure.log
-    fi
-
-    echo >> configure.log
-fi
-
 # see if shared library build supported
 cat > $test.c <<EOF
 extern int getchar();