diff options
author | Lars Wendler <polynomial-c@gentoo.org> | 2012-07-24 07:50:43 +0000 |
---|---|---|
committer | Lars Wendler <polynomial-c@gentoo.org> | 2012-07-24 07:50:43 +0000 |
commit | 4a37ba06d7b5a57a9aff01527b04a0437576b193 (patch) | |
tree | eacda415802c54fb296d964c2e8670e0073ed454 /app-emulation | |
parent | fix nss-ldapd to download the right version (diff) | |
download | historical-4a37ba06d7b5a57a9aff01527b04a0437576b193.tar.gz historical-4a37ba06d7b5a57a9aff01527b04a0437576b193.tar.bz2 historical-4a37ba06d7b5a57a9aff01527b04a0437576b193.zip |
Fixed crash when opening a VNC connection via IPv6 (bug #425698)
Package-Manager: portage-2.2.0_alpha120/cvs/Linux x86_64
Diffstat (limited to 'app-emulation')
-rw-r--r-- | app-emulation/virtualbox/ChangeLog | 9 | ||||
-rw-r--r-- | app-emulation/virtualbox/Manifest | 24 | ||||
-rw-r--r-- | app-emulation/virtualbox/files/virtualbox-4.1.18-ipv6_vnc.patch | 20 | ||||
-rw-r--r-- | app-emulation/virtualbox/virtualbox-4.1.18-r1.ebuild | 389 |
4 files changed, 440 insertions, 2 deletions
diff --git a/app-emulation/virtualbox/ChangeLog b/app-emulation/virtualbox/ChangeLog index 9d2ba9d7f848..637063c3f376 100644 --- a/app-emulation/virtualbox/ChangeLog +++ b/app-emulation/virtualbox/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for app-emulation/virtualbox # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-emulation/virtualbox/ChangeLog,v 1.114 2012/06/20 16:14:50 polynomial-c Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-emulation/virtualbox/ChangeLog,v 1.115 2012/07/24 07:50:43 polynomial-c Exp $ + +*virtualbox-4.1.18-r1 (24 Jul 2012) + + 24 Jul 2012; Lars Wendler <polynomial-c@gentoo.org> + +virtualbox-4.1.18-r1.ebuild, +files/virtualbox-4.1.18-ipv6_vnc.patch: + Fixed crash when opening a VNC connection via IPv6. Thanks to Mark + Zhitomirski for reporting this in bug #425698. *virtualbox-4.1.18 (20 Jun 2012) diff --git a/app-emulation/virtualbox/Manifest b/app-emulation/virtualbox/Manifest index bfd65da39876..44bfa76afaf1 100644 --- a/app-emulation/virtualbox/Manifest +++ b/app-emulation/virtualbox/Manifest @@ -1,3 +1,6 @@ +-----BEGIN PGP SIGNED MESSAGE----- +Hash: SHA256 + AUX 10-virtualbox.rules 576 SHA256 9fe8aaa16b42e6730a2ebd6cf0fbc9ad0db0f45e06e554cc4ae06b4dfc0045e1 SHA512 e3df0f2dc7530f32f9d6ae4fdb5f354ec1eadcfe3028709b3434ce1f0eb2fb2ad56df680890c02ecb6f18aba2d408f58a1a22b74a2eb20b24a262247a0b875ec WHIRLPOOL 3c067b317fec749e174614173f0840a8ecb285ffa1c4d72869b5baca5759bbef58cfa767cb844cc09a9b578baaf7c9e0bfea99e7b9e0b4cd4b87f675ee68fba1 AUX vboxwebsrv-confd 683 SHA256 57d15be05b11a5d2df838e144f3e91c6443b6afb6ea2c105254947be72759bc8 SHA512 cc1bfe93733cc06fcab5384f6fc6b0e88cfff93b07b6ea3ef5f8226bab24249ecf9c0f857568527ebd257d4e5be987b5699d26e09940dc221917daf58492b184 WHIRLPOOL d7cec4f07dfa53623106bc47100068b2552a99c2114e166fb33e32b0e4c8f9b3517c87d31e83c7cadb8375a1584a2c3a653bca0f4339955af6fc610f0d1ec88f AUX vboxwebsrv-initd 797 SHA256 51cafb25408343650ddcd8401ef0226c2df3cb5020a5ccdfd85e2de821a2ccf5 SHA512 60d2d1ad58e8f887d6a9b6a47a520ca84aa0e2e043571176bdc887ce76be063e443a980ea8f1b941394d533d69a434a1ca6a5c0cb8bd6b9cd4f38c1af2e10bbe WHIRLPOOL 3d22cef4e224738c504313a26e2c78915f49b42f4498309157e351805ceb8f6f9c25cea40dc51d4e58d6741b60c0206dc16ab9b48e26145ba2e6d5e41a91f266 @@ -8,6 +11,7 @@ AUX virtualbox-4-makeself-check.patch 289 SHA256 31ddafbeef6d35696d76de06988412f AUX virtualbox-4-mkisofs-check.patch 356 SHA256 0e72a5ef8d915c550fd92865b40c265153dc2d4621714a599d3a7172726b6fff SHA512 9c78927a4a8e99562582feef867f1b3e16663f04c88ebe7f19fd9e2e0c7632b041dc6294da57053645982040b50830f51391b27847467aac6e377062ca32997a WHIRLPOOL cd9ad5d9538467321b4ce56c37966f04edd2e74aaf1b849085675b1d08213b6a99179968adde9ad48aadb9ea67ca2f3283ef794be2f3ea6215ad4ff11031a778 AUX virtualbox-4.0.2-restore_old_machines_dir.patch 528 SHA256 0867e42e671245b5f9851a3221ffc321cd660a382d0df02878fe57898087cac0 SHA512 03b8b3f927eb368246252c56edc05e0845f5de60b0a0e8d6c3d66270dcd4775a2fd678c0e2a9ec3a33ac4199305ebdc9ee93312a9aa93b0400fbb2d712745949 WHIRLPOOL 8f2c951f929724f96f4bcd8dd93298e7d154644755c97fe9b22bb891d49215ed7b9851ba72d78b78342aee40e615ceb2d1b09841af543b5d58249e2f1227d273 AUX virtualbox-4.1.10-libgsoapssl.patch 529 SHA256 cf03f4ce1ce23d1c99a568e809c364946529fe874f8da332cc2595578355a022 SHA512 3c73acfcd656df80352e74d4fba9a80cb5cdb1c14365d61e5feddccdfa5e821ac2e65bd105052ba887b1a7193c3dbd838a47a70335b757036f744ce52596226b WHIRLPOOL 4eb564da9f6bd369cfef696609aa04c1f5bd6e03290e9d2019552c1e986365912e0c606473e1f47003cd463201549a4f904bbaf443d9ecd989f0df6259f484c2 +AUX virtualbox-4.1.18-ipv6_vnc.patch 840 SHA256 a9ebbf7bdd18449e09deba011303c066ff66402c8f50a6441912d409b64f3b93 SHA512 371cbd340a067f955fcfab0122b04f35ec756acd8794f0166e0bf7bf102bb23ca9aad21151912a7b938e2177bbe17f4375776a0c990b8c480dae234601e95a63 WHIRLPOOL a784042af1a4e24131547dcbe5a857bfd1550b0c63bd3470ba28df1066c937c903a4891be3e73f08f1560ab321149ffd5e63b3abda35e0f014eea44daba8d0db AUX virtualbox-4.1.2-vboxpci-build.patch 568 SHA256 5451a946acba9ebee24d0337cab36f1ec55d1a97f80d380f7ea13bfb2d944e6e SHA512 0fb36216f2262fd99fced3f9b242b5e4d7647db132f4b19552f66ffe6dbb9149127c3d002dae2102e0aadd517227b7c4c2edd73f1c8f1e4d4b6e452c85850def WHIRLPOOL b795f19d0e3affc010d406f06f4dcfe0e938aead8b1388b4d1604be61bc99060d14b848916a575b6f86153a1d271fb3effaf3d58c4671df11b3ee461667ff99e AUX virtualbox-4.1.4-asneeded.patch 490 SHA256 9a932f4a50c8f520429f632f83b8c1cf740e14ee12d9348c1bbee95e52998e35 SHA512 13f68c4717b719c8519f179442a8fe8c7c251a1545a9b6c89756b6daa08e5e7ebf5b6b1d83eba009c7e20b80df3c36a9e54b5ebf86c84c0abb184d0705972275 WHIRLPOOL b7ba57e07dc1da453c1fddb5c7ef2b0a7ba04741b9c0eccf1d3556951a1fa4d7bd3595eaf4b229f3417ead317a7d859e2c724964c5a4ca271bf5b00ef0e02a39 AUX virtualbox-4.1.6-yasm120-fix.patch 707 SHA256 2f073b45e796d7145c755ad7d92d58ce7255ede1d895e2f9f43d89687af0ce88 SHA512 855b217fc891c2deacf44bc22f8b343cdb6d6164bed7df256ae23ca2fcacf8a8ce092b53981e883cab0cf55e633a3c2097466651173073ab6c34b45f69d9f0c3 WHIRLPOOL 14a9dac54689fa4776ac55771412e0a83f9627908dc069832a28e76acb32b1858fd2f3ae96378149480bcde21f4ec5ce1d756daa3197b3ae13924f750003bc67 @@ -21,7 +25,25 @@ DIST VirtualBox-4.1.16.tar.bz2 73255692 SHA256 b670499804c718a8ebbc7c2ddee37f70e DIST VirtualBox-4.1.18.tar.bz2 73688436 SHA256 e650e4fdc23581b9edc0e5d5705cc596c76796851ebf65ccda0edb8e413fa3b7 SHA512 8053daaf45aa8ea4e56f7fc3b53b280ecbf184cb943ef574c7c1005557e762bcd626fe8b28693706c1c5385f497ea1baf39927b2cf83a09dc055076ec7bc8a3e WHIRLPOOL 0e232225431b230fd73e8d23bcdb23e413aa85fc336aa8af179f190c2b855b77057daa324ef1fcc5da08a75c51daa87f04beb97f03bdbd9ce2a270064debca78 EBUILD virtualbox-4.1.12.ebuild 12221 SHA256 3ec16a63075da6c70a8342f4cb4e95704e12910ac70208906debb5e303ab53ce SHA512 416647a0ce2b7b41510cbc0714160faa6bfa22ee8149daea15d975a0300125d27adab226b6b1f93f3de3706ee48fee92f7e776a1dad070d1534824e65ee1d147 WHIRLPOOL c198d9463342650cecbee614691a05b5973bc2eeab77ced773168ba51552669a21ebef2e1f735baefa544e62e0d1e7fe341aecbc3ab470035d515b4d0692cc6f EBUILD virtualbox-4.1.16.ebuild 12269 SHA256 45dc97e8caadf7f012ddfe5729c9d8f56123d9258b0541ef5eb9d8f7ffc4d40d SHA512 aa063ac4deb46ef6aacfd7533afc6e225844412afcbd17246737f6d91cf4336c1845f7c8f4a2dd0dd6e60542c3ec458f90d8862a29dd0d8c4eab04f7b3f43a0d WHIRLPOOL 1db2a8fc7b6579eca4247a9e2f0915b7eabadd05ccb0db5cdebee614ebff5501cd443dddc874ceb211d7cf73d1b1ad2deae8bdfd666cd7c1b96e7b964c2f8f98 +EBUILD virtualbox-4.1.18-r1.ebuild 12359 SHA256 c98c7212829657f847013359219c6fb2fcad4e397be4b4594c350676eae44605 SHA512 4e18c881acb9c4e995996e93e55404d2645227f0abb84cb52db1b8fea0e720daebf5a4b2c3c95fa74f8c34b9bbc7ad33ce2151325210d56ff059b4ae2149bf79 WHIRLPOOL c8c7aae83f266e6216d999a458cb57c4a7b371ad575137fbd864e7f90f2c567ce0a85a04036c9562f229ea3e0eef3c81d6905eac657031511e41eae6fba80d8a EBUILD virtualbox-4.1.18.ebuild 12274 SHA256 85b5c0f1b81245a20aebaac450c81eb00bf6b896bc97382fedf48e82122a78c3 SHA512 dbf0d7b3e5f16ec20e75e3aceb68c661d5394dce455d902bfadc85cde7daaca0f5f78500678b541a38964ab6aa28f002461039880c131e5816ae10487053f457 WHIRLPOOL d9da6eb1cee9da6d7ec6c9dc6547aefcb0bc8b7a23a46cbe76d82468147f9492f9bd83555aff13c3f03179364e4d7b3074c930dd7e7f4243f3879792979d5591 EBUILD virtualbox-9999.ebuild 5131 SHA256 fbbf430d655e4d58cf667a92aca03ca129163ca96a8b44defa86ab59481f004c SHA512 c737f49cfa6060ed9684764fbb57bca7fd8a4f420c623eff6e99b6d5abf8213784178a8a62a86a533789a5fc680c40fb820fc69d33db9028bf031104b438087c WHIRLPOOL 4492eeb296ced928519a8bd893a74b398d047015665c252a1b755b66f916344945ee5f8ec9b50108578119b965c65892a5cfc1c46f97b41f1e1360db68baa649 -MISC ChangeLog 13408 SHA256 f1241fc5f2775babe95c2ea1f07aba298d3f348ef9273bc081d045150eabd2c6 SHA512 4043f72f3c729f5afba587544521916c573b1d4cc4eee7cd6d8ad93e2e3a2b3279f59c9ef415484a6e813de37c6e470f2860793ad7371b481644112616812d81 WHIRLPOOL d052dbd1e12162d6fa20bff241456d6f9aba01159434206f9e2239d6f6e38ede4d717c88aa4948472e7efd8010f02b80cd2604d5493915868f9c9ad0867c75bc +MISC ChangeLog 13691 SHA256 22d6b2fd738f1d249cdf5050478e1478d486ce9c27d21d147518ba7971e3000d SHA512 b81a1057d3ba3516e6a75c2e5592ab6fc7aeefb665b80eff8b7a7e896d5c7651bff1773e822269224f3e8fcc119a2c3a59df398920f4210ecd94ee596c9a9ba8 WHIRLPOOL e89cb92e602ced6a02805ee4be8232c5f0ac48a2a39895dc318868dbe32cfc6e08b92b659d3fa5c244ac89b18a8c500260a7d71bb8ff8fe7908399030cd34954 MISC metadata.xml 766 SHA256 54cc5df43fbe674f4f04674566dfec523c0c912f8c94db26f4215727ab6850e5 SHA512 60fca14fc1e69c4385145e5390f202c57fe270537db31e5e7ca86ea77a1a6b30053dcdecb09dfa8386abd4e3776137028832fa188cda2d78ee42bed3189f2499 WHIRLPOOL ce722dc1c7248f0230bd298f4079945dba4271c6209c2d0c2cd9269748422b21bd69ae284354085120c6f6309d28c16dac4e35eb19cae64b2d49da3bb574c9ee +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.19 (GNU/Linux) + +iQIcBAEBCAAGBQJQDlPYAAoJEPiazRVxLXTFoYcP/R1TcbX9klBoolZok4O7lGYT ++nizrG5adeSXXKUED9c2/EydPGeY5iDFy7uz+szOtUtjRXcCh/xcUQyYuT7WIBQV ++7uyDCtnmhfvvhm5rLCCwf+QdL+oKkCkykc5DzlQUWJXcq8T/A+SZOFZJTJc5mid ++DqB6gE1aKoY5AGnsawtxPk1ZOuu0FfS9Xin5Mq9dKZjLaTNrwdkjLNPSol1drPL +GYH+2NWM2vcRVkxIbM46/QZGH8gOPLjI9NdnwStKkULSpR0iSQY7T6xZMWCavXhp +uGH7pVlQJBengypn5ENOQcf54RofNNiMabPPxKJYzSYK8rfO6HBDwFSotD23SlxK +5UsNp6b/E3ClJb+Dpxcs2G06+NRLv9JP+HyorAtOqicCOZft1Ek4MVnF8/kaBe96 +DmuJrCCXY3pim7/5FzGGuSX+0JD/kQrOa2+Pa2qI5tXueT0OazaXveR2NZg95dQr +3+7d4XqHrHNzHFA9zDFBZdKiKhhj3MsFlZSRDFtJEPfn501MgJBNXSQzSM+fw+Ky +et8l7TOZBd8ERo8EuesedlLn1yVHsXZ53HufiV+s95DaEQgb7bKCeSv2NA58dayU +M+LsRlaREpbw14RvUBVm5dPXA3QBQMDq2hblYMrVKOjWypZevFt62MtWG5Ozp9SA +O5j1zQ69b7DI5MwUiM1b +=pjy0 +-----END PGP SIGNATURE----- diff --git a/app-emulation/virtualbox/files/virtualbox-4.1.18-ipv6_vnc.patch b/app-emulation/virtualbox/files/virtualbox-4.1.18-ipv6_vnc.patch new file mode 100644 index 000000000000..8f50aba1c692 --- /dev/null +++ b/app-emulation/virtualbox/files/virtualbox-4.1.18-ipv6_vnc.patch @@ -0,0 +1,20 @@ +diff -aur vanilla/VirtualBox-4.1.18/src/VBox/Frontends/VBoxHeadless/FramebufferVNC.cpp changed/VirtualBox-4.1.18/src/VBox/Frontends/VBoxHeadless/FramebufferVNC.cpp +--- vanilla/VirtualBox-4.1.18/src/VBox/Frontends/VBoxHeadless/FramebufferVNC.cpp 2012-06-20 15:15:53.000000000 +0200 ++++ changed/VirtualBox-4.1.18/src/VBox/Frontends/VBoxHeadless/FramebufferVNC.cpp 2012-07-16 16:24:22.448349886 +0200 +@@ -88,8 +88,16 @@ + + vncServer = rfbGetScreen(0, NULL, mWidth, mHeight, 8, 3, 1); + vncServer->screenData = (void*)this; ++#ifdef LIBVNCSERVER_IPv6 ++ if (mVncPort) { ++ vncServer->port = mVncPort; ++ vncServer->ipv6port = mVncPort; ++ } ++#else + if (mVncPort) + vncServer->port = mVncPort; ++#endif ++ + char *pszDesktopName; + rc = RTStrAPrintf(&pszDesktopName, "%s - VirtualBox", pszName); + if (rc >= 0) diff --git a/app-emulation/virtualbox/virtualbox-4.1.18-r1.ebuild b/app-emulation/virtualbox/virtualbox-4.1.18-r1.ebuild new file mode 100644 index 000000000000..89ea9949b938 --- /dev/null +++ b/app-emulation/virtualbox/virtualbox-4.1.18-r1.ebuild @@ -0,0 +1,389 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-emulation/virtualbox/virtualbox-4.1.18-r1.ebuild,v 1.1 2012/07/24 07:50:43 polynomial-c Exp $ + +EAPI=4 + +inherit eutils fdo-mime flag-o-matic linux-info multilib pax-utils python qt4-r2 toolchain-funcs java-pkg-opt-2 + +if [[ ${PV} == "9999" ]] ; then + # XXX: should finish merging the -9999 ebuild into this one ... + ESVN_REPO_URI="http://www.virtualbox.org/svn/vbox/trunk" + inherit linux-mod subversion +else + MY_P=VirtualBox-${PV} + SRC_URI="http://download.virtualbox.org/virtualbox/${PV}/${MY_P}.tar.bz2" + S="${WORKDIR}/${MY_P}" +fi + +DESCRIPTION="Family of powerful x86 virtualization products for enterprise as well as home use" +HOMEPAGE="http://www.virtualbox.org/" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="+additions alsa doc extensions headless java pam pulseaudio +opengl python +qt4 +sdk 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/openssl + dev-libs/libxml2 + sys-libs/zlib + !headless? ( + qt4? ( + x11-libs/qt-gui:4 + x11-libs/qt-core:4 + opengl? ( x11-libs/qt-opengl:4 ) + x11-libs/libXinerama + ) + opengl? ( virtual/opengl media-libs/freeglut ) + x11-libs/libX11 + x11-libs/libXcursor + x11-libs/libXext + x11-libs/libXmu + x11-libs/libXt + media-libs/libsdl[X,video] + ) + vnc? ( >=net-libs/libvncserver-0.9.7 ) + java? ( || ( virtual/jre:1.7 virtual/jre:1.6 ) )" +DEPEND="${RDEPEND} + >=dev-util/kbuild-0.1.999 + >=dev-lang/yasm-0.6.2 + sys-devel/bin86 + sys-devel/dev86 + sys-power/iasl + media-libs/libpng + pam? ( sys-libs/pam ) + sys-libs/libcap + doc? ( + dev-texlive/texlive-basic + dev-texlive/texlive-latex + dev-texlive/texlive-latexrecommended + dev-texlive/texlive-latexextra + dev-texlive/texlive-fontsrecommended + dev-texlive/texlive-fontsextra + ) + java? ( || ( virtual/jdk:1.7 virtual/jdk:1.6 ) ) + virtual/pkgconfig + alsa? ( >=media-libs/alsa-lib-1.0.13 ) + !headless? ( x11-libs/libXinerama ) + pulseaudio? ( media-sound/pulseaudio ) + vboxwebsrv? ( >=net-libs/gsoap-2.7.13 )" +PDEPEND="additions? ( ~app-emulation/virtualbox-additions-${PV} ) + extensions? ( ~app-emulation/virtualbox-extpack-oracle-${PV} )" + +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_4.so + usr/lib/virtualbox/VBoxPython2_5.so + usr/lib/virtualbox/VBoxPython2_6.so + usr/lib/virtualbox/VBoxPython2_7.so + usr/lib/virtualbox/VBoxXPCOMC.so + usr/lib/virtualbox/VBoxOGLhostcrutil.so + usr/lib/virtualbox/VBoxNetDHCP.so" + +REQUIRED_USE=" + java? ( sdk ) + python? ( sdk ) + vboxwebsrv? ( java ) +" + +pkg_setup() { + if ! use headless && ! use qt4 ; then + einfo "No USE=\"qt4\" selected, this build will not include" + einfo "any Qt frontend." + elif use headless && use qt4 ; then + einfo "You selected USE=\"headless qt4\", 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 + java-pkg-opt-2_pkg_setup + python_set_active_version 2 + python_pkg_setup +} + +src_prepare() { + # Remove shipped binaries (kBuild,yasm), see bug #232775 + rm -rf kBuild/bin tools + + # Disable things unused or split into separate ebuilds + sed -e "s/MY_LIBDIR/$(get_libdir)/" \ + "${FILESDIR}"/${PN}-4-localconfig > LocalConfig.kmk || die + + # unset useless/problematic checks in configure + epatch "${FILESDIR}/${PN}-ose-3.2.8-mesa-check.patch" \ + "${FILESDIR}/${PN}-4-makeself-check.patch" \ + "${FILESDIR}/${PN}-4-mkisofs-check.patch" + + # fix build with --as-needed (bug #249295 and bug #350907) + epatch "${FILESDIR}/${PN}-4.1.4-asneeded.patch" + + # Respect LDFLAGS + sed -e "s/_LDFLAGS\.${ARCH}*.*=/& ${LDFLAGS}/g" \ + -i Config.kmk src/libs/xpcom18a4/Config.kmk || die + + # We still want to use ${HOME}/.VirtualBox/Machines as machines dir. + epatch "${FILESDIR}/${PN}-4.0.2-restore_old_machines_dir.patch" + + # Don't build vboxpci.ko module (D'oh!) + epatch "${FILESDIR}"/${PN}-4.1.2-vboxpci-build.patch + + # Fix VNC connection via IPv6 + epatch "${FILESDIR}"/${PN}-4.1.18-ipv6_vnc.patch + + # 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 + + # Fix compile error on hardened bug 339914 (disable PIE) + if gcc-specs-pie ; then + epatch "${FILESDIR}"/virtualbox_nopie.patch + fi +} + +src_configure() { + local myconf + use alsa || myconf+=" --disable-alsa" + use opengl || myconf+=" --disable-opengl" + use pulseaudio || myconf+=" --disable-pulse" + use python || myconf+=" --disable-python" + use java || myconf+=" --disable-java" + use vboxwebsrv && myconf+=" --enable-webservice" + use vnc && myconf+=" --enable-vnc" + use doc || myconf+=" --disable-docs" + if ! use headless ; then + use qt4 || myconf+=" --disable-qt4" + else + myconf+=" --build-headless --disable-opengl" + fi + # not an autoconf script + ./configure \ + --with-gcc="$(tc-getCC)" \ + --with-g++="$(tc-getCXX)" \ + --disable-kmods \ + --disable-dbus \ + ${myconf} \ + || die "configure failed" +} + +src_compile() { + source ./env.sh + + # Force kBuild to respect C[XX]FLAGS and MAKEOPTS (bug #178529) + # and strip all flags + # strip-flags + + MAKE="kmk" emake \ + VBOX_VERSION_STRING='$(VBOX_VERSION_MAJOR).$(VBOX_VERSION_MINOR).$(VBOX_VERSION_BUILD)'_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_PATH="${S}/kBuild" \ + all || die "kmk failed" +} + +src_install() { + cd "${S}"/out/linux.${ARCH}/release/bin || die + + # Create configuration files + insinto /etc/vbox + newins "${FILESDIR}/${PN}-4-config" vbox.cfg + + # Set the right libdir + sed -i \ + -e "s/MY_LIBDIR/$(get_libdir)/" \ + "${D}"/etc/vbox/vbox.cfg || die "vbox.cfg sed failed" + + # Symlink binaries to the shipped wrapper + exeinto /usr/$(get_libdir)/${PN} + newexe "${FILESDIR}/${PN}-ose-3-wrapper" "VBox" || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/VBox + fperms 0750 /usr/$(get_libdir)/${PN}/VBox + + dosym /usr/$(get_libdir)/${PN}/VBox /usr/bin/VBoxManage + dosym /usr/$(get_libdir)/${PN}/VBox /usr/bin/VBoxVRDP + dosym /usr/$(get_libdir)/${PN}/VBox /usr/bin/VBoxHeadless + dosym /usr/$(get_libdir)/${PN}/VBoxTunctl /usr/bin/VBoxTunctl + + # Install binaries and libraries + insinto /usr/$(get_libdir)/${PN} + doins -r components || die + + if use sdk ; then + doins -r sdk || die + fi + + if use vboxwebsrv ; then + doins vboxwebsrv || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/vboxwebsrv + fperms 0750 /usr/$(get_libdir)/${PN}/vboxwebsrv + dosym /usr/$(get_libdir)/${PN}/VBox /usr/bin/vboxwebsrv + newinitd "${FILESDIR}"/vboxwebsrv-initd vboxwebsrv + newconfd "${FILESDIR}"/vboxwebsrv-confd vboxwebsrv + fi + + for each in VBox{Manage,SVC,XPCOMIPCD,Tunctl,NetAdpCtl,NetDHCP,ExtPackHelperApp} *so *r0 *gc ; do + doins $each || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/${each} + fperms 0750 /usr/$(get_libdir)/${PN}/${each} + done + # VBoxNetAdpCtl and VBoxNetDHCP binaries need to be suid root in any case.. + fperms 4750 /usr/$(get_libdir)/${PN}/VBoxNetAdpCtl + fperms 4750 /usr/$(get_libdir)/${PN}/VBoxNetDHCP + + if ! use headless ; then + for each in VBox{SDL,Headless} ; do + doins $each || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/${each} + fperms 4750 /usr/$(get_libdir)/${PN}/${each} + pax-mark -m "${D}"/usr/$(get_libdir)/${PN}/${each} + done + + if use opengl && use qt4 ; then + doins VBoxTestOGL || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/VBoxTestOGL + fperms 0750 /usr/$(get_libdir)/${PN}/VBoxTestOGL + fi + + dosym /usr/$(get_libdir)/${PN}/VBox /usr/bin/VBoxSDL + + if use qt4 ; then + doins VirtualBox || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/VirtualBox + fperms 4750 /usr/$(get_libdir)/${PN}/VirtualBox + pax-mark -m "${D}"/usr/$(get_libdir)/${PN}/VirtualBox + + dosym /usr/$(get_libdir)/${PN}/VBox /usr/bin/VirtualBox + + newmenu "${FILESDIR}"/${PN}-ose.desktop-2 ${PN}.desktop + fi + + pushd "${S}"/src/VBox/Resources/OSE &>/dev/null || die + for size in 16 20 32 40 48 64 128 ; do + insinto /usr/share/icons/hicolor/${size}x${size}/apps + newins ${PN}-${size}px.png ${PN}.png + done + insinto /usr/share/pixmaps + newins ${PN}-48px.png ${PN}.png + popd &>/dev/null || die + else + doins VBoxHeadless || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/VBoxHeadless + fperms 4750 /usr/$(get_libdir)/${PN}/VBoxHeadless + pax-mark -m "${D}"/usr/$(get_libdir)/${PN}/VBoxHeadless + fi + + insinto /usr/$(get_libdir)/${PN} + # Install EFI Firmware files (bug #320757) + pushd "${S}"/src/VBox/Devices/EFI/FirmwareBin &>/dev/null || die + for fwfile in VBoxEFI{32,64}.fd ; do + doins ${fwfile} || die + fowners root:vboxusers /usr/$(get_libdir)/${PN}/${fwfile} || die + done + popd &>/dev/null || die + + # New way of handling USB device nodes for VBox (bug #356215) + insinto /lib/udev + doins VBoxCreateUSBNode.sh + fowners root:vboxusers /lib/udev/VBoxCreateUSBNode.sh + fperms 0750 /lib/udev/VBoxCreateUSBNode.sh + insinto /lib/udev/rules.d + doins "${FILESDIR}"/10-virtualbox.rules + + insinto /usr/share/${PN} + if ! use headless && use qt4 ; then + doins -r nls + fi + + # VRDPAuth only works with this (bug #351949) + dosym VBoxAuth.so /usr/$(get_libdir)/${PN}/VRDPAuth.so + + # set an env-variable for 3rd party tools + echo -n "VBOX_APP_HOME=/usr/$(get_libdir)/${PN}" > "${T}/90virtualbox" + doenvd "${T}/90virtualbox" + + if use java ; then + java-pkg_regjar "${D}/usr/$(get_libdir)/${PN}/sdk/bindings/xpcom/java/vboxjxpcom.jar" + java-pkg_regso "${D}/usr/$(get_libdir)/${PN}/libvboxjxpcom.so" + fi +} + +pkg_postinst() { + fdo-mime_desktop_database_update + + udevadm control --reload-rules && udevadm trigger --subsystem-match=usb + + if ! use headless && use qt4 ; 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." + if [ -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 +} |