summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Stransky <stransky@redhat.com>2019-12-06 17:01:36 +0100
committerMartin Stransky <stransky@redhat.com>2019-12-06 17:01:36 +0100
commita45c5315565ee7953cd1fd424938fa69c1a12702 (patch)
treed6e75ce525f0db18212cd0cdf889598867575bbb
parentfixed test builds (diff)
downloadlibrewolf-fedora-ff-a45c5315565ee7953cd1fd424938fa69c1a12702.tar.gz
librewolf-fedora-ff-a45c5315565ee7953cd1fd424938fa69c1a12702.tar.bz2
librewolf-fedora-ff-a45c5315565ee7953cd1fd424938fa69c1a12702.zip
Updated ASAN setup
-rw-r--r--firefox.spec13
1 files changed, 10 insertions, 3 deletions
diff --git a/firefox.spec b/firefox.spec
index 0c92a7e..55f7cbf 100644
--- a/firefox.spec
+++ b/firefox.spec
@@ -1,7 +1,7 @@
# Set to true if it's going to be submitted as update.
%global release_build 0
%global debug_build 0
-%global build_with_clang 1
+%global build_with_clang 0
%global build_with_asan 0
# Disabled arm due to rhbz#1658940
@@ -449,6 +449,13 @@ echo "ac_add_options --without-system-libvpx" >> .mozconfig
echo "ac_add_options --disable-ion" >> .mozconfig
%endif
+%if %{build_with_asan}
+echo "ac_add_options --enable-address-sanitizer" >> .mozconfig
+echo "ac_add_options --disable-jemalloc" >> .mozconfig
+echo "ac_add_options --disable-crashreporter" >> .mozconfig
+echo "ac_add_options --disable-elf-hack" >> .mozconfig
+%endif
+
echo 'export NODEJS="%{_buildrootdir}/bin/node-stdout-nonblocking-wrapper"' >> .mozconfig
# Remove executable bit to make brp-mangle-shebangs happy.
@@ -539,8 +546,8 @@ MOZ_LINK_FLAGS="$MOZ_LINK_FLAGS -L%{_libdir}"
export RUSTFLAGS="-Cdebuginfo=0"
%endif
%if %{build_with_asan}
-MOZ_OPT_FLAGS="$MOZ_OPT_FLAGS -fsanitize=address"
-MOZ_LINK_FLAGS="$MOZ_LINK_FLAGS -lasan"
+MOZ_OPT_FLAGS="$MOZ_OPT_FLAGS -fsanitize=address -Dxmalloc=myxmalloc"
+MOZ_LINK_FLAGS="$MOZ_LINK_FLAGS -fsanitize=address"
%endif
%if !%{build_with_clang}
bgstack15