summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorCole Mickens <cole.mickens@gmail.com>2016-02-18 17:30:06 -0800
committerCole Mickens <cole.mickens@gmail.com>2016-02-18 21:08:28 -0800
commit718848d5aac47660b0c0d7bdd1702c1f474debf1 (patch)
tree7d15fb30240c6940d931fc18bedb87ac07f844c2 /nixos/modules
parent412dd80149e837ef89171f1fe0f0423e3b72aa21 (diff)
downloadnixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.tar
nixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.tar.gz
nixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.tar.bz2
nixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.tar.lz
nixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.tar.xz
nixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.tar.zst
nixpkgs-718848d5aac47660b0c0d7bdd1702c1f474debf1.zip
azure: package qemu @ 2.2.0
This commit packages qemu-220. This package is qemu-2.2.0
and is only used with Azure.
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/virtualisation/azure-image.nix4
-rw-r--r--nixos/modules/virtualisation/azure-qemu-220-no-etc-install.patch14
2 files changed, 16 insertions, 2 deletions
diff --git a/nixos/modules/virtualisation/azure-image.nix b/nixos/modules/virtualisation/azure-image.nix
index 7093e50ed35..f0a739bc95d 100644
--- a/nixos/modules/virtualisation/azure-image.nix
+++ b/nixos/modules/virtualisation/azure-image.nix
@@ -16,14 +16,14 @@ in
               cyl=$(((${diskSize}*1024*1024)/(512*63*255)))
               size=$(($cyl*255*63*512))              
               roundedsize=$((($size/(1024*1024)+1)*(1024*1024)))
-              ${pkgs.vmTools.qemu}/bin/qemu-img create -f raw $diskImage $roundedsize
+              ${pkgs.vmTools.qemu-220}/bin/qemu-img create -f raw $diskImage $roundedsize
               mv closure xchg/
             '';
 
           postVM =
             ''
               mkdir -p $out
-              ${pkgs.vmTools.qemu}/bin/qemu-img convert -f raw -O vpc -o subformat=fixed $diskImage $out/disk.vhd
+              ${pkgs.vmTools.qemu-220}/bin/qemu-img convert -f raw -O vpc -o subformat=fixed $diskImage $out/disk.vhd
               rm $diskImage
             '';
           diskImageBase = "nixos-image-${config.system.nixosLabel}-${pkgs.stdenv.system}.raw";
diff --git a/nixos/modules/virtualisation/azure-qemu-220-no-etc-install.patch b/nixos/modules/virtualisation/azure-qemu-220-no-etc-install.patch
new file mode 100644
index 00000000000..81d29feea3d
--- /dev/null
+++ b/nixos/modules/virtualisation/azure-qemu-220-no-etc-install.patch
@@ -0,0 +1,14 @@
+diff --git a/Makefile b/Makefile
+index d6b9dc1..ce7c493 100644
+--- a/Makefile
++++ b/Makefile
+@@ -384,8 +384,7 @@ install-confdir:
+ install-sysconfig: install-datadir install-confdir
+ 	$(INSTALL_DATA) $(SRC_PATH)/sysconfigs/target/target-x86_64.conf "$(DESTDIR)$(qemu_confdir)"
+ 
+-install: all $(if $(BUILD_DOCS),install-doc) install-sysconfig \
+-install-datadir install-localstatedir
++install: all $(if $(BUILD_DOCS),install-doc) install-datadir
+ ifneq ($(TOOLS),)
+ 	$(call install-prog,$(TOOLS),$(DESTDIR)$(bindir))
+ endif