From 48bdeb0db9c7ffed22c6eb859ee40b55ba598b86 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Wed, 20 Dec 2017 11:17:21 +0000 Subject: gentoo resync : 20.12.2017 --- app-emulation/virtualbox/Manifest | 5 +- app-emulation/virtualbox/virtualbox-5.1.28.ebuild | 459 ---------------------- app-emulation/virtualbox/virtualbox-5.2.2.ebuild | 459 ++++++++++++++++++++++ 3 files changed, 462 insertions(+), 461 deletions(-) delete mode 100644 app-emulation/virtualbox/virtualbox-5.1.28.ebuild create mode 100644 app-emulation/virtualbox/virtualbox-5.2.2.ebuild (limited to 'app-emulation/virtualbox') diff --git a/app-emulation/virtualbox/Manifest b/app-emulation/virtualbox/Manifest index b19a8d18692e..ac0825eb3abe 100644 --- a/app-emulation/virtualbox/Manifest +++ b/app-emulation/virtualbox/Manifest @@ -8,11 +8,12 @@ AUX virtualbox-5.1.4-paxmark-bldprogs.patch 2642 BLAKE2B f8c25139dc58f6f2a9def4c AUX virtualbox-ose-5-wrapper 3405 BLAKE2B 92001ed3397a22abb5955617451bfb78d1f1f62f9be99cf87c57c42d118abb42b9436a0a83736d882b34360c9f8e67f9a8adaeffe7e9a3456c4ddc93a7850e53 SHA512 96f9ab8e2a83b5aebbb66916cbca0a7af0e2d69285296fe87869f096149791e0491dec2408f21f7249b68d928eebe396ab710a4ec6b6d6bc9c67120d323effa0 AUX virtualbox-ose.desktop-2 201 BLAKE2B 05fbf657e8c1d8ec46f1b88e681efd50a4e5ab2a0f32f3fd25ca956e1e9bff6357c69a96628e3eba26b01869b6dc596f68f739f9330fa3018c186dfa0fdcea06 SHA512 a678e237ad0451e8785f242ebf822b4f3b03d2e2280a62f71728f79bdcfc84d3465ee60cad90db75e64b2c89a1b0b224de00519728fb605df67ca7c9aee0874c DIST VirtualBox-5.1.26.tar.bz2 115915813 BLAKE2B c770420804fd0bcbe5582fccfefc55b6d69a603a99cc9ba26e72f6c1947a3e2bcbc5e9e1aa0185d544fb37b10db8233aa4c5cd14777138f63c2959a3ca5e6954 SHA512 680e9646a51a0a5923b3ded10007ee1c1e2a41c6d8a961d2b2540db6578bed2847154f4cac87e3cfe1118a62595b47c7df99da854f6c340e173b9eb8cacf2add -DIST VirtualBox-5.1.28.tar.bz2 116427658 BLAKE2B cf18e3677962b5ae5c32dade4a6054e3bc35d5b4a7422ee77529150a9a55893d88b0b5c73504caa9a7fa58d178788a6383ac933e818bc4e8b972d7f4ac6b8522 SHA512 5c21fd535424d7fd9adbb51894ec6d37ecf00a63a850362bd7b61fedca5031e096641814130a97ad839c0bd7089dc3dc465509615aab2af3c5735ff71005670a DIST VirtualBox-5.1.30.tar.bz2 116510730 BLAKE2B fe1d9ea37aa33a6aa6a78aebb469e267b9412e96cadc0a5287c263e8be21fdd0c9035a03e31ca954bef99eb5c05416de2bdfde5a657daa9a61eb795815d33542 SHA512 6c44d9593f4815644a484b306e621fe7eca224002f85d89c00f2470300f2c78dbfe50ffda61d2c2465df14ca77c70a2ab86f1a05116feeee9f5833857eb18dee +DIST VirtualBox-5.2.2.tar.bz2 118424845 BLAKE2B c918ff1d3989d2d94cec807b596b5daceece6388575f40c70b3581288be664e39cd0f0dae974516d1122110d5660185bac7bcf336418d8f44455290cafb52a7d SHA512 415956cfe987a20eb0a372288c29f0e388bd706a3b94ff69b92ef5bbf2e9aecd75761a56f5421ef97d165f756cd7fd46b9eaf16b74b7d2460b831d7f03aae7dc DIST virtualbox-5.1.24-patches-01.tar.xz 2708 BLAKE2B 6779a7ad1b013cf2e735817eae9785451c6a91e4a61558a650cfdc67d80b63db0eb33992a3207b0acc1e80b75caef14d9d291705ca7b3c96c4185c31e585e92d SHA512 0028e593818013f809831ac5a73eec63988c0aefb4b309fb3c928efbea8db8b8f46bd7c82f156396adc704f0567474df262dfe9bb6e09af0b2c23528fe2c6e2d DIST virtualbox-5.1.30-patches-02.tar.xz 2608 BLAKE2B 08b05a26622a7acec455f6d0dc72858f5f2758488e50d219f83c3d12606419d48e9d99302cde5a275929fe79af900c1b3ea3957fe9dfdaa952aaa0da9933291a SHA512 8a490f7cc44e40262fc47819736251c177adb635256794e9500f52729197c85211d5b0c0d000268089953a4c185872a8ba03c5d42df6b80f05eac8b81335320a +DIST virtualbox-5.2.0-patches-01.tar.xz 2460 BLAKE2B d3f973dc7ee0557c360f801c3bf84065a7e7bc9960984398b8f86d71fab32c59774e970c6cf873be07bcb9666af168570e8a78705a5999b1fc5d863dbbc6e538 SHA512 b91278dd81a50e412f5a281c72949f591a1c53303080549b74b28763cab9e3948948afb0256e0453d17736683cca3372a8e9c6d63f02f3eff3ef92c2a1ea332b EBUILD virtualbox-5.1.26.ebuild 13854 BLAKE2B 31cab7cbb9711d56ded8c764ad520031b813a3340ca5855504f73c81f6f55305df8052b0870f732ac5fbbd69d3aa0a523baf8d6b83ab914513f48970806af099 SHA512 565ae4bb7ab2139ea3ab8ae80f613ef758d60d1fb77599334276d46f3c30ad3c0ac5a6a54ab3c5e5fb78bfafdffe169418e6ddd6c45890ff7ff7b2e13b9d6b2b -EBUILD virtualbox-5.1.28.ebuild 13856 BLAKE2B b815e1bd8a9d3f606664a00250d2e64fba8402105ec49543a12b10cfc13393fc1cdb945cae01efdc0c18823b1137cff494ba2d41a2c9c594c6c407bf3993ccfc SHA512 5cef775577a33e0b2af3694d5c84667c5c6a58204b303620cd0404594f3e26f7b3a39bdb40099b0a4c003356cec1f6eb7ea103503cfe7f592522d00bae46c706 EBUILD virtualbox-5.1.30.ebuild 13856 BLAKE2B 31453b5457dd6246bfe4e6dcf45eabe1be6c87d9c8ec53e410bec175d2ee6c9f0480e0f744a68fc67fc193ba8832aafcbaf3345977f1ec5ce51e83b2dea71691 SHA512 c1fc12b4dd6079cec924a6703e00773f353daf888ebeefe3aa940c2aa32f6c6e3d1547c427eecbae10ec209608f6cdac8817994b4e18f6b92bd26cd2ca09eb26 +EBUILD virtualbox-5.2.2.ebuild 13845 BLAKE2B 2cd7c3030520556b792c82c0517fbc0f8a724da4b2faa6dacdebb8cdf6f57282ec45a324615c5b927cb40e9d4f99bc519fee73f6f618de0cbdbfc6c6f0a27884 SHA512 d03cae82af1b6065411f0f124b8aeab674d3864eaa02bd4da8c29d0788369f0960ad54e26e98673cde70f554a3ef5bc755735bbf14de7b3fdfa37e9e404537f0 MISC metadata.xml 950 BLAKE2B 98d5a25b631c928a86d8b716936c497aaba8f7bcbb0441c771acbf9998a89168bdfcb5d09e03d58e3403b3d90dd6acb611b1d47f4a0e4bf87a17c2f03ecc78ec SHA512 f09b74c1738a060749799ef652162824b40812de13558582cc660b57f1c379eb2d915ab53c1f2d55bb0c6cf4f917e0a6e55dabb5bde8b592a1eeaf34c3078363 diff --git a/app-emulation/virtualbox/virtualbox-5.1.28.ebuild b/app-emulation/virtualbox/virtualbox-5.1.28.ebuild deleted file mode 100644 index b9f8673f6fc6..000000000000 --- a/app-emulation/virtualbox/virtualbox-5.1.28.ebuild +++ /dev/null @@ -1,459 +0,0 @@ -# Copyright 1999-2017 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -PYTHON_COMPAT=( python2_7 ) -inherit eutils flag-o-matic java-pkg-opt-2 linux-info multilib pax-utils python-single-r1 toolchain-funcs udev xdg-utils - -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.24-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 - eapply "${FILESDIR}/050_virtualbox-5.1.24-nopie.patch" - fi - - # Only add paxmark patch when we're on pax_kernel - if use pax_kernel ; then - eapply "${FILESDIR}"/virtualbox-5.1.4-paxmark-bldprogs.patch - 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() { - xdg_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() { - xdg_desktop_database_update -} diff --git a/app-emulation/virtualbox/virtualbox-5.2.2.ebuild b/app-emulation/virtualbox/virtualbox-5.2.2.ebuild new file mode 100644 index 000000000000..f6ef3647989f --- /dev/null +++ b/app-emulation/virtualbox/virtualbox-5.2.2.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 flag-o-matic java-pkg-opt-2 linux-info multilib pax-utils python-single-r1 toolchain-funcs udev xdg-utils + +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.2.0-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.3127 + >=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 + eapply "${FILESDIR}/050_virtualbox-5.1.24-nopie.patch" + fi + + # Only add paxmark patch when we're on pax_kernel + if use pax_kernel ; then + eapply "${FILESDIR}"/virtualbox-5.1.4-paxmark-bldprogs.patch + 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() { + xdg_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() { + xdg_desktop_database_update +} -- cgit v1.2.3