about summary refs log tree commit diff
path: root/pkgs/applications/virtualization/virtualbox
diff options
context:
space:
mode:
authorJulian Stecklina <julian.stecklina@cyberus-technology.de>2020-04-22 13:13:59 +0200
committerJulian Stecklina <julian.stecklina@cyberus-technology.de>2020-04-28 13:36:50 +0200
commit7c995a453220b0269ffd844344982fcc195212ef (patch)
treebff9ef86d6dc269706b5b337bcae62683eecd3c9 /pkgs/applications/virtualization/virtualbox
parentc26e7f9aac4a12bc206d4461efd228697e1dd3a7 (diff)
downloadnixlib-7c995a453220b0269ffd844344982fcc195212ef.tar
nixlib-7c995a453220b0269ffd844344982fcc195212ef.tar.gz
nixlib-7c995a453220b0269ffd844344982fcc195212ef.tar.bz2
nixlib-7c995a453220b0269ffd844344982fcc195212ef.tar.lz
nixlib-7c995a453220b0269ffd844344982fcc195212ef.tar.xz
nixlib-7c995a453220b0269ffd844344982fcc195212ef.tar.zst
nixlib-7c995a453220b0269ffd844344982fcc195212ef.zip
virtualbox: build BIOS from C instead of alternative sources
VirtualBox ships with "alternative BIOS sources" for its virtual BIOS.
These are generated by first compiling the BIOS C sources with the
Open Watcom toolchain, disassembling the output and checking in the
disassembly into the VirtualBox repo.

The result means that the BIOS C code cannot be patched, because it's
not compiled from the C sources, if Open Watcom is not there.

As Open Watcom is now available in nixpkgs, we can just ignore the
alternative BIOS sources and compile it from C directly.
Diffstat (limited to 'pkgs/applications/virtualization/virtualbox')
-rw-r--r--pkgs/applications/virtualization/virtualbox/default.nix4
1 files changed, 4 insertions, 0 deletions
diff --git a/pkgs/applications/virtualization/virtualbox/default.nix b/pkgs/applications/virtualization/virtualbox/default.nix
index df7b81a43c8a..7b7929d9f1d6 100644
--- a/pkgs/applications/virtualization/virtualbox/default.nix
+++ b/pkgs/applications/virtualization/virtualbox/default.nix
@@ -3,6 +3,9 @@
 , libpng, glib, lvm2, libXrandr, libXinerama, libopus, qtbase, qtx11extras
 , qttools, qtsvg, qtwayland, pkgconfig, which, docbook_xsl, docbook_xml_dtd_43
 , alsaLib, curl, libvpx, nettools, dbus, substituteAll, fetchpatch
+# If open-watcom-bin is not passed, VirtualBox will fall back to use
+# the shipped alternative sources (assembly).
+, open-watcom-bin ? null
 , makeself, perl
 , javaBindings ? true, jdk ? null # Almost doesn't affect closure size
 , pythonBindings ? false, python3 ? null
@@ -148,6 +151,7 @@ in stdenv.mkDerivation {
       ${optionalString (!pulseSupport) "--disable-pulse"} \
       ${optionalString (!enableHardening) "--disable-hardening"} \
       ${optionalString (!enable32bitGuests) "--disable-vmmraw"} \
+      ${optionalString (open-watcom-bin != null) "--with-ow-dir=${open-watcom-bin}"} \
       --disable-kmods
     sed -e 's@PKG_CONFIG_PATH=.*@PKG_CONFIG_PATH=${libIDL}/lib/pkgconfig:${glib.dev}/lib/pkgconfig ${libIDL}/bin/libIDL-config-2@' \
         -i AutoConfig.kmk