diff --git a/srcpkgs/firefox/template b/srcpkgs/firefox/template index 76578da1804..674550b06db 100644 --- a/srcpkgs/firefox/template +++ b/srcpkgs/firefox/template @@ -1,7 +1,7 @@ # Template build file for 'firefox'. pkgname=firefox version=48.0.2 -revision=2 +revision=3 short_desc="Lightweight gecko-based web browser" maintainer="Juan RP " homepage="https://www.mozilla.org/firefox/" @@ -34,6 +34,15 @@ case "$XBPS_TARGET_MACHINE" in x86_64*) build_options_default+=" rust" ;; esac +_gccver=$(gcc --version | awk '/^gcc \(GCC\)/ { print $3 }') +if [ "${_gccver%%.*}" -gt 5 ]; then + # Append CFLAGS and CXXFLAGS to set work around code which gcc6 would + # otherwise regard as out-of-specification and allow it to produce a + # working program. + CFLAGS+=" -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2" + CXXFLAGS+=" -fno-delete-null-pointer-checks -fno-lifetime-dse -fno-schedule-insns2" +fi + post_extract() { [ ! -d "${wrkdrc}/xbps-build" ] && mkdir -p "${wrksrc}/xbps-build" }