summaryrefslogtreecommitdiff
path: root/qemu
diff options
context:
space:
mode:
authorFredrik Rinnestam <fredrik@crux.nu>2018-02-04 17:19:54 +0100
committerFredrik Rinnestam <fredrik@crux.nu>2018-02-04 17:19:54 +0100
commit6a1554cabb5d358f6068471bc017f84f6dbc5fb6 (patch)
treeadfd853c5704a345fa5541ea0067b58a24b1d904 /qemu
parent3ea797e65ee547af94487d2fbde0ae3c8fd3dbb7 (diff)
downloadopt-6a1554cabb5d358f6068471bc017f84f6dbc5fb6.tar.gz
opt-6a1554cabb5d358f6068471bc017f84f6dbc5fb6.tar.xz
qemu: fix glibc 2.27 build
Diffstat (limited to 'qemu')
-rw-r--r--qemu/.md5sum1
-rw-r--r--qemu/.signature5
-rw-r--r--qemu/Pkgfile5
-rw-r--r--qemu/memfd.patch26
4 files changed, 34 insertions, 3 deletions
diff --git a/qemu/.md5sum b/qemu/.md5sum
index 8a4e7e505..3ecc517bb 100644
--- a/qemu/.md5sum
+++ b/qemu/.md5sum
@@ -1 +1,2 @@
+394d007fcb6ed2530f58e506c075a0bc memfd.patch
b375373f688bea0cd8865b966dad15e3 qemu-2.10.1.tar.bz2
diff --git a/qemu/.signature b/qemu/.signature
index 819d95987..3be3d7471 100644
--- a/qemu/.signature
+++ b/qemu/.signature
@@ -1,5 +1,6 @@
untrusted comment: verify with /etc/ports/opt.pub
-RWSE3ohX2g5d/cjSR4H3k4OT/I8fUaC3NQ/X5zx2DKZm49cL2h5hBq5mORi6XTrqslP6PFImentBKdhbNR/0B2NmoACfLpoT5Aw=
-SHA256 (Pkgfile) = e0fcd92f07f69c3bf518b5bcc76a0bd1b08e6dab452f58b69348343ced15cca0
+RWSE3ohX2g5d/Rh1LWvdF9IYn+aNeQQtC6p/QYBOIGn0vKFDCHRyT96A+PwCeG1dtJ0hMM9Xf7LD0Zv+wDQgKEb5M9LBm5zUkgc=
+SHA256 (Pkgfile) = 3058e4616ffac6e2fef9b58e7dbc9c997869d24f114158804fc36a31ea00deb6
SHA256 (.footprint) = b6da9b735ebebce85e3cce44546080de1466210467e188496f7164eb7a726024
SHA256 (qemu-2.10.1.tar.bz2) = 8e040bc7556401ebb3a347a8f7878e9d4028cf71b2744b1a1699f4e741966ba8
+SHA256 (memfd.patch) = 367acd86f6e0c020119d605830bc2eb1e02be1906f2ba58839893aa35c6054b3
diff --git a/qemu/Pkgfile b/qemu/Pkgfile
index d897d2090..2aeb4091e 100644
--- a/qemu/Pkgfile
+++ b/qemu/Pkgfile
@@ -7,12 +7,15 @@
name=qemu
version=2.10.1
release=1
-source=(http://wiki.qemu-project.org/download/qemu-$version.tar.bz2)
+source=(http://wiki.qemu-project.org/download/qemu-$version.tar.bz2 \
+ memfd.patch)
build() {
cd $name-$version
+ patch -p1 -i $SRC/memfd.patch
+
./configure --prefix=/usr \
--cc="${CC:=gcc}" \
--host-cc="${CC:=gcc}" \
diff --git a/qemu/memfd.patch b/qemu/memfd.patch
new file mode 100644
index 000000000..9ff848460
--- /dev/null
+++ b/qemu/memfd.patch
@@ -0,0 +1,26 @@
+diff -rupN qemu-2.10.1-orig/configure qemu-2.10.1/configure
+--- qemu-2.10.1-orig/configure 2018-02-03 20:31:28.775201548 +0100
++++ qemu-2.10.1/configure 2018-02-03 20:49:55.690456630 +0100
+@@ -3855,7 +3855,7 @@ fi
+ # check if memfd is supported
+ memfd=no
+ cat > $TMPC << EOF
+-#include <sys/memfd.h>
++#include <sys/mman.h>
+
+ int main(void)
+ {
+diff -rupN qemu-2.10.1-orig/util/memfd.c qemu-2.10.1/util/memfd.c
+--- qemu-2.10.1-orig/util/memfd.c 2018-02-03 20:31:29.058197629 +0100
++++ qemu-2.10.1/util/memfd.c 2018-02-03 20:50:33.589907638 +0100
+@@ -31,9 +31,7 @@
+
+ #include "qemu/memfd.h"
+
+-#ifdef CONFIG_MEMFD
+-#include <sys/memfd.h>
+-#elif defined CONFIG_LINUX
++#if defined CONFIG_LINUX && !defined CONFIG_MEMFD
+ #include <sys/syscall.h>
+ #include <asm/unistd.h>
+

Generated by cgit