diff --git a/pkgs/applications/virtualization/qemu/default.nix b/pkgs/applications/virtualization/qemu/default.nix index 04fead5209c..25651a359d6 100644 --- a/pkgs/applications/virtualization/qemu/default.nix +++ b/pkgs/applications/virtualization/qemu/default.nix @@ -35,7 +35,7 @@ let in stdenv.mkDerivation rec { - version = "3.1.0"; + version = "4.0.0"; name = "qemu-" + stdenv.lib.optionalString xenSupport "xen-" + stdenv.lib.optionalString hostCpuOnly "host-cpu-only-" @@ -44,7 +44,7 @@ stdenv.mkDerivation rec { src = fetchurl { url = "https://wiki.qemu.org/download/qemu-${version}.tar.bz2"; - sha256 = "08frr1fdjx8qcfh3fafn10kibdwbvkqqvfl7hpqbm7i9dg4f1zlq"; + sha256 = "085g6f75si8hbn94mnnjn1r7ysixn5bqj4bhqwvadj00fhzp2zvd"; }; nativeBuildInputs = [ python2 pkgconfig flex bison ]; @@ -78,13 +78,7 @@ stdenv.mkDerivation rec { ./no-etc-install.patch ./fix-qemu-ga.patch ./9p-ignore-noatime.patch - (fetchpatch { - name = "CVE-2019-3812.patch"; - url = "https://git.qemu.org/?p=qemu.git;a=patch;h=b05b267840515730dbf6753495d5b7bd8b04ad1c"; - sha256 = "03a5vc5wvirbyi5r8kb2r4m2w6f1zmh9bqsr2psh4pblwar0nf55"; - }) ] ++ optional nixosTestRunner ./force-uid0-on-9p.patch - ++ optional pulseSupport ./fix-hda-recording.patch ++ optionals stdenv.hostPlatform.isMusl [ (fetchpatch { url = https://raw.githubusercontent.com/alpinelinux/aports/2bb133986e8fa90e2e76d53369f03861a87a74ef/main/qemu/xattr_size_max.patch; diff --git a/pkgs/applications/virtualization/qemu/fix-hda-recording.patch b/pkgs/applications/virtualization/qemu/fix-hda-recording.patch deleted file mode 100644 index b4e21f4f347..00000000000 --- a/pkgs/applications/virtualization/qemu/fix-hda-recording.patch +++ /dev/null @@ -1,34 +0,0 @@ -diff --git a/audio/paaudio.c b/audio/paaudio.c -index fea6071..c1169d4 100644 ---- a/audio/paaudio.c -+++ b/audio/paaudio.c -@@ -608,6 +608,7 @@ static int qpa_init_in(HWVoiceIn *hw, struct audsettings *as, void *drv_opaque) - { - int error; - pa_sample_spec ss; -+ pa_buffer_attr ba; - struct audsettings obt_as = *as; - PAVoiceIn *pa = (PAVoiceIn *) hw; - paaudio *g = pa->g = drv_opaque; -@@ -616,6 +617,12 @@ static int qpa_init_in(HWVoiceIn *hw, struct audsettings *as, void *drv_opaque) - ss.channels = as->nchannels; - ss.rate = as->freq; - -+ ba.fragsize = pa_frame_size (&ss) * g->conf.samples; -+ ba.maxlength = 5 * ba.fragsize; -+ ba.tlength = -1; -+ ba.prebuf = -1; -+ ba.minreq = -1; -+ - obt_as.fmt = pa_to_audfmt (ss.format, &obt_as.endianness); - - pa->stream = qpa_simple_new ( -@@ -625,7 +632,7 @@ static int qpa_init_in(HWVoiceIn *hw, struct audsettings *as, void *drv_opaque) - g->conf.source, - &ss, - NULL, /* channel map */ -- NULL, /* buffering attributes */ -+ &ba, /* buffering attributes */ - &error - ); - if (!pa->stream) { diff --git a/pkgs/applications/virtualization/qemu/no-etc-install.patch b/pkgs/applications/virtualization/qemu/no-etc-install.patch index 47b4b3176dc..37c12ddbfeb 100644 --- a/pkgs/applications/virtualization/qemu/no-etc-install.patch +++ b/pkgs/applications/virtualization/qemu/no-etc-install.patch @@ -1,10 +1,25 @@ +From 98b3e5993bbdb0013b6cc1814e0ad9555290c3af Mon Sep 17 00:00:00 2001 +From: Will Dietz +Date: Tue, 23 Apr 2019 21:31:45 -0500 +Subject: [PATCH] no install localstatedir + +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index 04a0d45050..5dc82d0eb7 100644 --- a/Makefile +++ b/Makefile -@@ -597,7 +597,7 @@ +@@ -786,7 +786,7 @@ endif + ICON_SIZES=16x16 24x24 32x32 48x48 64x64 128x128 256x256 512x512 -install: all $(if $(BUILD_DOCS),install-doc) install-datadir install-localstatedir +install: all $(if $(BUILD_DOCS),install-doc) install-datadir ifneq ($(TOOLS),) - $(call install-prog,$(subst qemu-ga,qemu-ga$(EXESUF),$(TOOLS)),$(DESTDIR)$(bindir)) + $(call install-prog,$(subst qemu-ga,qemu-ga$(EXESUF),$(TOOLS)),$(DESTDIR)$(bindir)) endif +-- +2.21.GIT +