summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app-emulation/virtualbox-extpack-oracle/Manifest1
-rw-r--r--app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.1.24.117012-r1706.ebuild42
-rw-r--r--app-emulation/virtualbox-guest-additions/Manifest1
-rw-r--r--app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.1.24-r1706.ebuild191
-rw-r--r--app-emulation/virtualbox-modules/Manifest1
-rw-r--r--app-emulation/virtualbox-modules/virtualbox-modules-5.1.24-r1706.ebuild36
-rw-r--r--app-emulation/virtualbox/Manifest1
-rw-r--r--app-emulation/virtualbox/virtualbox-5.1.24-r1706.ebuild459
-rw-r--r--sys-kernel/virtualbox-guest-dkms/Manifest1
-rw-r--r--sys-kernel/virtualbox-guest-dkms/files/dkms.patch4
-rw-r--r--sys-kernel/virtualbox-guest-dkms/virtualbox-guest-dkms-5.1.24-r1706.ebuild43
-rw-r--r--sys-kernel/virtualbox-modules-dkms/Manifest1
-rw-r--r--sys-kernel/virtualbox-modules-dkms/virtualbox-modules-dkms-5.1.24-r1706.ebuild45
-rw-r--r--x11-drivers/xf86-video-virtualbox/Manifest1
-rw-r--r--x11-drivers/xf86-video-virtualbox/xf86-video-virtualbox-5.1.24-r1706.ebuild192
15 files changed, 1017 insertions, 2 deletions
diff --git a/app-emulation/virtualbox-extpack-oracle/Manifest b/app-emulation/virtualbox-extpack-oracle/Manifest
index 04f89f2a..c08877ec 100644
--- a/app-emulation/virtualbox-extpack-oracle/Manifest
+++ b/app-emulation/virtualbox-extpack-oracle/Manifest
@@ -1 +1,2 @@
DIST Oracle_VM_VirtualBox_Extension_Pack-5.1.22-115126.tar.gz 19559514 SHA256 244e6f450cba64e0b025711050db3c43e6ce77e12cd80bcd08796315a90c8aaf SHA512 55841287d580d984142a0572aff4124a180bbe10cb8536426992b5d9e0ce0f3f6d3858aae12de728995a237101a581aa6500b312e457b812f079e3ad67e7ec10 WHIRLPOOL fd883e9f4c77b282528c938296ab820a719334abd3573e4fb9f2023b9a4f2dfa09261aad94f808a6bc1203cf5419f17cbc39d7af8e1b6938b05b14ea51470990
+DIST Oracle_VM_VirtualBox_Extension_Pack-5.1.24-117012.tar.gz 19624088 SHA256 65198a2e048d30fc7d18cd4670fb84fed9a878cca1b77f416b4fea4efe8ca2a4 SHA512 fc821a446c67c4046dd2aa2078d6a71a63a490d59c96f76b29a5a46b26ad7e51588c1009efbafa448e73c799dc816de0b5f0ee17b10d306d3e701a15f69c595d WHIRLPOOL b86d40a08774cd56f612e4bd1edd1bea0e070185e9fab19ca21c0a08ffe092c73877a62dfa5be68e7a963145a84785330c935dd43b5c9ddcfbfc3ee2236f9e0a
diff --git a/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.1.24.117012-r1706.ebuild b/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.1.24.117012-r1706.ebuild
new file mode 100644
index 00000000..3c6c739d
--- /dev/null
+++ b/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.1.24.117012-r1706.ebuild
@@ -0,0 +1,42 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit eutils multilib versionator
+
+MAIN_PV="$(get_version_component_range 1-3)"
+if [[ ${PV} = *_beta* ]] || [[ ${PV} = *_rc* ]] ; then
+ MY_PV="${MAIN_PV}_$(get_version_component_range 5)"
+ DEP_PV="${MY_PV}"
+ MY_PV="${MY_PV/beta/BETA}"
+ MY_PV="${MY_PV/rc/RC}"
+else
+ MY_PV="${MAIN_PV}"
+ DEP_PV="${MAIN_PV}"
+fi
+VBOX_BUILD_ID="$(get_version_component_range 4)"
+MY_PN="Oracle_VM_VirtualBox_Extension_Pack"
+MY_P="${MY_PN}-${MY_PV}-${VBOX_BUILD_ID}"
+
+DESCRIPTION="PUEL extensions for VirtualBox"
+HOMEPAGE="http://www.virtualbox.org/"
+SRC_URI="http://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.vbox-extpack -> ${MY_P}.tar.gz"
+
+LICENSE="PUEL"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE=""
+RESTRICT="mirror strip"
+
+RDEPEND="~app-emulation/virtualbox-${DEP_PV}"
+
+S="${WORKDIR}"
+
+QA_PREBUILT="/usr/lib*/virtualbox/ExtensionPacks/${MY_PN}/.*"
+
+src_install() {
+ insinto /usr/$(get_libdir)/virtualbox/ExtensionPacks/${MY_PN}
+ doins -r linux.${ARCH}
+ doins ExtPack* PXE-Intel.rom
+}
diff --git a/app-emulation/virtualbox-guest-additions/Manifest b/app-emulation/virtualbox-guest-additions/Manifest
index f9bb476c..9ae911ae 100644
--- a/app-emulation/virtualbox-guest-additions/Manifest
+++ b/app-emulation/virtualbox-guest-additions/Manifest
@@ -1 +1,2 @@
DIST VirtualBox-5.1.22.tar.bz2 115838360 SHA256 fcc918000b8c5ece553541ec10a9182410a742b7266257c76dda895dcd389899 SHA512 e48457371c9139fc04477c82fbd18974378fde08af2a6f9058a0eafa6e522987bd129b8d87c9f381789c4e817aded752fde6ea7fcb2ade471997373802e09348 WHIRLPOOL c6034aad69c8a25eaf5909b6889f04f8090ace562e18a76bc55ad4d3e8347844fa1ab466d32e92b09180dff71e0f928826db0994d34b03f44b11bdb03ccc40d2
+DIST VirtualBox-5.1.24.tar.bz2 116135442 SHA256 ee2db169a322bf0db3c3b6d8b84aa39236f36cbf37d0a4c10ab65902a396bb60 SHA512 3c9ad230a53f9159e648ae1f342bdb220ffd85f2ddd45ae4c61d6606f358e9343a4968b2a91784893fb1284288ad41c538b1ab299b3a49e7739bfc8c4fdea910 WHIRLPOOL aad73184e2d36928449e688fd86c6f42c061f77e86c7e6119a205154b307846ed25175f49e3f8e451844b48c0e71e9531902753f1fd917123c401ffbf7744a2d
diff --git a/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.1.24-r1706.ebuild b/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.1.24-r1706.ebuild
new file mode 100644
index 00000000..73b235b8
--- /dev/null
+++ b/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.1.24-r1706.ebuild
@@ -0,0 +1,191 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit eutils systemd user toolchain-funcs
+
+MY_PV="${PV/beta/BETA}"
+MY_PV="${MY_PV/rc/RC}"
+MY_P=VirtualBox-${MY_PV}
+DESCRIPTION="VirtualBox kernel modules and user-space tools for Gentoo guests"
+HOMEPAGE="http://www.virtualbox.org/"
+SRC_URI="http://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="X"
+
+RDEPEND="X? ( x11-apps/xrandr
+ x11-apps/xrefresh
+ x11-libs/libXmu
+ x11-libs/libX11
+ x11-libs/libXt
+ x11-libs/libXext
+ x11-libs/libXau
+ x11-libs/libXdmcp
+ x11-libs/libSM
+ x11-libs/libICE
+ x11-proto/glproto )
+ sys-apps/dbus
+ =sys-kernel/virtualbox-guest-dkms-${PV}
+ !!x11-drivers/xf86-input-virtualbox"
+DEPEND="${RDEPEND}
+ >=dev-util/kbuild-0.1.9998_pre20131130
+ >=dev-lang/yasm-0.6.2
+ sys-devel/bin86
+ sys-libs/pam
+ sys-power/iasl
+ X? ( x11-proto/renderproto )
+ !X? ( x11-proto/xproto )"
+PDEPEND="X? ( ~x11-drivers/xf86-video-virtualbox-${PV} )"
+
+BUILD_TARGETS="all"
+BUILD_TARGET_ARCH="${ARCH}"
+
+S="${WORKDIR}/${MY_P}"
+
+pkg_setup() {
+ enewgroup vboxguest
+ enewuser vboxguest -1 /bin/sh /dev/null vboxguest
+ enewgroup vboxsf
+}
+
+src_unpack() {
+ unpack ${A}
+
+ "${S}"/src/VBox/Additions/linux/export_modules "${WORKDIR}/vbox-kmod.tar.gz"
+ unpack ./vbox-kmod.tar.gz
+
+ cd "${S}"
+ rm -rf kBuild/bin tools
+}
+
+src_prepare() {
+ pushd "${WORKDIR}" &>/dev/null || die
+ eapply "${FILESDIR}"/vboxguest-4.1.0-log-use-c99.patch
+ popd &>/dev/null || die
+
+ cp "${FILESDIR}/${PN}-5-localconfig" LocalConfig.kmk || die
+ use X || echo "VBOX_WITH_X11_ADDITIONS :=" >> LocalConfig.kmk
+
+ for vboxheader in {product,revision,version}-generated.h ; do
+ for mdir in vbox{guest,sf} ; do
+ ln -sf "${S}"/out/linux.${ARCH}/release/${vboxheader} \
+ "${WORKDIR}/${mdir}/${vboxheader}"
+ done
+ done
+
+ sed -e '/^check_gcc$/d' -i configure || die
+
+ eapply_user
+}
+
+src_configure() {
+ local cmd=(
+ ./configure
+ --nofatal
+ --disable-xpcom
+ --disable-sdl-ttf
+ --disable-pulse
+ --disable-alsa
+ --with-gcc="$(tc-getCC)"
+ --with-g++="$(tc-getCXX)"
+ --target-arch=${ARCH}
+ --with-linux="${KV_OUT_DIR}"
+ --build-headless
+ )
+ echo "${cmd[@]}"
+ "${cmd[@]}" || die "configure failed"
+ source ./env.sh
+ export VBOX_GCC_OPT="${CFLAGS} ${CPPFLAGS}"
+}
+
+src_compile() {
+ MAKE="kmk" \
+ emake TOOL_YASM_AS=yasm \
+ VBOX_ONLY_ADDITIONS=1
+}
+
+src_install() {
+ cd "${S}"/out/linux.${ARCH}/release/bin/additions || die
+
+ insinto /sbin
+ newins mount.vboxsf mount.vboxsf
+ fperms 4755 /sbin/mount.vboxsf
+
+ newinitd "${FILESDIR}"/${PN}-8.initd ${PN}
+
+ insinto /usr/sbin/
+ newins VBoxService vboxguest-service
+ fperms 0755 /usr/sbin/vboxguest-service
+
+ insinto /usr/bin
+ doins VBoxControl
+ fperms 0755 /usr/bin/VBoxControl
+
+ if use X ; then
+ doins VBoxClient
+ fperms 0755 /usr/bin/VBoxClient
+
+ pushd "${S}"/src/VBox/Additions/x11/Installer &>/dev/null \
+ || die
+ newins 98vboxadd-xclient VBoxClient-all
+ fperms 0755 /usr/bin/VBoxClient-all
+ popd &>/dev/null || die
+ fi
+
+ local udev_rules_dir="/lib/udev/rules.d"
+ dodir ${udev_rules_dir}
+ echo 'KERNEL=="vboxguest", OWNER="vboxguest", GROUP="vboxguest", MODE="0660"' \
+ >> "${D}/${udev_rules_dir}/60-virtualbox-guest-additions.rules" \
+ || die
+ echo 'KERNEL=="vboxuser", OWNER="vboxguest", GROUP="vboxguest", MODE="0660"' \
+ >> "${D}/${udev_rules_dir}/60-virtualbox-guest-additions.rules" \
+ || die
+
+ insinto /etc/xdg/autostart
+ doins "${FILESDIR}"/vboxclient.desktop
+
+ insinto /usr/share/doc/${PF}
+ doins "${FILESDIR}"/xorg.conf.vbox
+
+ systemd_dounit "${FILESDIR}/${PN}.service"
+}
+
+pkg_postinst() {
+ if ! use X ; then
+ elog "use flag X is off, enable it to install the"
+ elog "X Window System video driver."
+ fi
+ elog ""
+ elog "Please add users to the \"vboxguest\" group so they can"
+ elog "benefit from seamless mode, auto-resize and clipboard."
+ elog ""
+ elog "The vboxsf group has been added to make automount services work."
+ elog "These services are part of the shared folders support."
+ elog ""
+ elog "Please add:"
+ elog "/etc/init.d/${PN}"
+ elog "to the default runlevel in order to start"
+ elog "needed services."
+ elog "To use the VirtualBox X driver, use the following"
+ elog "file as your /etc/X11/xorg.conf:"
+ elog " /usr/share/doc/${PF}/xorg.conf.vbox"
+ elog ""
+ elog "Also make sure you use the Mesa library for OpenGL:"
+ elog " eselect opengl set xorg-x11"
+ elog ""
+ elog "An autostart .desktop file has been installed to start"
+ elog "VBoxClient in desktop sessions."
+ elog ""
+ elog "You can mount shared folders with:"
+ elog " mount -t vboxsf <shared_folder_name> <mount_point>"
+ elog ""
+ elog "Warning:"
+ elog "this ebuild is only needed if you are running gentoo"
+ elog "inside a VirtualBox Virtual Machine, you don't need"
+ elog "it to run VirtualBox itself."
+ elog ""
+}
diff --git a/app-emulation/virtualbox-modules/Manifest b/app-emulation/virtualbox-modules/Manifest
index 2b5a3be2..3ea54f8b 100644
--- a/app-emulation/virtualbox-modules/Manifest
+++ b/app-emulation/virtualbox-modules/Manifest
@@ -1 +1,2 @@
DIST vbox-kernel-module-src-5.1.22.tar.xz 620064 SHA256 e4d92a9cc6eb677d75364cb09f7e47360f80fb80f434caea2cc65b25853f94c4 SHA512 e38f67cc36bdb5b98546816eb66ad29b5b93830afa12e850ae00aae4382acd13e1a25d9c7f3e8bfb5e42636499798c95eb632c599ab96e51c55e0a77fa693e73 WHIRLPOOL c90c86e2c4c78c82f25c3c97d6efc13d5f098bd6266ad4f7b5a62f79d0dc2c2a823ec955b0d58d72aa363475b2ff784634b50742be40fc801f62707928e405b7
+DIST vbox-kernel-module-src-5.1.24.tar.xz 625508 SHA256 279e8ac5d5342896c63fd94dfe04d2462f759318b1dfc9eb3a617fbf8cc5e683 SHA512 2a2de8b4b328234470ed5f2209d792efef0c81251c20e45c13b923865fe5855d76512f17f8727daa17c10b09306748f70c1ec588a027c31645f7c676f96fca4c WHIRLPOOL eeaea483c46e0533053aff80af1f990fbaaeb073c7fbe535ec8425be6e73840c332dc3f22ccb0b6cd3b0f05a24fd206beb50dcdf8edf0245f4fa5be957bbb8d7
diff --git a/app-emulation/virtualbox-modules/virtualbox-modules-5.1.24-r1706.ebuild b/app-emulation/virtualbox-modules/virtualbox-modules-5.1.24-r1706.ebuild
new file mode 100644
index 00000000..e8b50e38
--- /dev/null
+++ b/app-emulation/virtualbox-modules/virtualbox-modules-5.1.24-r1706.ebuild
@@ -0,0 +1,36 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit eutils user
+
+MY_P=vbox-kernel-module-src-${PV}
+DESCRIPTION="Kernel Modules for Virtualbox"
+HOMEPAGE="http://www.virtualbox.org/"
+SRC_URI="https://dev.gentoo.org/~polynomial-c/virtualbox/${MY_P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE=""
+
+DEPEND="=sys-kernel/${PN}-dkms-${PV}"
+RDEPEND="${DEPEND}
+ !=app-emulation/virtualbox-9999"
+
+S=${WORKDIR}
+
+pkg_setup() {
+ enewgroup vboxusers
+}
+
+src_compile() {
+ :
+}
+
+src_install() {
+ insinto /usr/lib/modules-load.d/
+ doins "${FILESDIR}"/virtualbox.conf
+}
diff --git a/app-emulation/virtualbox/Manifest b/app-emulation/virtualbox/Manifest
index 842a00c8..cc07e9ec 100644
--- a/app-emulation/virtualbox/Manifest
+++ b/app-emulation/virtualbox/Manifest
@@ -1,2 +1,3 @@
DIST VirtualBox-5.1.22.tar.bz2 115838360 SHA256 fcc918000b8c5ece553541ec10a9182410a742b7266257c76dda895dcd389899 SHA512 e48457371c9139fc04477c82fbd18974378fde08af2a6f9058a0eafa6e522987bd129b8d87c9f381789c4e817aded752fde6ea7fcb2ade471997373802e09348 WHIRLPOOL c6034aad69c8a25eaf5909b6889f04f8090ace562e18a76bc55ad4d3e8347844fa1ab466d32e92b09180dff71e0f928826db0994d34b03f44b11bdb03ccc40d2
+DIST VirtualBox-5.1.24.tar.bz2 116135442 SHA256 ee2db169a322bf0db3c3b6d8b84aa39236f36cbf37d0a4c10ab65902a396bb60 SHA512 3c9ad230a53f9159e648ae1f342bdb220ffd85f2ddd45ae4c61d6606f358e9343a4968b2a91784893fb1284288ad41c538b1ab299b3a49e7739bfc8c4fdea910 WHIRLPOOL aad73184e2d36928449e688fd86c6f42c061f77e86c7e6119a205154b307846ed25175f49e3f8e451844b48c0e71e9531902753f1fd917123c401ffbf7744a2d
DIST virtualbox-5.1.18-patches-01.tar.xz 4512 SHA256 1aa525a8230f77abc672e61bea76af9ddfbb8f22acf21ef382b7a0a88de92764 SHA512 f1c88dd9b7fbafb9764df0a88dc5615aa78a01408d0a14c0dae33e3a53bd75c191c0181934848e17f5fd77784f9e01bf44b444f1485fc302cb1538c2e8ddac95 WHIRLPOOL c11adda0297cc18f0ac614a3492c411413bf640090c9cdb4c5382c4da0391734c479d92c2933e46e0dc8ccf59e155ce35e72182abcb5015a7e03ec33d51c1ab0
diff --git a/app-emulation/virtualbox/virtualbox-5.1.24-r1706.ebuild b/app-emulation/virtualbox/virtualbox-5.1.24-r1706.ebuild
new file mode 100644
index 00000000..35574cec
--- /dev/null
+++ b/app-emulation/virtualbox/virtualbox-5.1.24-r1706.ebuild
@@ -0,0 +1,459 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python2_7 )
+inherit eutils fdo-mime flag-o-matic java-pkg-opt-2 linux-info multilib pax-utils python-single-r1 toolchain-funcs udev
+
+MY_PV="${PV/beta/BETA}"
+MY_PV="${MY_PV/rc/RC}"
+MY_P=VirtualBox-${MY_PV}
+SRC_URI="http://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2
+ https://dev.gentoo.org/~polynomial-c/${PN}/patchsets/${PN}-5.1.18-patches-01.tar.xz"
+S="${WORKDIR}/${MY_P}"
+
+DESCRIPTION="Family of powerful x86 virtualization products for enterprise and home use"
+HOMEPAGE="http://www.virtualbox.org/"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="alsa debug doc headless java libressl lvm pam pax_kernel pulseaudio +opengl python +qt5 +sdk +udev vboxwebsrv vnc"
+
+RDEPEND="!app-emulation/virtualbox-bin
+ ~app-emulation/virtualbox-modules-${PV}
+ dev-libs/libIDL
+ >=dev-libs/libxslt-1.1.19
+ net-misc/curl
+ dev-libs/libxml2
+ media-libs/libpng:0=
+ media-libs/libvpx:0=
+ sys-libs/zlib
+ !headless? (
+ media-libs/libsdl:0[X,video]
+ x11-libs/libX11
+ x11-libs/libXcursor
+ x11-libs/libXext
+ x11-libs/libXmu
+ x11-libs/libXt
+ opengl? ( virtual/opengl media-libs/freeglut )
+ qt5? (
+ dev-qt/qtcore:5
+ dev-qt/qtgui:5
+ dev-qt/qtprintsupport:5
+ dev-qt/qtwidgets:5
+ dev-qt/qtx11extras:5
+ opengl? ( dev-qt/qtopengl:5 )
+ x11-libs/libXinerama
+ )
+ )
+ java? ( >=virtual/jre-1.6:= )
+ libressl? ( dev-libs/libressl:= )
+ !libressl? ( dev-libs/openssl:0= )
+ lvm? ( sys-fs/lvm2 )
+ udev? ( >=virtual/udev-171 )
+ vnc? ( >=net-libs/libvncserver-0.9.9 )"
+DEPEND="${RDEPEND}
+ >=dev-util/kbuild-0.1.9998_pre20131130-r1
+ >=dev-lang/yasm-0.6.2
+ sys-devel/bin86
+ sys-libs/libcap
+ sys-power/iasl
+ virtual/pkgconfig
+ alsa? ( >=media-libs/alsa-lib-1.0.13 )
+ doc? (
+ app-text/docbook-sgml-dtd:4.4
+ dev-texlive/texlive-basic
+ dev-texlive/texlive-latex
+ dev-texlive/texlive-latexrecommended
+ dev-texlive/texlive-latexextra
+ dev-texlive/texlive-fontsrecommended
+ dev-texlive/texlive-fontsextra
+ )
+ !headless? ( x11-libs/libXinerama )
+ java? ( >=virtual/jre-1.6:= )
+ pam? ( sys-libs/pam )
+ pax_kernel? ( sys-apps/elfix )
+ pulseaudio? ( media-sound/pulseaudio )
+ qt5? ( dev-qt/linguist-tools:5 )
+ vboxwebsrv? ( net-libs/gsoap[-gnutls(-)] )
+ ${PYTHON_DEPS}"
+
+QA_TEXTRELS_x86="usr/lib/virtualbox-ose/VBoxGuestPropSvc.so
+ usr/lib/virtualbox/VBoxSDL.so
+ usr/lib/virtualbox/VBoxSharedFolders.so
+ usr/lib/virtualbox/VBoxDD2.so
+ usr/lib/virtualbox/VBoxOGLrenderspu.so
+ usr/lib/virtualbox/VBoxPython.so
+ usr/lib/virtualbox/VBoxDD.so
+ usr/lib/virtualbox/VBoxDDU.so
+ usr/lib/virtualbox/VBoxREM64.so
+ usr/lib/virtualbox/VBoxSharedClipboard.so
+ usr/lib/virtualbox/VBoxHeadless.so
+ usr/lib/virtualbox/VBoxRT.so
+ usr/lib/virtualbox/VBoxREM.so
+ usr/lib/virtualbox/VBoxSettings.so
+ usr/lib/virtualbox/VBoxKeyboard.so
+ usr/lib/virtualbox/VBoxSharedCrOpenGL.so
+ usr/lib/virtualbox/VBoxVMM.so
+ usr/lib/virtualbox/VirtualBox.so
+ usr/lib/virtualbox/VBoxOGLhosterrorspu.so
+ usr/lib/virtualbox/components/VBoxC.so
+ usr/lib/virtualbox/components/VBoxSVCM.so
+ usr/lib/virtualbox/components/VBoxDDU.so
+ usr/lib/virtualbox/components/VBoxRT.so
+ usr/lib/virtualbox/components/VBoxREM.so
+ usr/lib/virtualbox/components/VBoxVMM.so
+ usr/lib/virtualbox/VBoxREM32.so
+ usr/lib/virtualbox/VBoxPython2_7.so
+ usr/lib/virtualbox/VBoxXPCOMC.so
+ usr/lib/virtualbox/VBoxOGLhostcrutil.so
+ usr/lib/virtualbox/VBoxNetDHCP.so
+ usr/lib/virtualbox/VBoxNetNAT.so"
+
+REQUIRED_USE="
+ java? ( sdk )
+ python? ( sdk )
+ vboxwebsrv? ( java )
+ ${PYTHON_REQUIRED_USE}
+"
+
+pkg_setup() {
+ if ! use headless && ! use qt5 ; then
+ einfo "No USE=\"qt5\" selected, this build will not include any Qt frontend."
+ elif use headless && use qt5 ; then
+ einfo "You selected USE=\"headless qt5\", defaulting to"
+ einfo "USE=\"headless\", this build will not include any X11/Qt frontend."
+ fi
+
+ if ! use opengl ; then
+ einfo "No USE=\"opengl\" selected, this build will lack"
+ einfo "the OpenGL feature."
+ fi
+ if ! use python ; then
+ einfo "You have disabled the \"python\" USE flag. This will only"
+ einfo "disable the python bindings being installed."
+ fi
+ java-pkg-opt-2_pkg_setup
+ python-single-r1_pkg_setup
+
+ tc-ld-disable-gold #bug 488176
+ tc-export CC CXX LD AR RANLIB
+ export HOST_CC="$(tc-getBUILD_CC)"
+}
+
+src_prepare() {
+ # Remove shipped binaries (kBuild,yasm), see bug #232775
+ rm -r kBuild/bin tools || die
+
+ # Replace pointless GCC version check with something less stupid.
+ # This is needed for the qt5 version check.
+ sed -e 's@^check_gcc$@cc_maj="$(gcc -dumpversion | cut -d. -f1)" ; cc_min="$(gcc -dumpversion | cut -d. -f2)"@' -i configure || die
+
+ # Don't use "echo -n"
+ sed 's@ECHO_N="echo -n"@ECHO_N="printf"@' -i configure || die
+
+ # Disable things unused or split into separate ebuilds
+ sed -e "s@MY_LIBDIR@$(get_libdir)@" \
+ "${FILESDIR}"/${PN}-5-localconfig > LocalConfig.kmk || die
+
+ # Respect LDFLAGS
+ sed -e "s@_LDFLAGS\.${ARCH}*.*=@& ${LDFLAGS}@g" \
+ -i Config.kmk src/libs/xpcom18a4/Config.kmk || die
+
+ # Do not use hard-coded ld (related to bug #488176)
+ sed -e '/QUIET)ld /s@ld @$(LD) @' \
+ -i src/VBox/Devices/PC/ipxe/Makefile.kmk || die
+
+ # Use PAM only when pam USE flag is enbaled (bug #376531)
+ if ! use pam ; then
+ elog "Disabling PAM removes the possibility to use the VRDP features."
+ sed -i 's@^.*VBOX_WITH_PAM@#VBOX_WITH_PAM@' Config.kmk || die
+ sed -i 's@\(.*/auth/Makefile.kmk.*\)@#\1@' \
+ src/VBox/HostServices/Makefile.kmk || die
+ fi
+
+ # add correct java path
+ if use java ; then
+ sed "s@/usr/lib/jvm/java-6-sun@$(java-config -O)@" \
+ -i "${S}"/Config.kmk || die
+ java-pkg-opt-2_src_prepare
+ fi
+
+ # Only add nopie patch when we're on hardened
+ if ! gcc-specs-pie ; then
+ rm "${WORKDIR}"/patches/050_${PN}-*-nopie.patch || die
+ fi
+
+ # Only add paxmark patch when we're on pax_kernel
+ if use pax_kernel ; then
+ epatch "${FILESDIR}"/virtualbox-5.1.4-paxmark-bldprogs.patch || die
+ fi
+
+ eapply "${WORKDIR}/patches"
+
+ eapply_user
+}
+
+src_configure() {
+ local myconf=(
+ --with-gcc="$(tc-getCC)"
+ --with-g++="$(tc-getCXX)"
+ --disable-dbus
+ --disable-kmods
+ )
+ use alsa || myconf+=( --disable-alsa )
+ use debug && myconf+=( --build-debug )
+ use doc || myconf+=( --disable-docs )
+ use java || myconf+=( --disable-java )
+ use lvm || myconf+=( --disable-devmapper )
+ use opengl || myconf+=( --disable-opengl )
+ use pulseaudio || myconf+=( --disable-pulse )
+ use python || myconf+=( --disable-python )
+ use vboxwebsrv && myconf+=( --enable-webservice )
+ use vnc && myconf+=( --enable-vnc )
+ if ! use headless ; then
+ use qt5 || myconf+=( --disable-qt )
+ else
+ myconf+=( --build-headless --disable-opengl )
+ fi
+ if use amd64 && ! has_multilib_profile ; then
+ myconf+=( --disable-vmmraw )
+ fi
+ # not an autoconf script
+ ./configure ${myconf[@]} || die "configure failed"
+}
+
+src_compile() {
+ source ./env.sh || die
+
+ # Force kBuild to respect C[XX]FLAGS and MAKEOPTS (bug #178529)
+ MAKEJOBS=$(grep -Eo '(\-j|\-\-jobs)(=?|[[:space:]]*)[[:digit:]]+' <<< ${MAKEOPTS}) #'
+ MAKELOAD=$(grep -Eo '(\-l|\-\-load-average)(=?|[[:space:]]*)[[:digit:]]+' <<< ${MAKEOPTS}) #'
+ MAKEOPTS="${MAKEJOBS} ${MAKELOAD}"
+ MAKE="kmk" emake \
+ VBOX_BUILD_PUBLISHER=_Gentoo \
+ TOOL_GCC3_CC="$(tc-getCC)" TOOL_GCC3_CXX="$(tc-getCXX)" \
+ TOOL_GCC3_AS="$(tc-getCC)" TOOL_GCC3_AR="$(tc-getAR)" \
+ TOOL_GCC3_LD="$(tc-getCXX)" TOOL_GCC3_LD_SYSMOD="$(tc-getLD)" \
+ TOOL_GCC3_CFLAGS="${CFLAGS}" TOOL_GCC3_CXXFLAGS="${CXXFLAGS}" \
+ VBOX_GCC_OPT="${CXXFLAGS}" \
+ TOOL_YASM_AS=yasm KBUILD_VERBOSE=2 \
+ all
+}
+
+src_install() {
+ local binpath="release"
+ use debug && binpath="debug"
+ cd "${S}"/out/linux.${ARCH}/${binpath}/bin || die
+
+ local vbox_inst_path="/usr/$(get_libdir)/${PN}" each fwfile size ico icofile
+
+ vbox_inst() {
+ local binary="${1}"
+ local perms="${2:-0750}"
+ local path="${3:-${vbox_inst_path}}"
+
+ [[ -n "${binary}" ]] || die "vbox_inst: No binray given!"
+ [[ ${perms} =~ ^[[:digit:]]+{4}$ ]] || die "vbox_inst: perms must consist of four digits."
+
+ insinto ${path}
+ doins ${binary}
+ fowners root:vboxusers ${path}/${binary}
+ fperms ${perms} ${path}/${binary}
+ }
+
+ # Create configuration files
+ insinto /etc/vbox
+ newins "${FILESDIR}/${PN}-4-config" vbox.cfg
+
+ # Set the correct libdir
+ sed \
+ -e "s@MY_LIBDIR@$(get_libdir)@" \
+ -i "${D}"/etc/vbox/vbox.cfg || die "vbox.cfg sed failed"
+
+ # Install the wrapper script
+ exeinto ${vbox_inst_path}
+ newexe "${FILESDIR}/${PN}-ose-5-wrapper" "VBox"
+ fowners root:vboxusers ${vbox_inst_path}/VBox
+ fperms 0750 ${vbox_inst_path}/VBox
+
+ # Install binaries and libraries
+ insinto ${vbox_inst_path}
+ doins -r components
+
+ # *.rc files for x86_64 are only available on multilib systems
+ local rcfiles="*.rc"
+ if use amd64 && ! has_multilib_profile ; then
+ rcfiles=""
+ fi
+ for each in VBox{ExtPackHelperApp,Manage,SVC,Tunctl,XPCOMIPCD} *so *r0 ${rcfiles} ; do
+ vbox_inst ${each}
+ done
+
+ # These binaries need to be suid root.
+ for each in VBox{Headless,Net{AdpCtl,DHCP,NAT}} ; do
+ vbox_inst ${each} 4750
+ done
+
+ # Install EFI Firmware files (bug #320757)
+ pushd "${S}"/src/VBox/Devices/EFI/FirmwareBin &>/dev/null || die
+ for fwfile in VBoxEFI{32,64}.fd ; do
+ vbox_inst ${fwfile} 0644
+ done
+ popd &>/dev/null || die
+
+ # VBoxSVC and VBoxManage need to be pax-marked (bug #403453)
+ # VBoxXPCOMIPCD (bug #524202)
+ for each in VBox{Headless,Manage,SVC,XPCOMIPCD} ; do
+ pax-mark -m "${D}"${vbox_inst_path}/${each}
+ done
+
+ # Symlink binaries to the shipped wrapper
+ for each in vbox{headless,manage} VBox{Headless,Manage,VRDP} ; do
+ dosym ${vbox_inst_path}/VBox /usr/bin/${each}
+ done
+ dosym ${vbox_inst_path}/VBoxTunctl /usr/bin/VBoxTunctl
+
+ # VRDPAuth only works with this (bug #351949)
+ dosym VBoxAuth.so ${vbox_inst_path}/VRDPAuth.so
+
+ # set an env-variable for 3rd party tools
+ echo -n "VBOX_APP_HOME=${vbox_inst_path}" > "${T}/90virtualbox"
+ doenvd "${T}/90virtualbox"
+
+ if ! use headless ; then
+ vbox_inst VBoxSDL 4750
+ pax-mark -m "${D}"${vbox_inst_path}/VBoxSDL
+
+ for each in vboxsdl VBoxSDL ; do
+ dosym ${vbox_inst_path}/VBox /usr/bin/${each}
+ done
+
+ if use qt5 ; then
+ vbox_inst VirtualBox 4750
+ pax-mark -m "${D}"${vbox_inst_path}/VirtualBox
+
+ if use opengl ; then
+ vbox_inst VBoxTestOGL
+ pax-mark -m "${D}"${vbox_inst_path}/VBoxTestOGL
+ fi
+
+ for each in virtualbox VirtualBox ; do
+ dosym ${vbox_inst_path}/VBox /usr/bin/${each}
+ done
+
+ insinto /usr/share/${PN}
+ doins -r nls
+
+ newmenu "${FILESDIR}"/${PN}-ose.desktop-2 ${PN}.desktop
+ fi
+
+ pushd "${S}"/src/VBox/Artwork/OSE &>/dev/null || die
+ for size in 16 32 48 64 128 ; do
+ newicon -s ${size} ${PN}-${size}px.png ${PN}.png
+ done
+ newicon ${PN}-48px.png ${PN}.png
+ doicon -s scalable ${PN}.svg
+ popd &>/dev/null || die
+ pushd "${S}"/src/VBox/Artwork/other &>/dev/null || die
+ for size in 16 24 32 48 64 72 96 128 256 512 ; do
+ for ico in hdd ova ovf vbox{,-extpack} vdi vdh vmdk ; do
+ icofile="${PN}-${ico}-${size}px.png"
+ if [[ -f "${icofile}" ]] ; then
+ newicon -s ${size} ${icofile} ${PN}-${ico}.png
+ fi
+ done
+ done
+ popd &>/dev/null || die
+ fi
+
+ if use lvm ; then
+ vbox_inst VBoxVolInfo 4750
+ dosym ${vbox_inst_path}/VBoxVolInfo /usr/bin/VBoxVolInfo
+ fi
+
+ if use sdk ; then
+ insinto ${vbox_inst_path}
+ doins -r sdk
+
+ if use java ; then
+ java-pkg_regjar "${D}${vbox_inst_path}/sdk/bindings/xpcom/java/vboxjxpcom.jar"
+ java-pkg_regso "${D}${vbox_inst_path}/libvboxjxpcom.so"
+ fi
+ fi
+
+ if use udev ; then
+ # New way of handling USB device nodes for VBox (bug #356215)
+ local udevdir="$(get_udevdir)"
+ insinto ${udevdir}
+ doins VBoxCreateUSBNode.sh
+ fowners root:vboxusers ${udevdir}/VBoxCreateUSBNode.sh
+ fperms 0750 ${udevdir}/VBoxCreateUSBNode.sh
+ insinto ${udevdir}/rules.d
+ sed "s@%UDEVDIR%@${udevdir}@" "${FILESDIR}"/10-virtualbox.rules \
+ > "${T}"/10-virtualbox.rules || die
+ doins "${T}"/10-virtualbox.rules
+ fi
+
+ if use vboxwebsrv ; then
+ vbox_inst vboxwebsrv
+ dosym ${vbox_inst_path}/VBox /usr/bin/vboxwebsrv
+ newinitd "${FILESDIR}"/vboxwebsrv-initd vboxwebsrv
+ newconfd "${FILESDIR}"/vboxwebsrv-confd vboxwebsrv
+ fi
+
+ if use doc ; then
+ dodoc UserManual.pdf
+ fi
+}
+
+pkg_postinst() {
+ fdo-mime_desktop_database_update
+
+ if use udev ; then
+ udevadm control --reload-rules \
+ && udevadm trigger --subsystem-match=usb
+ fi
+
+ if ! use headless && use qt5 ; then
+ elog "To launch VirtualBox just type: \"virtualbox\"."
+ fi
+ elog "You must be in the vboxusers group to use VirtualBox."
+ elog ""
+ elog "The latest user manual is available for download at:"
+ elog "http://download.virtualbox.org/virtualbox/${PV}/UserManual.pdf"
+ elog ""
+ elog "For advanced networking setups you should emerge:"
+ elog "net-misc/bridge-utils and sys-apps/usermode-utilities"
+ elog ""
+ elog "IMPORTANT!"
+ elog "If you upgrade from app-emulation/virtualbox-ose make sure to run"
+ elog "\"env-update\" as root and logout and relogin as the user you wish"
+ elog "to run ${PN} as."
+ elog ""
+ elog "Starting with version 4.0.0, ${PN} has USB-1 support."
+ elog "For USB-2 support, PXE-boot ability and VRDP support please emerge"
+ elog " app-emulation/virtualbox-extpack-oracle"
+ elog "package."
+ elog "Starting with version 5.0.0, ${PN} no longer has the \"additions\" and"
+ elog "the \"extension\" USE flag. For installation of the guest additions ISO"
+ elog "image, please emerge"
+ elog " app-emulation/virtualbox-additions"
+ elog "and for the USB2, USB3, VRDP and PXE boot ROM modules, please emerge"
+ elog " app-emulation/virtualbox-extpack-oracle"
+ if ! use udev ; then
+ elog ""
+ elog "WARNING!"
+ elog "Without USE=udev, USB devices will likely not work in ${PN}."
+ elif [ -e "${ROOT%/}/etc/udev/rules.d/10-virtualbox.rules" ] ; then
+ elog ""
+ elog "Please remove \"${ROOT%/}/etc/udev/rules.d/10-virtualbox.rules\""
+ elog "or else USB in ${PN} won't work."
+ fi
+}
+
+pkg_postrm() {
+ fdo-mime_desktop_database_update
+}
diff --git a/sys-kernel/virtualbox-guest-dkms/Manifest b/sys-kernel/virtualbox-guest-dkms/Manifest
index af81e8f2..219bc3f5 100644
--- a/sys-kernel/virtualbox-guest-dkms/Manifest
+++ b/sys-kernel/virtualbox-guest-dkms/Manifest
@@ -1 +1,2 @@
DIST virtualbox-guest-dkms-5.1.22-2-x86_64.pkg.tar.xz 576452 SHA256 d3a2bb61b2a50eb7e8c7bca49620ef685850d7299e476ee632db6a2650e549cd SHA512 35f4adb4c7e84c094879a8974f4f943bdc56738ff8801fc9e77511738c53577c68d10a9588847433b71fd216b152cccdd4cd7f6b6a1ab42e09a85c89ccfcc863 WHIRLPOOL 8d8890657640d495d055b5bb7271561a13844c25b525de061b0ef8003f23e5a0dae38af4eeed92c4253fb2f0b6b313f9f3cddacfefdfe7e1ed9424baac51c3d8
+DIST virtualbox-guest-dkms-5.1.24-1-x86_64.pkg.tar.xz 582460 SHA256 6d20aa1783dfef7ecdba00cabeebd15db146b58e936265815a5fdf22e93d1a65 SHA512 56b81d433f0e5ce39217368e9a9e720e8b678d4e3c971e9cf0894bf587aa207d9d2c5089113428eaa038b6c2530d3d0bd8a22703a3614ee3c1ff32f7c69c1b01 WHIRLPOOL e3d5205b9d2ad334b412b1d1d0789a9026b71e2e69868e1f9bfd2afd8ad246f57b435bbb7f15375194649aaeba0e825bdaee8c170a4c9bfd99cc5c3b0fce481e
diff --git a/sys-kernel/virtualbox-guest-dkms/files/dkms.patch b/sys-kernel/virtualbox-guest-dkms/files/dkms.patch
index d935cf1f..e9d2e3a9 100644
--- a/sys-kernel/virtualbox-guest-dkms/files/dkms.patch
+++ b/sys-kernel/virtualbox-guest-dkms/files/dkms.patch
@@ -6,9 +6,9 @@ diff -Nur a/dkms.conf b/dkms.conf
#
-PACKAGE_NAME="vboxguest"
--PACKAGE_VERSION=5.1.22_OSE
+-PACKAGE_VERSION=5.1.24_OSE
+PACKAGE_NAME="virtualbox-guest-dkms"
-+PACKAGE_VERSION=5.1.22
++PACKAGE_VERSION=5.1.24
AUTOINSTALL=yes
BUILT_MODULE_NAME[0]="vboxguest"
diff --git a/sys-kernel/virtualbox-guest-dkms/virtualbox-guest-dkms-5.1.24-r1706.ebuild b/sys-kernel/virtualbox-guest-dkms/virtualbox-guest-dkms-5.1.24-r1706.ebuild
new file mode 100644
index 00000000..c4823e9c
--- /dev/null
+++ b/sys-kernel/virtualbox-guest-dkms/virtualbox-guest-dkms-5.1.24-r1706.ebuild
@@ -0,0 +1,43 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit eutils
+
+DESCRIPTION="Kernel Modules (guest) source for Virtualbox"
+HOMEPAGE="http://www.virtualbox.org/"
+SRC_URI="http://mirror.archlinux.ro/archlinux/community/os/x86_64/${P}-1-x86_64.pkg.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE=""
+
+DEPEND="sys-kernel/dkms"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}"/usr/src/vboxguest-${PV}_OSE
+
+src_prepare() {
+ epatch ${FILESDIR}/dkms.patch
+}
+
+src_compile() {
+ :
+}
+
+src_install() {
+ dodir /usr/src/${P}
+ insinto /usr/src/${P}
+ doins -r ${S}/*
+}
+
+pkg_postinst() {
+ dkms add ${PN}/${PV}
+}
+
+pkg_prerm() {
+ dkms remove ${PN}/${PV} --all
+}
diff --git a/sys-kernel/virtualbox-modules-dkms/Manifest b/sys-kernel/virtualbox-modules-dkms/Manifest
index 2b5a3be2..3ea54f8b 100644
--- a/sys-kernel/virtualbox-modules-dkms/Manifest
+++ b/sys-kernel/virtualbox-modules-dkms/Manifest
@@ -1 +1,2 @@
DIST vbox-kernel-module-src-5.1.22.tar.xz 620064 SHA256 e4d92a9cc6eb677d75364cb09f7e47360f80fb80f434caea2cc65b25853f94c4 SHA512 e38f67cc36bdb5b98546816eb66ad29b5b93830afa12e850ae00aae4382acd13e1a25d9c7f3e8bfb5e42636499798c95eb632c599ab96e51c55e0a77fa693e73 WHIRLPOOL c90c86e2c4c78c82f25c3c97d6efc13d5f098bd6266ad4f7b5a62f79d0dc2c2a823ec955b0d58d72aa363475b2ff784634b50742be40fc801f62707928e405b7
+DIST vbox-kernel-module-src-5.1.24.tar.xz 625508 SHA256 279e8ac5d5342896c63fd94dfe04d2462f759318b1dfc9eb3a617fbf8cc5e683 SHA512 2a2de8b4b328234470ed5f2209d792efef0c81251c20e45c13b923865fe5855d76512f17f8727daa17c10b09306748f70c1ec588a027c31645f7c676f96fca4c WHIRLPOOL eeaea483c46e0533053aff80af1f990fbaaeb073c7fbe535ec8425be6e73840c332dc3f22ccb0b6cd3b0f05a24fd206beb50dcdf8edf0245f4fa5be957bbb8d7
diff --git a/sys-kernel/virtualbox-modules-dkms/virtualbox-modules-dkms-5.1.24-r1706.ebuild b/sys-kernel/virtualbox-modules-dkms/virtualbox-modules-dkms-5.1.24-r1706.ebuild
new file mode 100644
index 00000000..00923566
--- /dev/null
+++ b/sys-kernel/virtualbox-modules-dkms/virtualbox-modules-dkms-5.1.24-r1706.ebuild
@@ -0,0 +1,45 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit eutils
+
+MY_P=vbox-kernel-module-src-${PV}
+DESCRIPTION="Kernel Modules source for Virtualbox"
+HOMEPAGE="http://www.virtualbox.org/"
+SRC_URI="https://dev.gentoo.org/~polynomial-c/virtualbox/${MY_P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE=""
+
+DEPEND="sys-kernel/dkms"
+RDEPEND="${DEPEND}"
+
+S=${WORKDIR}
+
+src_prepare() {
+ grep -lR linux/autoconf.h * | xargs sed -i -e 's:<linux/autoconf.h>:<generated/autoconf.h>:'
+}
+
+src_compile() {
+ :
+}
+
+src_install() {
+ cp ${FILESDIR}/dkms.conf ${S}
+ dodir /usr/src/${P}
+ insinto /usr/src/${P}
+ doins -r ${S}/*
+}
+
+pkg_postinst() {
+ dkms add ${PN}/${PV}
+}
+
+pkg_prerm() {
+ dkms remove ${PN}/${PV} --all
+}
diff --git a/x11-drivers/xf86-video-virtualbox/Manifest b/x11-drivers/xf86-video-virtualbox/Manifest
index f9bb476c..9ae911ae 100644
--- a/x11-drivers/xf86-video-virtualbox/Manifest
+++ b/x11-drivers/xf86-video-virtualbox/Manifest
@@ -1 +1,2 @@
DIST VirtualBox-5.1.22.tar.bz2 115838360 SHA256 fcc918000b8c5ece553541ec10a9182410a742b7266257c76dda895dcd389899 SHA512 e48457371c9139fc04477c82fbd18974378fde08af2a6f9058a0eafa6e522987bd129b8d87c9f381789c4e817aded752fde6ea7fcb2ade471997373802e09348 WHIRLPOOL c6034aad69c8a25eaf5909b6889f04f8090ace562e18a76bc55ad4d3e8347844fa1ab466d32e92b09180dff71e0f928826db0994d34b03f44b11bdb03ccc40d2
+DIST VirtualBox-5.1.24.tar.bz2 116135442 SHA256 ee2db169a322bf0db3c3b6d8b84aa39236f36cbf37d0a4c10ab65902a396bb60 SHA512 3c9ad230a53f9159e648ae1f342bdb220ffd85f2ddd45ae4c61d6606f358e9343a4968b2a91784893fb1284288ad41c538b1ab299b3a49e7739bfc8c4fdea910 WHIRLPOOL aad73184e2d36928449e688fd86c6f42c061f77e86c7e6119a205154b307846ed25175f49e3f8e451844b48c0e71e9531902753f1fd917123c401ffbf7744a2d
diff --git a/x11-drivers/xf86-video-virtualbox/xf86-video-virtualbox-5.1.24-r1706.ebuild b/x11-drivers/xf86-video-virtualbox/xf86-video-virtualbox-5.1.24-r1706.ebuild
new file mode 100644
index 00000000..0b01d8ae
--- /dev/null
+++ b/x11-drivers/xf86-video-virtualbox/xf86-video-virtualbox-5.1.24-r1706.ebuild
@@ -0,0 +1,192 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python2_7 )
+inherit eutils multilib python-single-r1 versionator toolchain-funcs
+
+MY_PV="${PV/beta/BETA}"
+MY_PV="${MY_PV/rc/RC}"
+MY_P=VirtualBox-${MY_PV}
+DESCRIPTION="VirtualBox X11 video driver for Gentoo guest"
+HOMEPAGE="http://www.virtualbox.org/"
+SRC_URI="http://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="+dri"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+RDEPEND="
+ >=x11-base/xorg-server-1.7:=[-minimal]
+ x11-libs/libXcomposite
+ ${PYTHON_DEPS}"
+DEPEND="${RDEPEND}
+ >=dev-lang/yasm-0.6.2
+ >=dev-util/kbuild-0.1.9998_pre20131130
+ sys-power/iasl
+ x11-proto/fontsproto
+ x11-proto/randrproto
+ x11-proto/renderproto
+ x11-proto/resourceproto
+ x11-proto/scrnsaverproto
+ x11-proto/xextproto
+ x11-proto/xineramaproto
+ x11-proto/xproto
+ x11-libs/libXdmcp
+ x11-libs/libXau
+ x11-libs/libX11
+ x11-libs/libXfixes
+ x11-libs/libXext
+ dri? ( x11-proto/xf86driproto
+ >=x11-libs/libdrm-2.4.5 )"
+PDEPEND="dri? ( ~app-emulation/virtualbox-guest-additions-${PV} )"
+
+BUILD_TARGETS="all"
+BUILD_TARGET_ARCH="${ARCH}"
+S="${WORKDIR}/${MY_P}"
+MODULES_SRC_DIR="${S}/src/VBox/Additions/linux/drm"
+
+PATCHES=(
+ # Ugly hack to build the opengl part of the video driver
+ "${FILESDIR}/${PN}-2.2.0-enable-opengl.patch"
+
+ # unset useless/problematic checks in configure
+ "${FILESDIR}/${PN}-5.0.0_beta3-configure_checks.patch"
+
+ # xorg-1.19 patch from opensuse (bug #602784)
+ "${FILESDIR}/${PN}-5.1.10-xorg119.patch"
+)
+
+QA_TEXTRELS_x86="usr/lib/VBoxOGL.so"
+
+pkg_setup() {
+ if [ "${MERGE_TYPE}" != "binary" ]; then
+ version_is_at_least 4.9 $(gcc-version) || die "Please set gcc 4.9 or higher as active in gcc-config to build ${PN}"
+ fi
+
+ python-single-r1_pkg_setup
+}
+
+src_prepare() {
+ # Prepare the vboxvideo_drm Makefiles and build dir
+ eapply "${FILESDIR}"/${PN}-5.1.4-Makefile.module.kms.patch
+
+ # Remove shipped binaries (kBuild,yasm), see bug #232775
+ rm -r kBuild/bin tools || die
+
+ # Disable things unused or splitted into separate ebuilds
+ cp "${FILESDIR}/${PN}-5-localconfig" LocalConfig.kmk || die
+
+ # Remove pointless GCC version check
+ sed -e '/^check_gcc$/d' -i configure || die
+
+ default
+
+ # link with lazy on hardened #394757
+ sed '/^TEMPLATE_VBOXR3EXE_LDFLAGS.linux/s/$/ -Wl,-z,lazy/' \
+ -i Config.kmk || die
+}
+
+src_configure() {
+ # build the user-space tools, warnings are harmless
+ local cmd=(
+ ./configure
+ --nofatal
+ --disable-xpcom
+ --disable-sdl-ttf
+ --disable-pulse
+ --disable-alsa
+ --with-gcc="$(tc-getCC)"
+ --with-g++="$(tc-getCXX)"
+ --target-arch=${ARCH}
+ --with-linux="${KV_OUT_DIR}"
+ --build-headless
+ )
+ echo "${cmd[@]}"
+ "${cmd[@]}" || die "configure failed"
+ source ./env.sh
+ export VBOX_GCC_OPT="${CFLAGS} ${CPPFLAGS}"
+}
+
+src_compile() {
+ local each targets=(
+ Runtime
+ Additions/common/VBoxGuestLib
+ GuestHost/OpenGL
+ Additions/x11/x11stubs
+ Additions/common/crOpenGL
+ Additions/x11/vboxvideo
+ )
+
+ # need to use the upstream build system to create necessary objects properly
+ use dri && targets+=( Additions/linux/drm )
+
+ for each in ${targets[@]} ; do
+ pushd "${S}"/src/VBox/${each} &>/dev/null || die
+ MAKE="kmk" \
+ emake TOOL_YASM_AS=yasm \
+ VBOX_USE_SYSTEM_XORG_HEADERS=1 \
+ KBUILD_PATH="${S}/kBuild" \
+ KBUILD_VERBOSE=2
+ popd &>/dev/null || die
+ done
+
+ if use dri; then
+ local objdir="out/linux.${ARCH}/release/obj/vboxvideo_drm"
+ # We need a Makefile, so use Makefile.module.kms
+ ln -s Makefile.module.kms "${MODULES_SRC_DIR}"/Makefile || die
+ # All of these are expected to be in $(KBUILD_EXTMOD)/ so symlink them into place
+ targets=(
+ include
+ src/VBox/Runtime/r0drv
+ src/VBox/Installer/linux/Makefile.include.{head,foot}er
+ out/linux.${ARCH}/release/{product,version,revision}-generated.h
+ )
+ for each in ${targets[@]} ; do
+ ln -s "${S}"/${each} \
+ "${MODULES_SRC_DIR}"/${each##*/} || die
+ done
+ # see the vboxvideo_drm_SOURCES list in Makefile.kmk for the below,
+ # and replace '..' with 'dt'
+ targets=(
+ dt/dt/common/VBoxVideo/HGSMIBase.o
+ dt/dt/common/VBoxVideo/Modesetting.o
+ dt/dt/common/VBoxVideo/VBVABase.o
+ dt/dt/dt/GuestHost/HGSMI/HGSMICommon.o
+ dt/dt/dt/GuestHost/HGSMI/HGSMIMemAlloc.o
+ dt/dt/dt/Runtime/common/alloc/heapoffset.o
+ )
+ for each in ${targets[@]} ; do
+ ln -s "${S}"/${objdir}/${each} \
+ "${MODULES_SRC_DIR}" || die
+ ln -s "${S}"/${objdir}/${each}.dep \
+ "${MODULES_SRC_DIR}" || die
+ done
+ fi
+}
+
+src_install() {
+ cd "${S}/out/linux.${ARCH}/release/bin/additions" || die
+ insinto /usr/$(get_libdir)/xorg/modules/drivers
+ newins vboxvideo_drv_system.so vboxvideo_drv.so
+
+ # Guest OpenGL driver
+ insinto /usr/$(get_libdir)
+ doins -r VBoxOGL*
+
+ if use dri ; then
+ dosym /usr/$(get_libdir)/VBoxOGL.so \
+ /usr/$(get_libdir)/dri/vboxvideo_dri.so
+ fi
+}
+
+pkg_postinst() {
+ elog "You need to edit the file /etc/X11/xorg.conf and set:"
+ elog ""
+ elog " Driver \"vboxvideo\""
+ elog ""
+ elog "in the Graphics device section (Section \"Device\")"
+}