1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-22 13:41:26 +00:00

virtualbox: 5.0.26 -> 5.1.4

This commit is contained in:
Christian Albrecht 2016-09-10 11:40:06 +02:00
parent 30107249b1
commit 2942815968
3 changed files with 67 additions and 14 deletions

View file

@ -1,6 +1,6 @@
{ stdenv, fetchurl, lib, iasl, dev86, pam, libxslt, libxml2, libX11, xproto, libXext
, libXcursor, libXmu, qt4, libIDL, SDL, libcap, zlib, libpng, glib, kernel, lvm2
, libXrandr
{ stdenv, buildEnv, fetchurl, lib, iasl, dev86, pam, libxslt, libxml2, libX11, xproto, libXext
, libXcursor, libXmu, qt5, libIDL, SDL, libcap, zlib, libpng, glib, kernel, lvm2
, libXrandr, libXinerama
, which, alsaLib, curl, libvpx, gawk, nettools, dbus
, xorriso, makeself, perl, pkgconfig, nukeReferences
, javaBindings ? false, jdk ? null
@ -20,7 +20,7 @@ let
# revision/hash as well. See
# http://download.virtualbox.org/virtualbox/${version}/SHA256SUMS
# for hashes.
version = "5.0.26";
version = "5.1.4";
forEachModule = action: ''
for mod in \
@ -41,12 +41,12 @@ let
'';
# See https://github.com/NixOS/nixpkgs/issues/672 for details
extpackRevision = "108824";
extpackRevision = "110228";
extensionPack = requireFile rec {
name = "Oracle_VM_VirtualBox_Extension_Pack-${version}-${extpackRevision}.vbox-extpack";
# IMPORTANT: Hash must be base16 encoded because it's used as an input to
# VBoxExtPackHelperApp!
sha256 = "2f2302c7ba3d00a1258fe8e7767a6eb08dccdc3c31f6e3eeb74063c2c268b104";
sha256 = "9462ff1b567c37ad9a33c0c7ca1925776615ec89b5a72563f29a8cc8514cf316";
message = ''
In order to use the extension pack, you need to comply with the VirtualBox Personal Use
and Evaluation License (PUEL) available at:
@ -60,23 +60,28 @@ let
'';
};
vbox-qt5-env = buildEnv {
name = "vbox-qt5-env-${version}";
paths = [ qt5.qtbase.dev qt5.qtbase.out qt5.qtx11extras.dev qt5.qtx11extras.out qt5.qttools.dev ];
};
in stdenv.mkDerivation {
name = "virtualbox-${version}-${kernel.version}";
src = fetchurl {
url = "http://download.virtualbox.org/virtualbox/${version}/VirtualBox-${version}.tar.bz2";
sha256 = "78dec1369d2c8feefea3c682d95e76c0e99414c56626388035cf4061d4dad62e";
sha256 = "b9a14a7771059c55c44b97f8d4eef9bea84544f3e215e0caa563bc35e2f16aaf";
};
buildInputs =
[ iasl dev86 libxslt libxml2 xproto libX11 libXext libXcursor libIDL
libcap glib lvm2 python alsaLib curl libvpx pam xorriso makeself perl
pkgconfig which libXmu nukeReferences ]
pkgconfig which libXmu nukeReferences libpng ]
++ optional javaBindings jdk
++ optional pythonBindings python
++ optional pulseSupport libpulseaudio
++ optionals (headless) [ libXrandr libpng ]
++ optionals (!headless) [ qt4 SDL ];
++ optionals (headless) [ libXrandr ]
++ optionals (!headless) [ vbox-qt5-env libXinerama SDL ];
hardeningDisable = [ "fortify" "pic" "stackprotector" ];
@ -103,11 +108,12 @@ in stdenv.mkDerivation {
set +x
'';
patches = optional enableHardening ./hardened.patch;
patches = optional enableHardening ./hardened.patch
++ [ ./libressl.patch ];
postPatch = ''
sed -i -e 's|/sbin/ifconfig|${nettools}/bin/ifconfig|' \
src/apps/adpctl/VBoxNetAdpCtl.cpp
src/VBox/HostDrivers/adpctl/VBoxNetAdpCtl.cpp
'';
# first line: ugly hack, and it isn't yet clear why it's a problem
@ -135,7 +141,7 @@ in stdenv.mkDerivation {
./configure \
${optionalString headless "--build-headless"} \
${optionalString (!headless) "--with-qt4-dir=${qt4}"} \
${optionalString (!headless) "--with-qt-dir=${vbox-qt5-env}"} \
${optionalString (!javaBindings) "--disable-java"} \
${optionalString (!pythonBindings) "--disable-python"} \
${optionalString (!pulseSupport) "--disable-pulse"} \

View file

@ -12,7 +12,7 @@ stdenv.mkDerivation {
src = fetchurl {
url = "http://download.virtualbox.org/virtualbox/${version}/VBoxGuestAdditions_${version}.iso";
sha256 = "7458ee5a7121a7d243fd6a7528ba427945d9120c5efc7cd75b3951fb01f09c59";
sha256 = "e385b698338003595f6cdeee7b631ec6713058ba1227d1f2a1da342bdf741982";
};
KERN_DIR = "${kernel.dev}/lib/modules/*/build";

View file

@ -0,0 +1,47 @@
diff --git a/src/VBox/Runtime/common/crypto/digest-builtin.cpp b/src/VBox/Runtime/common/crypto/digest-builtin.cpp
index 66b4304..1aaceff 100644
--- a/src/VBox/Runtime/common/crypto/digest-builtin.cpp
+++ b/src/VBox/Runtime/common/crypto/digest-builtin.cpp
@@ -561,7 +561,7 @@ static PCRTCRDIGESTDESC const g_apDigestOps[] =
* OpenSSL EVP.
*/
-# if OPENSSL_VERSION_NUMBER >= 0x10100000
+# if OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER)
/** @impl_interface_method{RTCRDIGESTDESC::pfnNew} */
static DECLCALLBACK(void*) rtCrDigestOsslEvp_New(void)
{
@@ -597,7 +597,7 @@ static DECLCALLBACK(int) rtCrDigestOsslEvp_Init(void *pvState, void *pvOpaque, b
if (fReInit)
{
pEvpType = EVP_MD_CTX_md(pThis);
-# if OPENSSL_VERSION_NUMBER >= 0x10100000
+# if OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER)
EVP_MD_CTX_reset(pThis);
# else
EVP_MD_CTX_cleanup(pThis);
@@ -616,7 +616,7 @@ static DECLCALLBACK(int) rtCrDigestOsslEvp_Init(void *pvState, void *pvOpaque, b
static DECLCALLBACK(void) rtCrDigestOsslEvp_Delete(void *pvState)
{
EVP_MD_CTX *pThis = (EVP_MD_CTX *)pvState;
-# if OPENSSL_VERSION_NUMBER >= 0x10100000
+# if OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER)
EVP_MD_CTX_reset(pThis);
# else
EVP_MD_CTX_cleanup(pThis);
@@ -661,13 +661,13 @@ static RTCRDIGESTDESC const g_rtCrDigestOpenSslDesc =
NULL,
RTDIGESTTYPE_UNKNOWN,
EVP_MAX_MD_SIZE,
-# if OPENSSL_VERSION_NUMBER >= 0x10100000
+# if OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER)
0,
# else
sizeof(EVP_MD_CTX),
# endif
0,
-# if OPENSSL_VERSION_NUMBER >= 0x10100000
+# if OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER)
rtCrDigestOsslEvp_New,
rtCrDigestOsslEvp_Free,
# else