summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorAnthony Ruhier2020-07-29 12:57:44 +0000
committerAnthony Ruhier2020-07-29 12:57:44 +0000
commitea4809c67eb94920b6bf15f1e119ed41bcc23592 (patch)
tree49355839c3520d28065744b600019276ec682bfe /PKGBUILD
parenteeff876c12a86127e48ea5b54bd1c76e38125ff7 (diff)
downloadaur-ea4809c67eb94920b6bf15f1e119ed41bcc23592.tar.gz
Use LDD to allow building with rust 1.45 and LTO
See https://bugzilla.mozilla.org/show_bug.cgi?id=1654465 and https://github.com/rust-lang/rust/issues/74657 for details.
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD25
1 files changed, 14 insertions, 11 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 5bd201fdf827..b0ec8e0718c8 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -58,9 +58,9 @@ arch=(i686 x86_64)
license=(MPL GPL LGPL)
url="https://www.mozilla.org/en-US/firefox/channel/#beta"
depends=(gtk3 libxt mime-types dbus-glib ffmpeg 'nss>=3.55' ttf-font libpulse)
-makedepends=(unzip zip diffutils python2-setuptools yasm mesa imake inetutils
- xorg-server-xvfb autoconf2.13 rust clang llvm jack gtk2
- python nodejs python2-psutil cbindgen nasm xorgproto)
+makedepends=(unzip zip diffutils yasm mesa imake inetutils xorg-server-xvfb
+ autoconf2.13 rust clang llvm jack gtk2 nodejs cbindgen nasm
+ python-setuptools python-psutil lld)
optdepends=('networkmanager: Location detection via available WiFi networks'
'libnotify: Notification integration'
'pulseaudio: Audio support'
@@ -71,10 +71,12 @@ conflicts=('firefox-beta-bin')
options=(!emptydirs !makeflags !strip)
source=(https://archive.mozilla.org/pub/firefox/releases/$pkgver/source/$_pkgname-$pkgver.source.tar.xz{,.asc}
0001-Use-remoting-name-for-GDK-application-names.patch
+ bug1654465.diff
$pkgname.desktop)
sha256sums=('284daebc9876878de648f0e10632db585cb3b2344b59ea3d0952589d96aee970'
'SKIP'
'3bb7463471fb43b2163a705a79a13a3003d70fff4bbe44f467807ca056de9a75'
+ 'e577f7e5636deda0026b0e385186f3ecb2212c9b84b6a2949a1811dab3e410d6'
'54d93249fedc9c4cdc5eb82da498b08f08bcb089f85a138b457f3251a0913ad1')
validpgpkeys=('14F26682D0916CDD81E37B6D61B7B526D98F0353') # Mozilla Software Releases <release@mozilla.com>
@@ -104,6 +106,9 @@ prepare() {
# https://bugzilla.mozilla.org/show_bug.cgi?id=1530052
patch -Np1 -i ../0001-Use-remoting-name-for-GDK-application-names.patch
+ # https://bugzilla.mozilla.org/show_bug.cgi?id=1654465
+ patch -Np1 -i ../bug1654465.diff
+
echo -n "$_google_api_key" >google-api-key
echo -n "$_mozilla_api_key" >mozilla-api-key
@@ -115,6 +120,8 @@ ac_add_options --enable-release
ac_add_options --enable-hardening
ac_add_options --enable-optimize
ac_add_options --enable-rust-simd
+ac_add_options --enable-linker=lld
+ac_add_options --disable-elf-hack
export CC='clang --target=x86_64-unknown-linux-gnu'
export CXX='clang++ --target=x86_64-unknown-linux-gnu'
export AR=llvm-ar
@@ -179,15 +186,11 @@ END
xvfb-run -s "-screen 0 1920x1080x24 -nolisten local" \
./mach python build/pgo/profileserver.py
- if [[ ! -s merged.profdata ]]; then
- echo "No profile data produced."
- return 1
- fi
+ stat -c "Profile data found (%s bytes)" merged.profdata
+ test -s merged.profdata
- if [[ ! -s jarlog ]]; then
- echo "No jar log produced."
- return 1
- fi
+ stat -c "Jar log found (%s bytes)" jarlog
+ test -s jarlog
echo "Removing instrumented browser..."
./mach clobber