diff options
author | William A. Kennington III <william@wkennington.com> | 2015-06-01 01:49:57 -0700 |
---|---|---|
committer | William A. Kennington III <william@wkennington.com> | 2015-06-01 01:50:05 -0700 |
commit | 5afa4f18d6173725d593e59f1c4a8f54b575f9fe (patch) | |
tree | 560fa33cacfd96ee6b7aa5409da394bba7cf0320 /pkgs/applications | |
parent | 7edb27b7af6ebff7e35207f7fcf16e0e2bd8884a (diff) |
qemu-nix: Build statically
Diffstat (limited to 'pkgs/applications')
-rw-r--r-- | pkgs/applications/virtualization/qemu/default.nix | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/pkgs/applications/virtualization/qemu/default.nix b/pkgs/applications/virtualization/qemu/default.nix index 0d57a8d9f5754..f04ff3119303f 100644 --- a/pkgs/applications/virtualization/qemu/default.nix +++ b/pkgs/applications/virtualization/qemu/default.nix @@ -41,7 +41,7 @@ let optLibuuid = if isNix then null else shouldUsePkg libuuid; optVde2 = if isNix then null else shouldUsePkg vde2; optLibaio = shouldUsePkg libaio; - optLibcap_ng = shouldUsePkg libcap_ng; + optLibcap_ng = if isNix then null else shouldUsePkg libcap_ng; optSpice = if isNix then null else shouldUsePkg spice; optSpice_protocol = if isNix then null else shouldUsePkg spice_protocol; optLibceph = if isNix then null else shouldUsePkg libceph; @@ -95,6 +95,8 @@ let targetList = if stdenv.system == "x86_64-linux" then "x86_64-softmmu,i386-softmmu" else if stdenv.system == "i686-linux" then "i386-softmmu" else null; + + hasModules = if isNix then null else true; in stdenv.mkDerivation rec { @@ -138,7 +140,7 @@ stdenv.mkDerivation rec { (mkOther "smbd" "smbd") (mkOther "sysconfdir" "/etc") (mkOther "localstatedir" "/var") - (mkEnable true "modules" null) + (mkEnable hasModules "modules" null) (mkEnable false "debug-tcg" null) (mkEnable false "debug-info" null) (mkEnable false "sparse" null) @@ -167,7 +169,7 @@ stdenv.mkDerivation rec { (mkEnable (!isNix) "system" null) (mkEnable (!isKvmOnly) "user" null) (mkEnable (!isKvmOnly) "guest-base" null) - (mkEnable true "pie" null) + (mkEnable (!isNix) "pie" null) (mkEnable (optLibuuid != null) "uuid" null) (mkEnable (optVde2 != null) "vde" null) (mkEnable false "netmap" null) # TODO(wkennington): Add Support @@ -199,6 +201,8 @@ stdenv.mkDerivation rec { (mkEnable (optNumactl != null) "numa" null) ] ++ optionals isKvmOnly [ (mkOther "target-list" targetList) + ] ++ optionals isNix [ + "--static" ]; installFlags = [ |