From 54295c4e6df45b54623b418826bb3bb21089a653 Mon Sep 17 00:00:00 2001 From: Johannes Date: Tue, 4 Jun 2019 16:39:17 +0200 Subject: [PATCH] icecat: fix cross [ci skip] --- .../icecat/patches/fix-webrtc-glibcisms.patch | 22 ++++++++++++++----- srcpkgs/icecat/template | 19 ++++++++-------- 2 files changed, 25 insertions(+), 16 deletions(-) diff --git a/srcpkgs/icecat/patches/fix-webrtc-glibcisms.patch b/srcpkgs/icecat/patches/fix-webrtc-glibcisms.patch index 0a9304430b2db7..3ff2570b12be83 100644 --- a/srcpkgs/icecat/patches/fix-webrtc-glibcisms.patch +++ b/srcpkgs/icecat/patches/fix-webrtc-glibcisms.patch @@ -1,13 +1,23 @@ ---- media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c.orig 2018-05-09 23:48:44.677389171 +0200 -+++ media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c 2018-05-09 23:48:56.254373557 +0200 -@@ -11,7 +11,9 @@ +--- media/webrtc/trunk/webrtc/system_wrappers/source/cpu_features_linux.c 2019-02-01 00:49:18.472382771 +0100 ++++ - 2019-02-01 00:50:25.928007236 +0100 +@@ -11,7 +11,10 @@ #include #include #include -#if __GLIBC_PREREQ(2, 16) -+#if !__GLIBC__ -+#include -+#elif __GLIBC_PREREQ(2, 16) ++#ifndef __GLIBC_PREREQ ++#define __GLIBC_PREREQ(a, b) 0 ++#endif ++#if !__GLIBC__ || __GLIBC_PREREQ(2, 16) #include #else #include +@@ -29,7 +32,7 @@ + int architecture = 0; + unsigned long hwcap = 0; + const char* platform = NULL; +-#if __GLIBC_PREREQ(2, 16) ++#if !__GLIBC__ || __GLIBC_PREREQ(2, 16) + hwcap = getauxval(AT_HWCAP); + platform = (const char*)getauxval(AT_PLATFORM); + #else diff --git a/srcpkgs/icecat/template b/srcpkgs/icecat/template index b1100f2e258633..7b46dea4e367e3 100644 --- a/srcpkgs/icecat/template +++ b/srcpkgs/icecat/template @@ -2,6 +2,7 @@ pkgname=icecat version=60.7.0 revision=1 +build_helper="rust" hostmakedepends="autoconf213 unzip zip pkg-config perl python yasm cargo llvm clang rust cbindgen" makedepends="gtk+-devel hunspell-devel libXt-devel libatomic-devel @@ -18,12 +19,16 @@ homepage="https://www.gnu.org/software/${pkgname}/" distfiles="${GNU_SITE}/${pkgname}/${version}/${pkgname}-${version}-gnu1.tar.bz2" checksum=6873d55b13e2d95ede3bf5bb59769179e91b1c4e05d8538d1576f18c9a6bb827 lib32disabled=yes -# I missed something when peeking at firefox-esr template, sorry. -nocross=https://build.voidlinux.org/builders/armv7l_builder/builds/18002/steps/shell_3/logs/stdio build_options="alsa dbus gtk3 pulseaudio startup_notification sndio xscreensaver" build_options_default="alsa dbus gtk3 pulseaudio startup_notification sndio xscreensaver" +case $XBPS_TARGET_MACHINE in + armv6*) + broken="required NEON extensions are not supported on armv6" + ;; +esac + CXXFLAGS="-Wno-class-memaccess -Wno-unused-function" post_extract() { @@ -44,14 +49,6 @@ do_build() { local triplet cp ${FILESDIR}/mozconfig .mozconfig - if [ "$CROSS_BUILD" ]; then - echo "ac_add_options --host=${XBPS_TRIPLET}" >>.mozconfig - echo "ac_add_options --target=${XBPS_CROSS_TRIPLET}" >>.mozconfig - else - echo "ac_add_options --host=${XBPS_TRIPLET}" >>.mozconfig - echo "ac_add_options --target=${XBPS_TRIPLET}" >>.mozconfig - fi - case "$XBPS_TARGET_MACHINE" in *-musl) echo "ac_add_options --disable-jemalloc" >>.mozconfig @@ -90,6 +87,8 @@ do_build() { echo "ac_add_options --host=$XBPS_TRIPLET" >>.mozconfig fi + mkdir -p third_party/rust/libloading/.deps + case "$XBPS_TARGET_MACHINE" in i686*) echo "ac_add_options --disable-debug-symbols" >>.mozconfig