diff --git a/.evergreen/generated_configs/legacy-config.yml b/.evergreen/generated_configs/legacy-config.yml index c20f583a76..671f24d245 100644 --- a/.evergreen/generated_configs/legacy-config.yml +++ b/.evergreen/generated_configs/legacy-config.yml @@ -246,7 +246,7 @@ tasks: shell: bash script: |- set -o errexit - env CFLAGS="-fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-all -fPIE -O" LDFLAGS="-pie -Wl,-z,relro -Wl,-z,now" SNAPPY="OFF" ZLIB="OFF" ZSTD="OFF" .evergreen/scripts/compile.sh + env CFLAGS="-fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-all -O" EXTRA_CONFIGURE_FLAGS="CMAKE_POSITION_INDEPENDENT_CODE=ON" LDFLAGS="-Wl,-z,relro -Wl,-z,now" SNAPPY="OFF" ZLIB="OFF" ZSTD="OFF" .evergreen/scripts/compile.sh - func: upload-build - name: debug-compile-compression-zlib tags: diff --git a/.evergreen/legacy_config_generator/evergreen_config_lib/tasks.py b/.evergreen/legacy_config_generator/evergreen_config_lib/tasks.py index 2a25d88b5c..8a1da6aaa5 100644 --- a/.evergreen/legacy_config_generator/evergreen_config_lib/tasks.py +++ b/.evergreen/legacy_config_generator/evergreen_config_lib/tasks.py @@ -182,8 +182,9 @@ def __init__( 'hardened-compile', tags=['hardened'], compression=None, - CFLAGS='-fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-all -fPIE -O', - LDFLAGS='-pie -Wl,-z,relro -Wl,-z,now', + CFLAGS='-fno-strict-overflow -D_FORTIFY_SOURCE=2 -fstack-protector-all -O', + LDFLAGS='-Wl,-z,relro -Wl,-z,now', + EXTRA_CONFIGURE_FLAGS='CMAKE_POSITION_INDEPENDENT_CODE=ON', ), CompileTask('debug-compile-compression-zlib', tags=['zlib', 'compression'], compression='zlib'), CompileTask('debug-compile-compression-snappy', tags=['snappy', 'compression'], compression='snappy'),