Gentoo Archives: gentoo-commits

From: Lars Wendler <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-emulation/virtualbox-extpack-oracle/, app-emulation/virtualbox-bin/, ...
Date: Wed, 16 Jan 2019 11:43:18
Message-Id: 1547638986.f1378b8c7a40f6bb7f4c2dbaf25fdf983c817c5a.polynomial-c@gentoo
1 commit: f1378b8c7a40f6bb7f4c2dbaf25fdf983c817c5a
2 Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jan 16 11:42:47 2019 +0000
4 Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
5 CommitDate: Wed Jan 16 11:43:06 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f1378b8c
7
8 virtualbox packages: Bump to versions 5.2.24 and 6.0.2
9
10 Package-Manager: Portage-2.3.56, Repoman-2.3.12
11 Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
12
13 app-emulation/virtualbox-additions/Manifest | 2 +
14 .../virtualbox-additions-5.2.24.ebuild | 33 ++
15 .../virtualbox-additions-6.0.2.ebuild | 34 ++
16 app-emulation/virtualbox-bin/Manifest | 7 +
17 .../virtualbox-bin-5.2.24.128163.ebuild | 287 ++++++++++++
18 .../virtualbox-bin-6.0.2.128162.ebuild | 289 ++++++++++++
19 app-emulation/virtualbox-extpack-oracle/Manifest | 2 +
20 .../virtualbox-extpack-oracle-5.2.24.128163.ebuild | 42 ++
21 .../virtualbox-extpack-oracle-6.0.2.128162.ebuild | 43 ++
22 app-emulation/virtualbox-guest-additions/Manifest | 2 +
23 .../virtualbox-guest-additions-5.2.24.ebuild | 228 ++++++++++
24 .../virtualbox-guest-additions-6.0.2.ebuild | 229 ++++++++++
25 app-emulation/virtualbox-modules/Manifest | 2 +
26 .../virtualbox-modules-5.2.24.ebuild | 51 +++
27 .../virtualbox-modules-6.0.2.ebuild | 52 +++
28 app-emulation/virtualbox/Manifest | 2 +
29 app-emulation/virtualbox/virtualbox-5.2.24.ebuild | 480 ++++++++++++++++++++
30 app-emulation/virtualbox/virtualbox-6.0.2.ebuild | 483 +++++++++++++++++++++
31 18 files changed, 2268 insertions(+)
32
33 diff --git a/app-emulation/virtualbox-additions/Manifest b/app-emulation/virtualbox-additions/Manifest
34 index 1933d815dbc..d8aaa0e6715 100644
35 --- a/app-emulation/virtualbox-additions/Manifest
36 +++ b/app-emulation/virtualbox-additions/Manifest
37 @@ -1,2 +1,4 @@
38 DIST VBoxGuestAdditions_5.2.22.iso 58013696 BLAKE2B 196f0048b685200328bcf753f3df23eac6477ce863885e93a54951795368bf62bdaa497589001ec203d75809b1f74ebbaa80419406d26bc7db43a131f5b9d698 SHA512 b320174b2f2ef796ac2c9c920579be38f0cedaa037d21992863ac355ecf6e99ae2aea56c70fb2034e9e03afac2cd7297f7717b447a6981701755593110164d37
39 +DIST VBoxGuestAdditions_5.2.24.iso 58429440 BLAKE2B ee5b2751238da4372c4164c02e96c5bc6a1dbfb6670f7cd8912415680e99118e65c8f4c765c7d5f9dcf521644a011540e289357fe38e715d6264fa84b5d7ef1b SHA512 e05f75f3a5974efba6f64606d255a03ddf104deec3c300a9369c06d603aa3cbf70b73cdfeda2ce1fcd1c36da472bc190da0ed4e908bd6dbcf857104c99a61b05
40 DIST VBoxGuestAdditions_6.0.0.iso 79245312 BLAKE2B 413501b62bb6c8a0b1cef8255c631d4bc6c919b3a9c15e0fd780f6196e299f72ede083d51ca8f32bb83ec6d9384f1959c619bc5df67495a23bce503cf45c39e8 SHA512 4064bab634e8ebd75bc80c47ebd9a2596701505e15ebe872e1b599a42588ece307f90febfd474e429cd7e5e4ecf063bc7e37d666c6ae369f8f97b36a0e0ed81d
41 +DIST VBoxGuestAdditions_6.0.2.iso 85905408 BLAKE2B c5ce6d2cc3c15032f5d6733df72f938f2e5b0e996d467464e0229cfd8b8a2ba57f4f3878d94f769f0dfda48b14e426815925d883add6934a2c3f72ac1a41d6cb SHA512 53e82fbec7f1e04f473f0add3a0e03e2abfb9e88b57d7501d28310c36ae26af835d52a76104b31a8a4dc69ff31b6826c7c391622cdf3977df7ab7c4181d0e7dd
42
43 diff --git a/app-emulation/virtualbox-additions/virtualbox-additions-5.2.24.ebuild b/app-emulation/virtualbox-additions/virtualbox-additions-5.2.24.ebuild
44 new file mode 100644
45 index 00000000000..6faf7e7e8a0
46 --- /dev/null
47 +++ b/app-emulation/virtualbox-additions/virtualbox-additions-5.2.24.ebuild
48 @@ -0,0 +1,33 @@
49 +# Copyright 1999-2019 Gentoo Authors
50 +# Distributed under the terms of the GNU General Public License v2
51 +
52 +EAPI=7
53 +
54 +MY_PN=VBoxGuestAdditions
55 +MY_PV="${PV/beta/BETA}"
56 +MY_PV="${MY_PV/rc/RC}"
57 +MY_P=${MY_PN}_${MY_PV}
58 +
59 +DESCRIPTION="CD image containing guest additions for VirtualBox"
60 +HOMEPAGE="https://www.virtualbox.org/"
61 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.iso"
62 +
63 +LICENSE="GPL-2+ LGPL-2.1+ MIT SGI-B-2.0 CDDL"
64 +SLOT="0"
65 +KEYWORDS="~amd64 ~x86"
66 +IUSE=""
67 +RESTRICT="mirror"
68 +
69 +RDEPEND="!app-emulation/virtualbox-bin
70 + !=app-emulation/virtualbox-9999"
71 +
72 +S="${WORKDIR}"
73 +
74 +src_unpack() {
75 + return 0
76 +}
77 +
78 +src_install() {
79 + insinto /usr/share/${PN/-additions}
80 + newins "${DISTDIR}"/${MY_P}.iso ${MY_PN}.iso
81 +}
82
83 diff --git a/app-emulation/virtualbox-additions/virtualbox-additions-6.0.2.ebuild b/app-emulation/virtualbox-additions/virtualbox-additions-6.0.2.ebuild
84 new file mode 100644
85 index 00000000000..5124a818a15
86 --- /dev/null
87 +++ b/app-emulation/virtualbox-additions/virtualbox-additions-6.0.2.ebuild
88 @@ -0,0 +1,34 @@
89 +# Copyright 1999-2019 Gentoo Authors
90 +# Distributed under the terms of the GNU General Public License v2
91 +
92 +EAPI=7
93 +
94 +MY_PN=VBoxGuestAdditions
95 +MY_PV="${PV/beta/BETA}"
96 +MY_PV="${MY_PV/rc/RC}"
97 +MY_P=${MY_PN}_${MY_PV}
98 +
99 +DESCRIPTION="CD image containing guest additions for VirtualBox"
100 +HOMEPAGE="https://www.virtualbox.org/"
101 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.iso"
102 +
103 +LICENSE="GPL-2+ LGPL-2.1+ MIT SGI-B-2.0 CDDL"
104 +SLOT="0"
105 +[[ "${PV}" == *_beta* ]] || [[ "${PV}" == *_rc* ]] || \
106 +KEYWORDS="~amd64 ~x86"
107 +IUSE=""
108 +RESTRICT="mirror"
109 +
110 +RDEPEND="!app-emulation/virtualbox-bin
111 + !=app-emulation/virtualbox-9999"
112 +
113 +S="${WORKDIR}"
114 +
115 +src_unpack() {
116 + return 0
117 +}
118 +
119 +src_install() {
120 + insinto /usr/share/${PN/-additions}
121 + newins "${DISTDIR}"/${MY_P}.iso ${MY_PN}.iso
122 +}
123
124 diff --git a/app-emulation/virtualbox-bin/Manifest b/app-emulation/virtualbox-bin/Manifest
125 index ad378d6707d..3cb7a5e910d 100644
126 --- a/app-emulation/virtualbox-bin/Manifest
127 +++ b/app-emulation/virtualbox-bin/Manifest
128 @@ -1,7 +1,14 @@
129 DIST Oracle_VM_VirtualBox_Extension_Pack-5.2.22-126460.tar.gz 19640932 BLAKE2B 162ab40da6b2cd30d00e020666a1f4fb026e29af2ca9d6c36c294e5fa299b61ab8fd147f24d2b500426c768808db2c7693c30e88519e695d7759f8eedf1c52c5 SHA512 85b8552668b6580bea24f051ad861c82b9ba32177fb7fa37fe2980d8bab32a84325d02bfa9c8f55c2021a4000ef2546d8996ca8b99ca7fc19f8281a92108dfb0
130 +DIST Oracle_VM_VirtualBox_Extension_Pack-5.2.24-128163.tar.gz 19683939 BLAKE2B ce05e159172e34e1d520b3783d77db06aa8f91067cc743beb1eeafaf01508e830f5fe9501cb1f3a6d99492e3046ec2dd2fec94ffd39a237ef4679352492aaa1a SHA512 035103e420d773201ad24093910d7175a5d548f19de4a58900e78e2ebfac711851c99375977ba9fd47fced234346437164d226592b7070a867a1d13fd534a3b5
131 DIST Oracle_VM_VirtualBox_Extension_Pack-6.0.0-127566.tar.gz 23284806 BLAKE2B 4b34e1640ac74be3acc4cddc6140f77a2e5456ec29c6523fc2fe27c5e7c4652dd28f523b85a6cb17aab52e3594e68ee64cbe2c4cb8edd68f7deda05ed8b9e05d SHA512 cd8cd82bf9cea29f50101c8cccd0b8f699dcc4c4e7e720fe80df82154339b787d154a6376adc9d0f4a3015ec1ee2d67d6575ac5197dfda63af3f758294c165b8
132 +DIST Oracle_VM_VirtualBox_Extension_Pack-6.0.2-128162.tar.gz 23289693 BLAKE2B 13e1ad30b40676ed2e11cf26957377696a9f30a7a92bda0ca5f69039ffebe4abf3bb0224844609a29ac217b227e4d1906c70cd404d3967a26dc0ace3bf4d2ccd SHA512 29b682bf8130f73b25a82e97053847077d9eb48f0510db7fb0cf2e817e1e6b9a6e7ded54ede7447c56aa7b219d32a2d6ee19cb0efbe5c7e0a984c5e137fada51
133 DIST VirtualBox-5.2.22-126460-Linux_amd64.run 88821201 BLAKE2B 1b0433844247ee9531af915dcbb740183fa29fb296f8c78b4165cc3b48300da71f7d329026983da581ffff0d7b8976a2e5e32d5e948861a557ddfa2437813ea0 SHA512 22b20a68884a114818fcdfe9a459a7c3b1b3598526a74cc66407f5bcdc6eb6bcbe022b820477ccdc081e22349777b73fac9d6126585ee3c8fa0d3d24624006f3
134 DIST VirtualBox-5.2.22-126460-Linux_x86.run 87817677 BLAKE2B 5f11e5f92386c9524869082cf1a5af413c69fe5b36b1ace58887076000c7b928267eb7c3be22282885d6871ccdcee981ec79a526c71f281f0e8ada5858194851 SHA512 32d44b6d691e33a1ee1426cb7a3cb3648722709c588d177951b8be802546faadfd612567981bbbfed3d782b18260e6e638e7879813f3b06bb5a8387b052b0227
135 +DIST VirtualBox-5.2.24-128163-Linux_amd64.run 89282001 BLAKE2B affd8768878cf25209b7a53dc024ff1798d2c2e007031d40b39c5245df608cc09fdb19c216075b0ec7a4fd63ff580731b1b04838d5d6dc81bd126fed005ea355 SHA512 f22e3c71e5c3f923edc14fbae0191a5d1262426166984e19c784e2b0a332296f949d2a9eeca6972c1f16a0f9573c1f9807c556d4dab2bd500d5b73e22485c7e1
136 +DIST VirtualBox-5.2.24-128163-Linux_x86.run 88391118 BLAKE2B ffc44c55f664e4bc2c2e8bf09d95fda3631541b4b4b1dca7735dd5fcbf12da8258065fa13466ce23229126fb84b0193eee7cd794cf09f631ce124c4fd6558f16 SHA512 a7350a8266c6b3522be91158d765ce31b69acbfd67b6056a96361e0cb48926cee115c8f3df4d1965fd7b082d3f487f9f655253620a8357dbfadfbd2320ad6a3b
137 DIST VirtualBox-6.0.0-127566-Linux_amd64.run 148766154 BLAKE2B 2e23341dc798aabc1fd696422073516b6f2f70b9bee525ef22528b72abf38acf24599442e5c56d52c24af48f5ae6e2e6cdee981293fc644fac965cc34041a101 SHA512 19b11f7cf62288624739547755a7732b7d355ba61040c7e951ecbaf0ce75252075e8168aa41054e31fa36d45998f1ae1136b65d09981475a3052c4da7fd3021b
138 +DIST VirtualBox-6.0.2-128162-Linux_amd64.run 155114954 BLAKE2B 0159383d2bd3ed0e454e03db61d7466e06b63222da364ae8c8964ac418c2a5de6b78c320c989bc497e6fc98051434d3e480d1bd16e0f92f8ac2fde8a60af088e SHA512 10b0971b81158f80de918f5ae9e0261eaec23ac7b5b3a8117c7d757a3044559648860b70d5688b58bcda1d0bdd36b1df70d5d0c8c1a65c53e1a65112beba1fff
139 DIST VirtualBoxSDK-5.2.22-126460.zip 10154660 BLAKE2B e0a0106f695ca7198d4b2ac5c62bb435fe7934858115dcb3aed57b40d82655bd54cbbae63b279132c23762a227c53affe68131a0bf9452c69dcaf2162b1e4ebf SHA512 1d34b8f7f32602b5656fdb6184e6c35cc54d6ecb36bc41d7df3e154f18c27ea5938635969feb69defe86a53897eee87792514967f15810224ee89e8e523d2b29
140 +DIST VirtualBoxSDK-5.2.24-128163.zip 10153218 BLAKE2B e0a86462396eaa3fb9aa475ab40ee810874f61d3e9f37050b4aba36e6b5150e3699303b7f9989e32e794b9f67de4340ff008fa67339a3c45678005d126a17c27 SHA512 fbc12076ee968a6066f6ac81ff1555e10710d10d7821be24a4b4371a4f4b0409bed2d209904daa2b3f98a7998357558ca158bd76b87c5449815843312b669627
141 DIST VirtualBoxSDK-6.0.0-127566.zip 10749531 BLAKE2B 98a9d1d85a5d835e9a6d1ed121f6650d795a695bf40fb05af235eba6454237a79487f801d6351f3c446b523001271faac8cc09880522f97cae73360c1179edf5 SHA512 1f25b9249c5e1e0a7caee867b1508f517e16afd23055decfe27a513d1199ebc72bfcd391a8e750403ddb80a4087df7cfd928604b827976d7075829c7e3d82e00
142 +DIST VirtualBoxSDK-6.0.2-128162.zip 10753904 BLAKE2B 52824830e3d816df57932d8812a959dc3590eeabe8b7ba1dc8927d7eac7bea0c4584e0f2d62b405fdb8d5833fc93792dfcd7c2cfc2714237ecb8dbf26be36f11 SHA512 d7d1d60c7ffc4022de16dccc7786bbc4d481cef26e105932158955cc4350d65a6ac5bffa01a319baee5a64f4ae7d016ba50f82128bef6e11e54e72e82e73c168
143
144 diff --git a/app-emulation/virtualbox-bin/virtualbox-bin-5.2.24.128163.ebuild b/app-emulation/virtualbox-bin/virtualbox-bin-5.2.24.128163.ebuild
145 new file mode 100644
146 index 00000000000..e4f534871c4
147 --- /dev/null
148 +++ b/app-emulation/virtualbox-bin/virtualbox-bin-5.2.24.128163.ebuild
149 @@ -0,0 +1,287 @@
150 +# Copyright 1999-2019 Gentoo Authors
151 +# Distributed under the terms of the GNU General Public License v2
152 +
153 +EAPI=6
154 +
155 +PYTHON_COMPAT=( python2_7 )
156 +
157 +inherit xdg-utils gnome2 pax-utils python-r1 udev unpacker eapi7-ver
158 +
159 +MAIN_PV="$(ver_cut 1-3)"
160 +if [[ ${PV} = *_beta* ]] || [[ ${PV} = *_rc* ]] ; then
161 + MY_PV="${MAIN_PV}_$(ver_cut 5)"
162 + MY_PV="${MY_PV/beta/BETA}"
163 + MY_PV="${MY_PV/rc/RC}"
164 +else
165 + MY_PV="${MAIN_PV}"
166 +fi
167 +VBOX_BUILD_ID="$(ver_cut 4)"
168 +VBOX_PV="${MY_PV}-${VBOX_BUILD_ID}"
169 +MY_P="VirtualBox-${VBOX_PV}-Linux"
170 +# needed as sometimes the extpack gets another build ID
171 +EXTP_PV="${VBOX_PV}"
172 +EXTP_PN="Oracle_VM_VirtualBox_Extension_Pack"
173 +EXTP_P="${EXTP_PN}-${EXTP_PV}"
174 +# needed as sometimes the SDK gets another build ID
175 +SDK_PV="${VBOX_PV}"
176 +SDK_P="VirtualBoxSDK-${SDK_PV}"
177 +
178 +DESCRIPTION="Family of powerful x86 virtualization products for enterprise and home use"
179 +HOMEPAGE="https://www.virtualbox.org/"
180 +SRC_URI="amd64? ( https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}_amd64.run )
181 + x86? ( https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}_x86.run )
182 + https://download.virtualbox.org/virtualbox/${MY_PV}/${EXTP_P}.vbox-extpack -> ${EXTP_P}.tar.gz"
183 +
184 +LICENSE="GPL-2 PUEL"
185 +SLOT="0"
186 +KEYWORDS="~amd64 ~x86"
187 +IUSE="+additions +chm headless python vboxwebsrv rdesktop-vrdp"
188 +RESTRICT="mirror"
189 +
190 +if [[ "${PV}" != *beta* ]] ; then
191 + SRC_URI+="
192 + sdk? ( https://download.virtualbox.org/virtualbox/${MY_PV}/${SDK_P}.zip )"
193 + IUSE+=" sdk"
194 +fi
195 +
196 +DEPEND="app-arch/unzip
197 + ${PYTHON_DEPS}"
198 +
199 +RDEPEND="!!app-emulation/virtualbox
200 + !app-emulation/virtualbox-additions
201 + ~app-emulation/virtualbox-modules-${MAIN_PV}
202 + !headless? (
203 + dev-libs/glib
204 + media-libs/fontconfig
205 + media-libs/freetype
206 + media-libs/libpng
207 + media-libs/libsdl[X]
208 + x11-libs/libXcursor
209 + x11-libs/libXext
210 + x11-libs/libXfixes
211 + x11-libs/libXft
212 + x11-libs/libXi
213 + x11-libs/libXinerama
214 + x11-libs/libXrandr
215 + x11-libs/libXrender
216 + chm? ( dev-libs/expat )
217 + )
218 + dev-libs/libxml2
219 + sys-fs/lvm2
220 + x11-libs/libXau
221 + x11-libs/libX11
222 + x11-libs/libXt
223 + x11-libs/libXmu
224 + x11-libs/libSM
225 + x11-libs/libICE
226 + x11-libs/libXdmcp
227 + ${PYTHON_DEPS}"
228 +
229 +REQUIRED_USE="${PYTHON_REQUIRED_USE}"
230 +S="${WORKDIR}"
231 +
232 +QA_PREBUILT="opt/VirtualBox/*"
233 +
234 +PYTHON_UPDATER_IGNORE="1"
235 +
236 +src_unpack() {
237 + unpack_makeself ${MY_P}_${ARCH}.run
238 + unpack ./VirtualBox.tar.bz2
239 +
240 + mkdir "${S}"/${EXTP_PN} || die
241 + pushd "${S}"/${EXTP_PN} &>/dev/null || die
242 + unpack ${EXTP_P}.tar.gz
243 + popd &>/dev/null || die
244 +
245 + if [[ "${PV}" != *beta* ]] && use sdk ; then
246 + unpack VirtualBoxSDK-${SDK_PV}.zip
247 + fi
248 +}
249 +
250 +src_configure() {
251 + :;
252 +}
253 +
254 +src_compile() {
255 + :;
256 +}
257 +
258 +src_install() {
259 + # create virtualbox configurations files
260 + insinto /etc/vbox
261 + newins "${FILESDIR}/${PN}-config" vbox.cfg
262 +
263 + if ! use headless ; then
264 + newmenu "${FILESDIR}"/${PN}.desktop-2 ${PN}.desktop
265 +
266 + # set up symlinks (bug #572012)
267 + dosym ../../../../opt/VirtualBox/virtualbox.xml /usr/share/mime/packages/virtualbox.xml
268 +
269 + local size ico icofile
270 + for size in 16 24 32 48 64 72 96 128 256 ; do
271 + pushd "${S}"/icons/${size}x${size} &>/dev/null || die
272 + if [[ -f "virtualbox.png" ]] ; then
273 + doicon -s ${size} virtualbox.png
274 + fi
275 + for ico in hdd ova ovf vbox{,-extpack} vdi vdh vmdk ; do
276 + icofile="virtualbox-${ico}.png"
277 + if [[ -f "${icofile}" ]] ; then
278 + doicon -s ${size} ${icofile}
279 + fi
280 + done
281 + popd &>/dev/null || die
282 + done
283 + doicon -s scalable "${S}"/icons/scalable/virtualbox.svg
284 + insinto /usr/share/pixmaps
285 + newins "${S}"/icons/48x48/virtualbox.png ${PN}.png
286 + fi
287 +
288 + pushd "${S}"/${EXTP_PN} &>/dev/null || die
289 + insinto /opt/VirtualBox/ExtensionPacks/${EXTP_PN}
290 + doins -r linux.${ARCH}
291 + doins ExtPack* PXE-Intel.rom
292 + popd &>/dev/null || die
293 + rm -rf "${S}"/${EXTP_PN}
294 +
295 + insinto /opt/VirtualBox
296 + dodir /opt/bin
297 +
298 + doins UserManual.pdf
299 +
300 + if [[ "${PV}" != *beta* ]] && use sdk ; then
301 + doins -r sdk
302 + fi
303 +
304 + if use additions; then
305 + doins -r additions
306 + fi
307 +
308 + if use vboxwebsrv; then
309 + doins vboxwebsrv
310 + fowners root:vboxusers /opt/VirtualBox/vboxwebsrv
311 + fperms 0750 /opt/VirtualBox/vboxwebsrv
312 + dosym ../../opt/VirtualBox/VBox.sh /opt/bin/vboxwebsrv
313 + newinitd "${FILESDIR}"/vboxwebsrv-initd vboxwebsrv
314 + newconfd "${FILESDIR}"/vboxwebsrv-confd vboxwebsrv
315 + fi
316 +
317 + if use rdesktop-vrdp; then
318 + doins rdesktop-vrdp
319 + doins -r rdesktop-vrdp-keymaps
320 + fperms 0750 /opt/VirtualBox/rdesktop-vrdp
321 + dosym ../../opt/VirtualBox/rdesktop-vrdp /opt/bin/rdesktop-vrdp
322 + fi
323 +
324 + if ! use headless && use chm; then
325 + doins kchmviewer VirtualBox.chm
326 + fowners root:vboxusers /opt/VirtualBox/kchmviewer
327 + fperms 0750 /opt/VirtualBox/kchmviewer
328 + fi
329 +
330 + # This ebuild / package supports only py2.7. When py3 comes is unknown.
331 + # The compile phase makes VBoxPython2_7.so.
332 + # py3 support would presumably require a binary pre-compiled by py3.
333 + use python && doins VBoxPython.so VBoxPython2_7.so
334 +
335 + rm -rf src rdesktop* deffiles install* routines.sh runlevel.sh \
336 + vboxdrv.sh VBox.sh VBox.png vboxnet.sh additions VirtualBox.desktop \
337 + VirtualBox.tar.bz2 LICENSE VBoxSysInfo.sh rdesktop* vboxwebsrv \
338 + webtest kchmviewer VirtualBox.chm vbox-create-usb-node.sh \
339 + 90-vbox-usb.fdi uninstall.sh vboxshell.py vboxdrv-pardus.py \
340 + VBoxPython?_*.so
341 +
342 + if use headless ; then
343 + rm -rf VBoxSDL VirtualBox VBoxKeyboard.so
344 + fi
345 +
346 + doins -r * || die
347 +
348 + # create symlinks for working around unsupported $ORIGIN/.. in VBoxC.so (setuid)
349 + dosym ../VBoxVMM.so /opt/VirtualBox/components/VBoxVMM.so
350 + dosym ../VBoxREM.so /opt/VirtualBox/components/VBoxREM.so
351 + dosym ../VBoxRT.so /opt/VirtualBox/components/VBoxRT.so
352 + dosym ../VBoxDDU.so /opt/VirtualBox/components/VBoxDDU.so
353 + dosym ../VBoxXPCOM.so /opt/VirtualBox/components/VBoxXPCOM.so
354 +
355 + local each
356 + for each in VBox{Manage,SVC,XPCOMIPCD,Tunctl,NetAdpCtl,NetDHCP,NetNAT,TestOGL,ExtPackHelperApp}; do
357 + fowners root:vboxusers /opt/VirtualBox/${each}
358 + fperms 0750 /opt/VirtualBox/${each}
359 + pax-mark -m "${ED%/}"/opt/VirtualBox/${each}
360 + done
361 + # VBoxNetAdpCtl and VBoxNetDHCP binaries need to be suid root in any case..
362 + fperms 4750 /opt/VirtualBox/VBoxNetAdpCtl
363 + fperms 4750 /opt/VirtualBox/VBoxNetDHCP
364 + fperms 4750 /opt/VirtualBox/VBoxNetNAT
365 +
366 + if ! use headless ; then
367 + # Hardened build: Mark selected binaries set-user-ID-on-execution
368 + for each in VBox{SDL,Headless} VirtualBox; do
369 + fowners root:vboxusers /opt/VirtualBox/${each}
370 + fperms 4510 /opt/VirtualBox/${each}
371 + pax-mark -m "${ED%/}"/opt/VirtualBox/${each}
372 + done
373 +
374 + dosym ../VirtualBox/VBox.sh /opt/bin/VirtualBox
375 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxSDL
376 + else
377 + # Hardened build: Mark selected binaries set-user-ID-on-execution
378 + fowners root:vboxusers /opt/VirtualBox/VBoxHeadless
379 + fperms 4510 /opt/VirtualBox/VBoxHeadless
380 + pax-mark -m "${ED%/}"/opt/VirtualBox/VBoxHeadless
381 + fi
382 +
383 + exeinto /opt/VirtualBox
384 + newexe "${FILESDIR}/${PN}-3-wrapper" "VBox.sh"
385 + fowners root:vboxusers /opt/VirtualBox/VBox.sh
386 + fperms 0750 /opt/VirtualBox/VBox.sh
387 +
388 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxManage
389 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxVRDP
390 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxHeadless
391 + dosym ../VirtualBox/VBoxTunctl /opt/bin/VBoxTunctl
392 +
393 + # set an env-variable for 3rd party tools
394 + echo -n "VBOX_APP_HOME=/opt/VirtualBox" > "${T}/90virtualbox"
395 + doenvd "${T}/90virtualbox"
396 +
397 + local udevdir="$(get_udevdir)"
398 + insinto ${udevdir}/rules.d
399 + doins "${FILESDIR}"/10-virtualbox.rules
400 + sed "s@%UDEVDIR%@${udevdir}@" \
401 + -i "${ED%/}"${udevdir}/rules.d/10-virtualbox.rules || die
402 + # move udev scripts into ${udevdir} (bug #372491)
403 + mv "${ED%/}"/opt/VirtualBox/VBoxCreateUSBNode.sh "${ED%/}"${udevdir} || die
404 + fperms 0750 ${udevdir}/VBoxCreateUSBNode.sh
405 +}
406 +
407 +pkg_postinst() {
408 + xdg_desktop_database_update
409 +
410 + gnome2_icon_cache_update
411 +
412 + udevadm control --reload-rules && udevadm trigger --subsystem-match=usb
413 +
414 + elog ""
415 + if ! use headless ; then
416 + elog "To launch VirtualBox just type: \"VirtualBox\""
417 + elog ""
418 + fi
419 + elog "You must be in the vboxusers group to use VirtualBox."
420 + elog ""
421 + elog "For advanced networking setups you should emerge:"
422 + elog "net-misc/bridge-utils and sys-apps/usermode-utilities"
423 + elog ""
424 + elog "Please visit http://www.virtualbox.org/wiki/Editions for"
425 + elog "an overview about the different features of ${PN}"
426 + elog "and virtualbox-ose"
427 + if [ -e "${ROOT}/etc/udev/rules.d/10-virtualbox.rules" ] ; then
428 + elog ""
429 + elog "Please remove \"${ROOT}/etc/udev/rules.d/10-virtualbox.rules\""
430 + elog "or else USB in ${PN} won't work."
431 + fi
432 +}
433 +
434 +pkg_postrm() {
435 + xdg_desktop_database_update
436 +}
437
438 diff --git a/app-emulation/virtualbox-bin/virtualbox-bin-6.0.2.128162.ebuild b/app-emulation/virtualbox-bin/virtualbox-bin-6.0.2.128162.ebuild
439 new file mode 100644
440 index 00000000000..87181607960
441 --- /dev/null
442 +++ b/app-emulation/virtualbox-bin/virtualbox-bin-6.0.2.128162.ebuild
443 @@ -0,0 +1,289 @@
444 +# Copyright 1999-2019 Gentoo Authors
445 +# Distributed under the terms of the GNU General Public License v2
446 +
447 +EAPI=6
448 +
449 +PYTHON_COMPAT=( python2_7 )
450 +
451 +inherit xdg-utils gnome2 pax-utils python-r1 udev unpacker eapi7-ver
452 +
453 +MAIN_PV="$(ver_cut 1-3)"
454 +if [[ ${PV} = *_beta* ]] || [[ ${PV} = *_rc* ]] ; then
455 + MY_PV="${MAIN_PV}_$(ver_cut 5-6)"
456 + MY_PV="${MY_PV/beta/BETA}"
457 + MY_PV="${MY_PV/rc/RC}"
458 +else
459 + MY_PV="${MAIN_PV}"
460 + KEYWORDS="~amd64" #~x86
461 +fi
462 +VBOX_BUILD_ID="$(ver_cut 4)"
463 +VBOX_PV="${MY_PV}-${VBOX_BUILD_ID}"
464 +MY_P="VirtualBox-${VBOX_PV}-Linux"
465 +# needed as sometimes the extpack gets another build ID
466 +EXTP_PV="${VBOX_PV}"
467 +EXTP_PN="Oracle_VM_VirtualBox_Extension_Pack"
468 +EXTP_P="${EXTP_PN}-${EXTP_PV}"
469 +# needed as sometimes the SDK gets another build ID
470 +SDK_PV="${VBOX_PV}"
471 +SDK_P="VirtualBoxSDK-${SDK_PV}"
472 +
473 +DESCRIPTION="Family of powerful x86 virtualization products for enterprise and home use"
474 +HOMEPAGE="https://www.virtualbox.org/"
475 +SRC_URI="amd64? ( https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}_amd64.run )
476 + https://download.virtualbox.org/virtualbox/${MY_PV}/${EXTP_P}.vbox-extpack -> ${EXTP_P}.tar.gz"
477 + #x86? ( https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}_x86.run )
478 +
479 +LICENSE="GPL-2 PUEL"
480 +SLOT="0"
481 +IUSE="+additions +chm headless python vboxwebsrv rdesktop-vrdp"
482 +RESTRICT="mirror"
483 +
484 +if [[ "${PV}" != *beta* ]] ; then
485 + SRC_URI+="
486 + sdk? ( https://download.virtualbox.org/virtualbox/${MY_PV}/${SDK_P}.zip )"
487 + IUSE+=" sdk"
488 +fi
489 +
490 +DEPEND="app-arch/unzip
491 + ${PYTHON_DEPS}"
492 +
493 +RDEPEND="!!app-emulation/virtualbox
494 + !app-emulation/virtualbox-additions
495 + ~app-emulation/virtualbox-modules-${MAIN_PV}
496 + !headless? (
497 + dev-libs/glib
498 + media-libs/fontconfig
499 + media-libs/freetype
500 + media-libs/libpng
501 + media-libs/libsdl[X]
502 + x11-libs/libXcursor
503 + x11-libs/libXext
504 + x11-libs/libXfixes
505 + x11-libs/libXft
506 + x11-libs/libXi
507 + x11-libs/libXinerama
508 + x11-libs/libXrandr
509 + x11-libs/libXrender
510 + chm? ( dev-libs/expat )
511 + )
512 + dev-libs/libxml2
513 + sys-fs/lvm2
514 + x11-libs/libXau
515 + x11-libs/libX11
516 + x11-libs/libXt
517 + x11-libs/libXmu
518 + x11-libs/libSM
519 + x11-libs/libICE
520 + x11-libs/libXdmcp
521 + ${PYTHON_DEPS}"
522 +
523 +REQUIRED_USE="${PYTHON_REQUIRED_USE}"
524 +S="${WORKDIR}"
525 +
526 +QA_PREBUILT="opt/VirtualBox/*"
527 +
528 +PYTHON_UPDATER_IGNORE="1"
529 +
530 +src_unpack() {
531 + unpack_makeself ${MY_P}_${ARCH}.run
532 + unpack ./VirtualBox.tar.bz2
533 +
534 + mkdir "${S}"/${EXTP_PN} || die
535 + pushd "${S}"/${EXTP_PN} &>/dev/null || die
536 + unpack ${EXTP_P}.tar.gz
537 + popd &>/dev/null || die
538 +
539 + if [[ "${PV}" != *beta* ]] && use sdk ; then
540 + unpack VirtualBoxSDK-${SDK_PV}.zip
541 + fi
542 +}
543 +
544 +src_configure() {
545 + :;
546 +}
547 +
548 +src_compile() {
549 + :;
550 +}
551 +
552 +src_install() {
553 + # create virtualbox configurations files
554 + insinto /etc/vbox
555 + newins "${FILESDIR}/${PN}-config" vbox.cfg
556 +
557 + if ! use headless ; then
558 + newmenu "${FILESDIR}"/${PN}.desktop-2 ${PN}.desktop
559 +
560 + # set up symlinks (bug #572012)
561 + dosym ../../../../opt/VirtualBox/virtualbox.xml /usr/share/mime/packages/virtualbox.xml
562 +
563 + local size ico icofile
564 + for size in 16 24 32 48 64 72 96 128 256 ; do
565 + pushd "${S}"/icons/${size}x${size} &>/dev/null || die
566 + if [[ -f "virtualbox.png" ]] ; then
567 + doicon -s ${size} virtualbox.png
568 + fi
569 + for ico in hdd ova ovf vbox{,-extpack} vdi vdh vmdk ; do
570 + icofile="virtualbox-${ico}.png"
571 + if [[ -f "${icofile}" ]] ; then
572 + doicon -s ${size} ${icofile}
573 + fi
574 + done
575 + popd &>/dev/null || die
576 + done
577 + doicon -s scalable "${S}"/icons/scalable/virtualbox.svg
578 + insinto /usr/share/pixmaps
579 + newins "${S}"/icons/48x48/virtualbox.png ${PN}.png
580 + fi
581 +
582 + pushd "${S}"/${EXTP_PN} &>/dev/null || die
583 + insinto /opt/VirtualBox/ExtensionPacks/${EXTP_PN}
584 + doins -r linux.${ARCH}
585 + doins ExtPack* PXE-Intel.rom
586 + popd &>/dev/null || die
587 + rm -rf "${S}"/${EXTP_PN}
588 +
589 + insinto /opt/VirtualBox
590 + dodir /opt/bin
591 +
592 + doins UserManual.pdf
593 +
594 + if [[ "${PV}" != *beta* ]] && use sdk ; then
595 + doins -r sdk
596 + fi
597 +
598 + if use additions; then
599 + doins -r additions
600 + fi
601 +
602 + if use vboxwebsrv; then
603 + doins vboxwebsrv
604 + fowners root:vboxusers /opt/VirtualBox/vboxwebsrv
605 + fperms 0750 /opt/VirtualBox/vboxwebsrv
606 + dosym ../../opt/VirtualBox/VBox.sh /opt/bin/vboxwebsrv
607 + newinitd "${FILESDIR}"/vboxwebsrv-initd vboxwebsrv
608 + newconfd "${FILESDIR}"/vboxwebsrv-confd vboxwebsrv
609 + fi
610 +
611 + if use rdesktop-vrdp; then
612 + doins rdesktop-vrdp
613 + doins -r rdesktop-vrdp-keymaps
614 + fperms 0750 /opt/VirtualBox/rdesktop-vrdp
615 + dosym ../../opt/VirtualBox/rdesktop-vrdp /opt/bin/rdesktop-vrdp
616 + fi
617 +
618 + if ! use headless && use chm; then
619 + doins kchmviewer VirtualBox.chm
620 + fowners root:vboxusers /opt/VirtualBox/kchmviewer
621 + fperms 0750 /opt/VirtualBox/kchmviewer
622 + fi
623 +
624 + # This ebuild / package supports only py2.7. When py3 comes is unknown.
625 + # The compile phase makes VBoxPython2_7.so.
626 + # py3 support would presumably require a binary pre-compiled by py3.
627 + use python && doins VBoxPython.so
628 +
629 + rm -rf src rdesktop* deffiles install* routines.sh runlevel.sh \
630 + vboxdrv.sh VBox.sh VBox.png vboxnet.sh additions VirtualBox.desktop \
631 + VirtualBox.tar.bz2 LICENSE VBoxSysInfo.sh rdesktop* vboxwebsrv \
632 + webtest kchmviewer VirtualBox.chm vbox-create-usb-node.sh \
633 + 90-vbox-usb.fdi uninstall.sh vboxshell.py vboxdrv-pardus.py \
634 + VBoxPython?_*.so
635 +
636 + if use headless ; then
637 + rm -rf VBoxSDL VirtualBox{,VM} VBoxKeyboard.so
638 + fi
639 +
640 + doins -r * || die
641 +
642 + # create symlinks for working around unsupported $ORIGIN/.. in VBoxC.so (setuid)
643 + dosym ../VBoxVMM.so /opt/VirtualBox/components/VBoxVMM.so
644 + dosym ../VBoxREM.so /opt/VirtualBox/components/VBoxREM.so
645 + dosym ../VBoxRT.so /opt/VirtualBox/components/VBoxRT.so
646 + dosym ../VBoxDDU.so /opt/VirtualBox/components/VBoxDDU.so
647 + dosym ../VBoxXPCOM.so /opt/VirtualBox/components/VBoxXPCOM.so
648 +
649 + local each
650 + for each in VBox{Manage,SVC,XPCOMIPCD,Tunctl,TestOGL,ExtPackHelperApp} VirtualBox ; do
651 + fowners root:vboxusers /opt/VirtualBox/${each}
652 + fperms 0750 /opt/VirtualBox/${each}
653 + pax-mark -m "${ED%/}"/opt/VirtualBox/${each}
654 + done
655 + # VBoxNetAdpCtl and VBoxNetDHCP binaries need to be suid root in any case..
656 + for each in VBoxNet{AdpCtl,DHCP,NAT} VirtualBoxVM ; do
657 + fowners root:vboxusers /opt/VirtualBox/${each}
658 + fperms 4750 /opt/VirtualBox/${each}
659 + pax-mark -m "${ED%/}"/opt/VirtualBox/${each}
660 + done
661 +
662 + if ! use headless ; then
663 + # Hardened build: Mark selected binaries set-user-ID-on-execution
664 + for each in VBox{SDL,Headless} ; do
665 + fowners root:vboxusers /opt/VirtualBox/${each}
666 + fperms 4510 /opt/VirtualBox/${each}
667 + pax-mark -m "${ED%/}"/opt/VirtualBox/${each}
668 + done
669 +
670 + dosym ../VirtualBox/VBox.sh /opt/bin/VirtualBox
671 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxSDL
672 + else
673 + # Hardened build: Mark selected binaries set-user-ID-on-execution
674 + fowners root:vboxusers /opt/VirtualBox/VBoxHeadless
675 + fperms 4510 /opt/VirtualBox/VBoxHeadless
676 + pax-mark -m "${ED%/}"/opt/VirtualBox/VBoxHeadless
677 + fi
678 +
679 + exeinto /opt/VirtualBox
680 + newexe "${FILESDIR}/${PN}-3-wrapper" "VBox.sh"
681 + fowners root:vboxusers /opt/VirtualBox/VBox.sh
682 + fperms 0750 /opt/VirtualBox/VBox.sh
683 +
684 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxManage
685 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxVRDP
686 + dosym ../VirtualBox/VBox.sh /opt/bin/VBoxHeadless
687 + dosym ../VirtualBox/VBoxTunctl /opt/bin/VBoxTunctl
688 +
689 + # set an env-variable for 3rd party tools
690 + echo -n "VBOX_APP_HOME=/opt/VirtualBox" > "${T}/90virtualbox"
691 + doenvd "${T}/90virtualbox"
692 +
693 + local udevdir="$(get_udevdir)"
694 + insinto ${udevdir}/rules.d
695 + doins "${FILESDIR}"/10-virtualbox.rules
696 + sed "s@%UDEVDIR%@${udevdir}@" \
697 + -i "${ED%/}"${udevdir}/rules.d/10-virtualbox.rules || die
698 + # move udev scripts into ${udevdir} (bug #372491)
699 + mv "${ED%/}"/opt/VirtualBox/VBoxCreateUSBNode.sh "${ED%/}"${udevdir} || die
700 + fperms 0750 ${udevdir}/VBoxCreateUSBNode.sh
701 +}
702 +
703 +pkg_postinst() {
704 + xdg_desktop_database_update
705 +
706 + gnome2_icon_cache_update
707 +
708 + udevadm control --reload-rules && udevadm trigger --subsystem-match=usb
709 +
710 + elog ""
711 + if ! use headless ; then
712 + elog "To launch VirtualBox just type: \"VirtualBox\""
713 + elog ""
714 + fi
715 + elog "You must be in the vboxusers group to use VirtualBox."
716 + elog ""
717 + elog "For advanced networking setups you should emerge:"
718 + elog "net-misc/bridge-utils and sys-apps/usermode-utilities"
719 + elog ""
720 + elog "Please visit http://www.virtualbox.org/wiki/Editions for"
721 + elog "an overview about the different features of ${PN}"
722 + elog "and virtualbox-ose"
723 + if [ -e "${ROOT}/etc/udev/rules.d/10-virtualbox.rules" ] ; then
724 + elog ""
725 + elog "Please remove \"${ROOT}/etc/udev/rules.d/10-virtualbox.rules\""
726 + elog "or else USB in ${PN} won't work."
727 + fi
728 +}
729 +
730 +pkg_postrm() {
731 + xdg_desktop_database_update
732 +}
733
734 diff --git a/app-emulation/virtualbox-extpack-oracle/Manifest b/app-emulation/virtualbox-extpack-oracle/Manifest
735 index 20aad7da1fb..289cf748834 100644
736 --- a/app-emulation/virtualbox-extpack-oracle/Manifest
737 +++ b/app-emulation/virtualbox-extpack-oracle/Manifest
738 @@ -1,2 +1,4 @@
739 DIST Oracle_VM_VirtualBox_Extension_Pack-5.2.22-126460.tar.gz 19640932 BLAKE2B 162ab40da6b2cd30d00e020666a1f4fb026e29af2ca9d6c36c294e5fa299b61ab8fd147f24d2b500426c768808db2c7693c30e88519e695d7759f8eedf1c52c5 SHA512 85b8552668b6580bea24f051ad861c82b9ba32177fb7fa37fe2980d8bab32a84325d02bfa9c8f55c2021a4000ef2546d8996ca8b99ca7fc19f8281a92108dfb0
740 +DIST Oracle_VM_VirtualBox_Extension_Pack-5.2.24-128163.tar.gz 19683939 BLAKE2B ce05e159172e34e1d520b3783d77db06aa8f91067cc743beb1eeafaf01508e830f5fe9501cb1f3a6d99492e3046ec2dd2fec94ffd39a237ef4679352492aaa1a SHA512 035103e420d773201ad24093910d7175a5d548f19de4a58900e78e2ebfac711851c99375977ba9fd47fced234346437164d226592b7070a867a1d13fd534a3b5
741 DIST Oracle_VM_VirtualBox_Extension_Pack-6.0.0-127566.tar.gz 23284806 BLAKE2B 4b34e1640ac74be3acc4cddc6140f77a2e5456ec29c6523fc2fe27c5e7c4652dd28f523b85a6cb17aab52e3594e68ee64cbe2c4cb8edd68f7deda05ed8b9e05d SHA512 cd8cd82bf9cea29f50101c8cccd0b8f699dcc4c4e7e720fe80df82154339b787d154a6376adc9d0f4a3015ec1ee2d67d6575ac5197dfda63af3f758294c165b8
742 +DIST Oracle_VM_VirtualBox_Extension_Pack-6.0.2-128162.tar.gz 23289693 BLAKE2B 13e1ad30b40676ed2e11cf26957377696a9f30a7a92bda0ca5f69039ffebe4abf3bb0224844609a29ac217b227e4d1906c70cd404d3967a26dc0ace3bf4d2ccd SHA512 29b682bf8130f73b25a82e97053847077d9eb48f0510db7fb0cf2e817e1e6b9a6e7ded54ede7447c56aa7b219d32a2d6ee19cb0efbe5c7e0a984c5e137fada51
743
744 diff --git a/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.2.24.128163.ebuild b/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.2.24.128163.ebuild
745 new file mode 100644
746 index 00000000000..e598ba63811
747 --- /dev/null
748 +++ b/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-5.2.24.128163.ebuild
749 @@ -0,0 +1,42 @@
750 +# Copyright 1999-2019 Gentoo Authors
751 +# Distributed under the terms of the GNU General Public License v2
752 +
753 +EAPI=7
754 +
755 +inherit multilib
756 +
757 +MAIN_PV="$(ver_cut 1-3)"
758 +if [[ ${PV} = *_beta* ]] || [[ ${PV} = *_rc* ]] ; then
759 + MY_PV="${MAIN_PV}_$(ver_cut 5)"
760 + DEP_PV="${MY_PV}"
761 + MY_PV="${MY_PV/beta/BETA}"
762 + MY_PV="${MY_PV/rc/RC}"
763 +else
764 + MY_PV="${MAIN_PV}"
765 + DEP_PV="${MAIN_PV}"
766 +fi
767 +VBOX_BUILD_ID="$(ver_cut 4)"
768 +MY_PN="Oracle_VM_VirtualBox_Extension_Pack"
769 +MY_P="${MY_PN}-${MY_PV}-${VBOX_BUILD_ID}"
770 +
771 +DESCRIPTION="PUEL extensions for VirtualBox"
772 +HOMEPAGE="https://www.virtualbox.org/"
773 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.vbox-extpack -> ${MY_P}.tar.gz"
774 +
775 +LICENSE="PUEL"
776 +SLOT="0"
777 +KEYWORDS="~amd64 ~x86"
778 +IUSE=""
779 +RESTRICT="mirror strip"
780 +
781 +RDEPEND="~app-emulation/virtualbox-${DEP_PV}"
782 +
783 +S="${WORKDIR}"
784 +
785 +QA_PREBUILT="/usr/lib*/virtualbox/ExtensionPacks/${MY_PN}/.*"
786 +
787 +src_install() {
788 + insinto /usr/$(get_libdir)/virtualbox/ExtensionPacks/${MY_PN}
789 + doins -r linux.${ARCH}
790 + doins ExtPack* PXE-Intel.rom
791 +}
792
793 diff --git a/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-6.0.2.128162.ebuild b/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-6.0.2.128162.ebuild
794 new file mode 100644
795 index 00000000000..a260ead1a63
796 --- /dev/null
797 +++ b/app-emulation/virtualbox-extpack-oracle/virtualbox-extpack-oracle-6.0.2.128162.ebuild
798 @@ -0,0 +1,43 @@
799 +# Copyright 1999-2019 Gentoo Authors
800 +# Distributed under the terms of the GNU General Public License v2
801 +
802 +EAPI=7
803 +
804 +inherit multilib
805 +
806 +MAIN_PV="$(ver_cut 1-3)"
807 +if [[ ${PV} = *_beta* ]] || [[ ${PV} = *_rc* ]] ; then
808 + MY_PV="${MAIN_PV}_$(ver_cut 5-6)"
809 + DEP_PV="${MY_PV}"
810 + MY_PV="${MY_PV/beta/BETA}"
811 + MY_PV="${MY_PV/rc/RC}"
812 +else
813 + MY_PV="${MAIN_PV}"
814 + DEP_PV="${MAIN_PV}"
815 +fi
816 +VBOX_BUILD_ID="$(ver_cut 4)"
817 +MY_PN="Oracle_VM_VirtualBox_Extension_Pack"
818 +MY_P="${MY_PN}-${MY_PV}-${VBOX_BUILD_ID}"
819 +
820 +DESCRIPTION="PUEL extensions for VirtualBox"
821 +HOMEPAGE="https://www.virtualbox.org/"
822 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.vbox-extpack -> ${MY_P}.tar.gz"
823 +
824 +LICENSE="PUEL"
825 +SLOT="0"
826 +[[ "${PV}" == *_beta* ]] || [[ "${PV}" == *_rc* ]] || \
827 +KEYWORDS="~amd64 ~x86"
828 +IUSE=""
829 +RESTRICT="mirror strip"
830 +
831 +RDEPEND="~app-emulation/virtualbox-${DEP_PV}"
832 +
833 +S="${WORKDIR}"
834 +
835 +QA_PREBUILT="/usr/lib*/virtualbox/ExtensionPacks/${MY_PN}/.*"
836 +
837 +src_install() {
838 + insinto /usr/$(get_libdir)/virtualbox/ExtensionPacks/${MY_PN}
839 + doins -r linux.${ARCH}
840 + doins ExtPack* PXE-Intel.rom
841 +}
842
843 diff --git a/app-emulation/virtualbox-guest-additions/Manifest b/app-emulation/virtualbox-guest-additions/Manifest
844 index cecb44f361e..f15d100c7ab 100644
845 --- a/app-emulation/virtualbox-guest-additions/Manifest
846 +++ b/app-emulation/virtualbox-guest-additions/Manifest
847 @@ -1,4 +1,6 @@
848 DIST VirtualBox-5.2.22.tar.bz2 118757134 BLAKE2B be795cdbfb09d3d443f63e190b63898239622f5a57aefdd90f382d9a849d09cc1abc2624071fbc60b2c04a12f33376184540cc362c19225733f99a3bcc8ff6a3 SHA512 4f6c4611a3114778f45419587dc1519ca07410c1ea6474cdb18ecd3b068639a4fdac3f25146fe9b8e006e30f19eba134ce9f665182008b033f6f78497e1ea722
849 +DIST VirtualBox-5.2.24.tar.bz2 118369194 BLAKE2B 2073ec85a641ae80113d41e8363401da5afaf6ea442c2a3c537341f39e06a03a7175463605133e642988f72c4adde4f987905c08f4ba58460953af7169cb4ca0 SHA512 2de5a19ff6aff56a4f7e7b9d7d39b3e787d2ac30d448e3313e915b1cde4b2eedccab44c7a195412efb9e9a6de3c1fb3ee96bde57af93f9ef8f317ffa8b7d4410
850 DIST VirtualBox-6.0.0.tar.bz2 154322106 BLAKE2B 952e857e5bd6f612272b7bc399af5596d4eb4f13c429c93be7f9e6c4b58e535fe0492806fd51fd5a3f22653f0a42abb2a25ce6b67b5b4712d7e88e34b68eb8cf SHA512 fbe193a3c4dfef943bd75e894452cc684e794e5fa2b25d0292f7fb3e84d5f1a890fe0a3a91dbae9a9b90ec87f12cb3d868457e1767a5841964568cf13a189561
851 +DIST VirtualBox-6.0.2.tar.bz2 155125777 BLAKE2B 2d902fd1963305883eebba85daa03bd17fe8a9ba20e7a6482508879068a809ee80c4a5caffeb26acd0fd4ad29f6f60cf963e1d314e4b01f137ede5b589a74cb9 SHA512 9cfc03eae073ada47c050d2a5eeefa6f724ad2094f2bc3717aa010553ab0dd5af0ed0860bf120727491c7798cdff9219e53cdc3d629f61e3cd12c55068e7401b
852 DIST virtualbox-5.2.16-patches-02.tar.xz 3152 BLAKE2B c8d8f3872f544a465c7d1aa07291599307120ac9eabfb299ddd788a11f85ca6c2d84b8e7306ee4ad436270dad0dd39f101ee68a549eac15afd1e3cdc03f23c6c SHA512 85ee8c4045de562d71ab2d761695ea48b6726a6f0c4bcaa2562bb0d147542d3f1a1b5b47cf593a7f22dac1b86f87b59a56bef421dce3e1fa8e5260cd41998450
853 DIST virtualbox-6.0.0_beta2-patches-01.tar.xz 2732 BLAKE2B a138e715d99f135f16ca21c92781bf6cd8913f7f766bb598eddcd63e98280e568e646f56bbd0a3714f273457ca90db0b77ec7940ba25028506a22891f1af7b2d SHA512 954e4b40d6e272efe756ee0965adb4110d45f764433a89080fda7ebaebbc20031f86a3e0027dfdaa1c6a7d6379a1af557cea71512504e4b57b5f5adbfc86b56e
854
855 diff --git a/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.24.ebuild b/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.24.ebuild
856 new file mode 100644
857 index 00000000000..5780804c8c4
858 --- /dev/null
859 +++ b/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-5.2.24.ebuild
860 @@ -0,0 +1,228 @@
861 +# Copyright 1999-2019 Gentoo Authors
862 +# Distributed under the terms of the GNU General Public License v2
863 +
864 +EAPI=7
865 +
866 +inherit linux-mod systemd user toolchain-funcs
867 +
868 +MY_PV="${PV/beta/BETA}"
869 +MY_PV="${MY_PV/rc/RC}"
870 +MY_P="VirtualBox-${MY_PV}"
871 +DESCRIPTION="VirtualBox kernel modules and user-space tools for Gentoo guests"
872 +HOMEPAGE="https://www.virtualbox.org/"
873 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2
874 + https://dev.gentoo.org/~polynomial-c/virtualbox/patchsets/virtualbox-5.2.16-patches-02.tar.xz"
875 +
876 +LICENSE="GPL-2"
877 +SLOT="0"
878 +KEYWORDS="~amd64 ~x86"
879 +IUSE="X"
880 +
881 +RDEPEND="
882 + X? ( x11-apps/xrandr
883 + x11-apps/xrefresh
884 + x11-libs/libXmu
885 + x11-libs/libX11
886 + x11-libs/libXt
887 + x11-libs/libXext
888 + x11-libs/libXau
889 + x11-libs/libXdmcp
890 + x11-libs/libSM
891 + x11-libs/libICE )
892 + sys-apps/dbus
893 +"
894 +DEPEND="
895 + ${RDEPEND}
896 + >=dev-util/kbuild-0.1.9998.3127
897 + >=dev-lang/yasm-0.6.2
898 + sys-devel/bin86
899 + sys-libs/pam
900 + sys-power/iasl
901 + x11-base/xorg-proto
902 +"
903 +PDEPEND="
904 + X? ( x11-drivers/xf86-video-vboxvideo )
905 +"
906 +BUILD_TARGETS="all"
907 +BUILD_TARGET_ARCH="${ARCH}"
908 +
909 +S="${WORKDIR}/${MY_P}"
910 +
911 +pkg_setup() {
912 + MODULE_NAMES="vboxguest(misc:${WORKDIR}/vboxguest:${WORKDIR}/vboxguest)
913 + vboxsf(misc:${WORKDIR}/vboxsf:${WORKDIR}/vboxsf)"
914 + use X && MODULE_NAMES+=" vboxvideo(misc:${WORKDIR}/vboxvideo::${WORKDIR}/vboxvideo)"
915 +
916 + linux-mod_pkg_setup
917 + BUILD_PARAMS="KERN_DIR=/lib/modules/${KV_FULL}/build KERNOUT=${KV_OUT_DIR}"
918 +}
919 +
920 +src_unpack() {
921 + unpack ${A}
922 +
923 + # Create and unpack a tarball with the sources of the Linux guest
924 + # kernel modules, to include all the needed files
925 + "${S}"/src/VBox/Additions/linux/export_modules.sh "${WORKDIR}/vbox-kmod.tar.gz"
926 + unpack ./vbox-kmod.tar.gz
927 +
928 + # Remove shipped binaries (kBuild,yasm), see bug #232775
929 + cd "${S}"
930 + rm -rf kBuild/bin tools
931 +}
932 +
933 +src_prepare() {
934 + # PaX fixes (see bug #298988)
935 + pushd "${WORKDIR}" &>/dev/null || die
936 + eapply "${FILESDIR}"/vboxguest-4.1.0-log-use-c99.patch
937 + popd &>/dev/null || die
938 +
939 + # Disable things unused or splitted into separate ebuilds
940 + cp "${FILESDIR}/${PN}-5-localconfig" LocalConfig.kmk || die
941 + use X || echo "VBOX_WITH_X11_ADDITIONS :=" >> LocalConfig.kmk
942 +
943 + # stupid new header references...
944 + local vboxheader mdir
945 + for vboxheader in {product,revision,version}-generated.h ; do
946 + for mdir in vbox{guest,sf} ; do
947 + ln -sf "${S}"/out/linux.${ARCH}/release/${vboxheader} \
948 + "${WORKDIR}/${mdir}/${vboxheader}"
949 + done
950 + done
951 +
952 + # Remove pointless GCC version check
953 + sed -e '/^check_gcc$/d' -i configure || die
954 +
955 + rm "${WORKDIR}/patches/008_virtualbox-4.3.14-missing_define.patch" || die
956 + eapply "${WORKDIR}/patches"
957 +
958 + eapply_user
959 +}
960 +
961 +src_configure() {
962 + # build the user-space tools, warnings are harmless
963 + local cmd=(
964 + ./configure
965 + --nofatal
966 + --disable-xpcom
967 + --disable-sdl-ttf
968 + --disable-pulse
969 + --disable-alsa
970 + --with-gcc="$(tc-getCC)"
971 + --with-g++="$(tc-getCXX)"
972 + --target-arch=${ARCH}
973 + --with-linux="${KV_OUT_DIR}"
974 + --build-headless
975 + )
976 + echo "${cmd[@]}"
977 + "${cmd[@]}" || die "configure failed"
978 + source ./env.sh
979 + export VBOX_GCC_OPT="${CFLAGS} ${CPPFLAGS}"
980 +}
981 +
982 +src_compile() {
983 + MAKE="kmk" \
984 + emake TOOL_YASM_AS=yasm \
985 + VBOX_ONLY_ADDITIONS=1 \
986 + KBUILD_VERBOSE=2
987 +
988 + # Now creating the kernel modules. We must do this _after_
989 + # we compiled the user-space tools as we need two of the
990 + # automatically generated header files. (>=3.2.0)
991 + linux-mod_src_compile
992 +}
993 +
994 +src_install() {
995 + linux-mod_src_install
996 +
997 + cd "${S}"/out/linux.${ARCH}/release/bin/additions || die
998 +
999 + insinto /sbin
1000 + newins mount.vboxsf mount.vboxsf
1001 + fperms 4755 /sbin/mount.vboxsf
1002 +
1003 + newinitd "${FILESDIR}"/${PN}-8.initd ${PN}
1004 +
1005 + insinto /usr/sbin/
1006 + newins VBoxService vboxguest-service
1007 + fperms 0755 /usr/sbin/vboxguest-service
1008 +
1009 + insinto /usr/bin
1010 + doins VBoxControl
1011 + fperms 0755 /usr/bin/VBoxControl
1012 +
1013 + # VBoxClient user service and xrandr wrapper
1014 + if use X ; then
1015 + doins VBoxClient
1016 + fperms 0755 /usr/bin/VBoxClient
1017 +
1018 + pushd "${S}"/src/VBox/Additions/x11/Installer &>/dev/null \
1019 + || die
1020 + newins 98vboxadd-xclient VBoxClient-all
1021 + fperms 0755 /usr/bin/VBoxClient-all
1022 + popd &>/dev/null || die
1023 + fi
1024 +
1025 + # udev rule for vboxdrv
1026 + local udev_rules_dir="/lib/udev/rules.d"
1027 + dodir ${udev_rules_dir}
1028 + echo 'KERNEL=="vboxguest", OWNER="vboxguest", GROUP="vboxguest", MODE="0660"' \
1029 + >> "${ED%/}/${udev_rules_dir}/60-virtualbox-guest-additions.rules" \
1030 + || die
1031 + echo 'KERNEL=="vboxuser", OWNER="vboxguest", GROUP="vboxguest", MODE="0660"' \
1032 + >> "${ED%/}/${udev_rules_dir}/60-virtualbox-guest-additions.rules" \
1033 + || die
1034 +
1035 + # VBoxClient autostart file
1036 + insinto /etc/xdg/autostart
1037 + doins "${FILESDIR}"/vboxclient.desktop
1038 +
1039 + # sample xorg.conf
1040 + insinto /usr/share/doc/${PF}
1041 + doins "${FILESDIR}"/xorg.conf.vbox
1042 +
1043 + systemd_dounit "${FILESDIR}/${PN}.service"
1044 +}
1045 +
1046 +pkg_preinst() {
1047 + enewgroup vboxguest
1048 + enewuser vboxguest -1 /bin/sh /dev/null vboxguest
1049 + # automount Error: VBoxServiceAutoMountWorker: Group "vboxsf" does not exist
1050 + enewgroup vboxsf
1051 +}
1052 +
1053 +pkg_postinst() {
1054 + linux-mod_pkg_postinst
1055 + if ! use X ; then
1056 + elog "use flag X is off, enable it to install the"
1057 + elog "X Window System video driver."
1058 + fi
1059 + elog ""
1060 + elog "Please add users to the \"vboxguest\" group so they can"
1061 + elog "benefit from seamless mode, auto-resize and clipboard."
1062 + elog ""
1063 + elog "The vboxsf group has been added to make automount services work."
1064 + elog "These services are part of the shared folders support."
1065 + elog ""
1066 + elog "Please add:"
1067 + elog "/etc/init.d/${PN}"
1068 + elog "to the default runlevel in order to start"
1069 + elog "needed services."
1070 + elog "To use the VirtualBox X driver, use the following"
1071 + elog "file as your /etc/X11/xorg.conf:"
1072 + elog " /usr/share/doc/${PF}/xorg.conf.vbox"
1073 + elog ""
1074 + elog "Also make sure you use the Mesa library for OpenGL:"
1075 + elog " eselect opengl set xorg-x11"
1076 + elog ""
1077 + elog "An autostart .desktop file has been installed to start"
1078 + elog "VBoxClient in desktop sessions."
1079 + elog ""
1080 + elog "You can mount shared folders with:"
1081 + elog " mount -t vboxsf <shared_folder_name> <mount_point>"
1082 + elog ""
1083 + elog "Warning:"
1084 + elog "this ebuild is only needed if you are running gentoo"
1085 + elog "inside a VirtualBox Virtual Machine, you don't need"
1086 + elog "it to run VirtualBox itself."
1087 + elog ""
1088 +}
1089
1090 diff --git a/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-6.0.2.ebuild b/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-6.0.2.ebuild
1091 new file mode 100644
1092 index 00000000000..1cda2a1f29f
1093 --- /dev/null
1094 +++ b/app-emulation/virtualbox-guest-additions/virtualbox-guest-additions-6.0.2.ebuild
1095 @@ -0,0 +1,229 @@
1096 +# Copyright 1999-2019 Gentoo Authors
1097 +# Distributed under the terms of the GNU General Public License v2
1098 +
1099 +EAPI=7
1100 +
1101 +inherit linux-mod systemd user toolchain-funcs
1102 +
1103 +MY_PV="${PV/beta/BETA}"
1104 +MY_PV="${MY_PV/rc/RC}"
1105 +MY_P="VirtualBox-${MY_PV}"
1106 +DESCRIPTION="VirtualBox kernel modules and user-space tools for Gentoo guests"
1107 +HOMEPAGE="https://www.virtualbox.org/"
1108 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2
1109 + https://dev.gentoo.org/~polynomial-c/virtualbox/patchsets/virtualbox-6.0.0_beta2-patches-01.tar.xz"
1110 +
1111 +LICENSE="GPL-2"
1112 +SLOT="0"
1113 +[[ "${PV}" == *_beta* ]] || [[ "${PV}" == *_rc* ]] || \
1114 +KEYWORDS="~amd64 ~x86"
1115 +IUSE="X"
1116 +
1117 +RDEPEND="
1118 + X? ( x11-apps/xrandr
1119 + x11-apps/xrefresh
1120 + x11-libs/libXmu
1121 + x11-libs/libX11
1122 + x11-libs/libXt
1123 + x11-libs/libXext
1124 + x11-libs/libXau
1125 + x11-libs/libXdmcp
1126 + x11-libs/libSM
1127 + x11-libs/libICE )
1128 + sys-apps/dbus
1129 +"
1130 +DEPEND="
1131 + ${RDEPEND}
1132 + >=dev-util/kbuild-0.1.9998.3127
1133 + >=dev-lang/yasm-0.6.2
1134 + sys-devel/bin86
1135 + sys-libs/pam
1136 + sys-power/iasl
1137 + x11-base/xorg-proto
1138 +"
1139 +PDEPEND="
1140 + X? ( x11-drivers/xf86-video-vboxvideo )
1141 +"
1142 +BUILD_TARGETS="all"
1143 +BUILD_TARGET_ARCH="${ARCH}"
1144 +
1145 +S="${WORKDIR}/${MY_P}"
1146 +
1147 +pkg_setup() {
1148 + MODULE_NAMES="vboxguest(misc:${WORKDIR}/vboxguest:${WORKDIR}/vboxguest)
1149 + vboxsf(misc:${WORKDIR}/vboxsf:${WORKDIR}/vboxsf)"
1150 + use X && MODULE_NAMES+=" vboxvideo(misc:${WORKDIR}/vboxvideo::${WORKDIR}/vboxvideo)"
1151 +
1152 + linux-mod_pkg_setup
1153 + BUILD_PARAMS="KERN_DIR=/lib/modules/${KV_FULL}/build KERNOUT=${KV_OUT_DIR}"
1154 +}
1155 +
1156 +src_unpack() {
1157 + unpack ${A}
1158 +
1159 + # Create and unpack a tarball with the sources of the Linux guest
1160 + # kernel modules, to include all the needed files
1161 + "${S}"/src/VBox/Additions/linux/export_modules.sh "${WORKDIR}/vbox-kmod.tar.gz"
1162 + unpack ./vbox-kmod.tar.gz
1163 +
1164 + # Remove shipped binaries (kBuild,yasm), see bug #232775
1165 + cd "${S}"
1166 + rm -rf kBuild/bin tools
1167 +}
1168 +
1169 +src_prepare() {
1170 + # PaX fixes (see bug #298988)
1171 + pushd "${WORKDIR}" &>/dev/null || die
1172 + eapply "${FILESDIR}"/vboxguest-4.1.0-log-use-c99.patch
1173 + popd &>/dev/null || die
1174 +
1175 + # Disable things unused or splitted into separate ebuilds
1176 + cp "${FILESDIR}/${PN}-5-localconfig" LocalConfig.kmk || die
1177 + use X || echo "VBOX_WITH_X11_ADDITIONS :=" >> LocalConfig.kmk
1178 +
1179 + # stupid new header references...
1180 + local vboxheader mdir
1181 + for vboxheader in {product,revision,version}-generated.h ; do
1182 + for mdir in vbox{guest,sf} ; do
1183 + ln -sf "${S}"/out/linux.${ARCH}/release/${vboxheader} \
1184 + "${WORKDIR}/${mdir}/${vboxheader}"
1185 + done
1186 + done
1187 +
1188 + # Remove pointless GCC version check
1189 + sed -e '/^check_gcc$/d' -i configure || die
1190 +
1191 + rm "${WORKDIR}/patches/010_virtualbox-5.2.12-qt511.patch" || die
1192 + eapply "${WORKDIR}/patches"
1193 +
1194 + eapply_user
1195 +}
1196 +
1197 +src_configure() {
1198 + # build the user-space tools, warnings are harmless
1199 + local cmd=(
1200 + ./configure
1201 + --nofatal
1202 + --disable-xpcom
1203 + --disable-sdl-ttf
1204 + --disable-pulse
1205 + --disable-alsa
1206 + --with-gcc="$(tc-getCC)"
1207 + --with-g++="$(tc-getCXX)"
1208 + --target-arch=${ARCH}
1209 + --with-linux="${KV_OUT_DIR}"
1210 + --build-headless
1211 + )
1212 + echo "${cmd[@]}"
1213 + "${cmd[@]}" || die "configure failed"
1214 + source ./env.sh
1215 + export VBOX_GCC_OPT="${CFLAGS} ${CPPFLAGS}"
1216 +}
1217 +
1218 +src_compile() {
1219 + MAKE="kmk" \
1220 + emake TOOL_YASM_AS=yasm \
1221 + VBOX_ONLY_ADDITIONS=1 \
1222 + KBUILD_VERBOSE=2
1223 +
1224 + # Now creating the kernel modules. We must do this _after_
1225 + # we compiled the user-space tools as we need two of the
1226 + # automatically generated header files. (>=3.2.0)
1227 + linux-mod_src_compile
1228 +}
1229 +
1230 +src_install() {
1231 + linux-mod_src_install
1232 +
1233 + cd "${S}"/out/linux.${ARCH}/release/bin/additions || die
1234 +
1235 + insinto /sbin
1236 + newins mount.vboxsf mount.vboxsf
1237 + fperms 4755 /sbin/mount.vboxsf
1238 +
1239 + newinitd "${FILESDIR}"/${PN}-8.initd ${PN}
1240 +
1241 + insinto /usr/sbin/
1242 + newins VBoxService vboxguest-service
1243 + fperms 0755 /usr/sbin/vboxguest-service
1244 +
1245 + insinto /usr/bin
1246 + doins VBoxControl
1247 + fperms 0755 /usr/bin/VBoxControl
1248 +
1249 + # VBoxClient user service and xrandr wrapper
1250 + if use X ; then
1251 + doins VBoxClient
1252 + fperms 0755 /usr/bin/VBoxClient
1253 +
1254 + pushd "${S}"/src/VBox/Additions/x11/Installer &>/dev/null \
1255 + || die
1256 + newins 98vboxadd-xclient VBoxClient-all
1257 + fperms 0755 /usr/bin/VBoxClient-all
1258 + popd &>/dev/null || die
1259 + fi
1260 +
1261 + # udev rule for vboxdrv
1262 + local udev_rules_dir="/lib/udev/rules.d"
1263 + dodir ${udev_rules_dir}
1264 + echo 'KERNEL=="vboxguest", OWNER="vboxguest", GROUP="vboxguest", MODE="0660"' \
1265 + >> "${ED%/}/${udev_rules_dir}/60-virtualbox-guest-additions.rules" \
1266 + || die
1267 + echo 'KERNEL=="vboxuser", OWNER="vboxguest", GROUP="vboxguest", MODE="0660"' \
1268 + >> "${ED%/}/${udev_rules_dir}/60-virtualbox-guest-additions.rules" \
1269 + || die
1270 +
1271 + # VBoxClient autostart file
1272 + insinto /etc/xdg/autostart
1273 + doins "${FILESDIR}"/vboxclient.desktop
1274 +
1275 + # sample xorg.conf
1276 + insinto /usr/share/doc/${PF}
1277 + doins "${FILESDIR}"/xorg.conf.vbox
1278 +
1279 + systemd_dounit "${FILESDIR}/${PN}.service"
1280 +}
1281 +
1282 +pkg_preinst() {
1283 + enewgroup vboxguest
1284 + enewuser vboxguest -1 /bin/sh /dev/null vboxguest
1285 + # automount Error: VBoxServiceAutoMountWorker: Group "vboxsf" does not exist
1286 + enewgroup vboxsf
1287 +}
1288 +
1289 +pkg_postinst() {
1290 + linux-mod_pkg_postinst
1291 + if ! use X ; then
1292 + elog "use flag X is off, enable it to install the"
1293 + elog "X Window System video driver."
1294 + fi
1295 + elog ""
1296 + elog "Please add users to the \"vboxguest\" group so they can"
1297 + elog "benefit from seamless mode, auto-resize and clipboard."
1298 + elog ""
1299 + elog "The vboxsf group has been added to make automount services work."
1300 + elog "These services are part of the shared folders support."
1301 + elog ""
1302 + elog "Please add:"
1303 + elog "/etc/init.d/${PN}"
1304 + elog "to the default runlevel in order to start"
1305 + elog "needed services."
1306 + elog "To use the VirtualBox X driver, use the following"
1307 + elog "file as your /etc/X11/xorg.conf:"
1308 + elog " /usr/share/doc/${PF}/xorg.conf.vbox"
1309 + elog ""
1310 + elog "Also make sure you use the Mesa library for OpenGL:"
1311 + elog " eselect opengl set xorg-x11"
1312 + elog ""
1313 + elog "An autostart .desktop file has been installed to start"
1314 + elog "VBoxClient in desktop sessions."
1315 + elog ""
1316 + elog "You can mount shared folders with:"
1317 + elog " mount -t vboxsf <shared_folder_name> <mount_point>"
1318 + elog ""
1319 + elog "Warning:"
1320 + elog "this ebuild is only needed if you are running gentoo"
1321 + elog "inside a VirtualBox Virtual Machine, you don't need"
1322 + elog "it to run VirtualBox itself."
1323 + elog ""
1324 +}
1325
1326 diff --git a/app-emulation/virtualbox-modules/Manifest b/app-emulation/virtualbox-modules/Manifest
1327 index 2647a1192db..5a6e05cde21 100644
1328 --- a/app-emulation/virtualbox-modules/Manifest
1329 +++ b/app-emulation/virtualbox-modules/Manifest
1330 @@ -1,2 +1,4 @@
1331 DIST vbox-kernel-module-src-5.2.22.tar.xz 638492 BLAKE2B 71aba29b056bb3dfeffbf4632fbf7f15d89b988267ba24c766b78b1d9c50a4d27fb1b8e699108b973af68024f9f77ca0a8ad787355d7342fe1400f14189487ff SHA512 3361bb536af8e8d490377be04d1b1b9af478538e23ec409d3e0205ad930c16e5228c57ae7d92d214ac533ae64298d9eaff3c9284ff9bb308108d1ad7d69fb507
1332 +DIST vbox-kernel-module-src-5.2.24.tar.xz 642124 BLAKE2B fbf077b1d94f0b2f6ccb1a9a9f2e9b6f2b02153659f60a28bf3905bbd9aca762bcdbbe1a96ff602048a4d43eb61b8195c1c511bea7248d0593efd7972a17fc5b SHA512 ba0dc0ba4964eb17c421f624e321369a96564f08daa7e6949db9cbde2a182cd29a51f7b0a3215938789bb61e2427cbd38e318e5d909fd54d243ef764f51eb0e4
1333 DIST vbox-kernel-module-src-6.0.0.tar.xz 666352 BLAKE2B 51309dd9fddb1e26e8fce55bae018d96569a28ce1d6850e2b13b47829d0336671d23962191ff4eda0f846c073a94a1d30fa67bb5e5b73f1fda63b6f06acc1225 SHA512 c0c26f2544580e16c525db997a5a3b2cbe1b84b0418cf099d12c67bc72ff7c79b30fe74793d10c710db6a03640ccb5935fbb9df55c2d8aea435beafe0de94385
1334 +DIST vbox-kernel-module-src-6.0.2.tar.xz 665352 BLAKE2B 703291334afb8662211dfc5223d66dafa496612ca917637b2d34f6d38475287a1eed00e484965c670da236fdfcc558e0c7ebd081be1f6674603af2c0b6bda549 SHA512 c05f3e89b2fc5a504e77f0617dbe9ccde8de6d9b06e4c2f6d59d90f362b2d5a8207d64b16a8c767e63066a04236934664dfd452b23f4c5a2c4a3b301e07212c9
1335
1336 diff --git a/app-emulation/virtualbox-modules/virtualbox-modules-5.2.24.ebuild b/app-emulation/virtualbox-modules/virtualbox-modules-5.2.24.ebuild
1337 new file mode 100644
1338 index 00000000000..c4b01a1b3f9
1339 --- /dev/null
1340 +++ b/app-emulation/virtualbox-modules/virtualbox-modules-5.2.24.ebuild
1341 @@ -0,0 +1,51 @@
1342 +# Copyright 1999-2019 Gentoo Authors
1343 +# Distributed under the terms of the GNU General Public License v2
1344 +
1345 +# XXX: the tarball here is just the kernel modules split out of the binary
1346 +# package that comes from virtualbox-bin
1347 +
1348 +EAPI=7
1349 +
1350 +inherit linux-mod user
1351 +
1352 +MY_P="vbox-kernel-module-src-${PV}"
1353 +DESCRIPTION="Kernel Modules for Virtualbox"
1354 +HOMEPAGE="https://www.virtualbox.org/"
1355 +SRC_URI="https://dev.gentoo.org/~polynomial-c/virtualbox/${MY_P}.tar.xz"
1356 +
1357 +LICENSE="GPL-2"
1358 +SLOT="0"
1359 +KEYWORDS="~amd64 ~x86"
1360 +IUSE="pax_kernel"
1361 +
1362 +RDEPEND="!=app-emulation/virtualbox-9999"
1363 +
1364 +S="${WORKDIR}"
1365 +
1366 +BUILD_TARGETS="all"
1367 +BUILD_TARGET_ARCH="${ARCH}"
1368 +MODULE_NAMES="vboxdrv(misc:${S}) vboxnetflt(misc:${S}) vboxnetadp(misc:${S}) vboxpci(misc:${S})"
1369 +
1370 +pkg_setup() {
1371 + enewgroup vboxusers
1372 + linux-mod_pkg_setup
1373 + BUILD_PARAMS="CC=$(tc-getBUILD_CC) KERN_DIR=${KV_DIR} KERN_VER=${KV_FULL} O=${KV_OUT_DIR} V=1 KBUILD_VERBOSE=1"
1374 +}
1375 +
1376 +src_prepare() {
1377 + if use pax_kernel && kernel_is -ge 3 0 0 ; then
1378 + eapply -p0 "${FILESDIR}"/${PN}-5.2.8-pax-const.patch
1379 + fi
1380 +
1381 + default
1382 +}
1383 +
1384 +src_install() {
1385 + linux-mod_src_install
1386 + insinto /usr/lib/modules-load.d/
1387 + doins "${FILESDIR}"/virtualbox.conf
1388 +}
1389 +
1390 +pkg_postinst() {
1391 + linux-mod_pkg_postinst
1392 +}
1393
1394 diff --git a/app-emulation/virtualbox-modules/virtualbox-modules-6.0.2.ebuild b/app-emulation/virtualbox-modules/virtualbox-modules-6.0.2.ebuild
1395 new file mode 100644
1396 index 00000000000..7257cb3b581
1397 --- /dev/null
1398 +++ b/app-emulation/virtualbox-modules/virtualbox-modules-6.0.2.ebuild
1399 @@ -0,0 +1,52 @@
1400 +# Copyright 1999-2019 Gentoo Authors
1401 +# Distributed under the terms of the GNU General Public License v2
1402 +
1403 +# XXX: the tarball here is just the kernel modules split out of the binary
1404 +# package that comes from virtualbox-bin
1405 +
1406 +EAPI=7
1407 +
1408 +inherit linux-mod user
1409 +
1410 +MY_P="vbox-kernel-module-src-${PV}"
1411 +DESCRIPTION="Kernel Modules for Virtualbox"
1412 +HOMEPAGE="https://www.virtualbox.org/"
1413 +SRC_URI="https://dev.gentoo.org/~polynomial-c/virtualbox/${MY_P}.tar.xz"
1414 +
1415 +LICENSE="GPL-2"
1416 +SLOT="0"
1417 +[[ "${PV}" == *_beta* ]] || [[ "${PV}" == *_rc* ]] || \
1418 +KEYWORDS="~amd64 ~x86"
1419 +IUSE="pax_kernel"
1420 +
1421 +RDEPEND="!=app-emulation/virtualbox-9999"
1422 +
1423 +S="${WORKDIR}"
1424 +
1425 +BUILD_TARGETS="all"
1426 +BUILD_TARGET_ARCH="${ARCH}"
1427 +MODULE_NAMES="vboxdrv(misc:${S}) vboxnetflt(misc:${S}) vboxnetadp(misc:${S}) vboxpci(misc:${S})"
1428 +
1429 +pkg_setup() {
1430 + enewgroup vboxusers
1431 + linux-mod_pkg_setup
1432 + BUILD_PARAMS="CC=$(tc-getBUILD_CC) KERN_DIR=${KV_DIR} KERN_VER=${KV_FULL} O=${KV_OUT_DIR} V=1 KBUILD_VERBOSE=1"
1433 +}
1434 +
1435 +src_prepare() {
1436 + if use pax_kernel && kernel_is -ge 3 0 0 ; then
1437 + eapply -p0 "${FILESDIR}"/${PN}-5.2.8-pax-const.patch
1438 + fi
1439 +
1440 + default
1441 +}
1442 +
1443 +src_install() {
1444 + linux-mod_src_install
1445 + insinto /usr/lib/modules-load.d/
1446 + doins "${FILESDIR}"/virtualbox.conf
1447 +}
1448 +
1449 +pkg_postinst() {
1450 + linux-mod_pkg_postinst
1451 +}
1452
1453 diff --git a/app-emulation/virtualbox/Manifest b/app-emulation/virtualbox/Manifest
1454 index cecb44f361e..f15d100c7ab 100644
1455 --- a/app-emulation/virtualbox/Manifest
1456 +++ b/app-emulation/virtualbox/Manifest
1457 @@ -1,4 +1,6 @@
1458 DIST VirtualBox-5.2.22.tar.bz2 118757134 BLAKE2B be795cdbfb09d3d443f63e190b63898239622f5a57aefdd90f382d9a849d09cc1abc2624071fbc60b2c04a12f33376184540cc362c19225733f99a3bcc8ff6a3 SHA512 4f6c4611a3114778f45419587dc1519ca07410c1ea6474cdb18ecd3b068639a4fdac3f25146fe9b8e006e30f19eba134ce9f665182008b033f6f78497e1ea722
1459 +DIST VirtualBox-5.2.24.tar.bz2 118369194 BLAKE2B 2073ec85a641ae80113d41e8363401da5afaf6ea442c2a3c537341f39e06a03a7175463605133e642988f72c4adde4f987905c08f4ba58460953af7169cb4ca0 SHA512 2de5a19ff6aff56a4f7e7b9d7d39b3e787d2ac30d448e3313e915b1cde4b2eedccab44c7a195412efb9e9a6de3c1fb3ee96bde57af93f9ef8f317ffa8b7d4410
1460 DIST VirtualBox-6.0.0.tar.bz2 154322106 BLAKE2B 952e857e5bd6f612272b7bc399af5596d4eb4f13c429c93be7f9e6c4b58e535fe0492806fd51fd5a3f22653f0a42abb2a25ce6b67b5b4712d7e88e34b68eb8cf SHA512 fbe193a3c4dfef943bd75e894452cc684e794e5fa2b25d0292f7fb3e84d5f1a890fe0a3a91dbae9a9b90ec87f12cb3d868457e1767a5841964568cf13a189561
1461 +DIST VirtualBox-6.0.2.tar.bz2 155125777 BLAKE2B 2d902fd1963305883eebba85daa03bd17fe8a9ba20e7a6482508879068a809ee80c4a5caffeb26acd0fd4ad29f6f60cf963e1d314e4b01f137ede5b589a74cb9 SHA512 9cfc03eae073ada47c050d2a5eeefa6f724ad2094f2bc3717aa010553ab0dd5af0ed0860bf120727491c7798cdff9219e53cdc3d629f61e3cd12c55068e7401b
1462 DIST virtualbox-5.2.16-patches-02.tar.xz 3152 BLAKE2B c8d8f3872f544a465c7d1aa07291599307120ac9eabfb299ddd788a11f85ca6c2d84b8e7306ee4ad436270dad0dd39f101ee68a549eac15afd1e3cdc03f23c6c SHA512 85ee8c4045de562d71ab2d761695ea48b6726a6f0c4bcaa2562bb0d147542d3f1a1b5b47cf593a7f22dac1b86f87b59a56bef421dce3e1fa8e5260cd41998450
1463 DIST virtualbox-6.0.0_beta2-patches-01.tar.xz 2732 BLAKE2B a138e715d99f135f16ca21c92781bf6cd8913f7f766bb598eddcd63e98280e568e646f56bbd0a3714f273457ca90db0b77ec7940ba25028506a22891f1af7b2d SHA512 954e4b40d6e272efe756ee0965adb4110d45f764433a89080fda7ebaebbc20031f86a3e0027dfdaa1c6a7d6379a1af557cea71512504e4b57b5f5adbfc86b56e
1464
1465 diff --git a/app-emulation/virtualbox/virtualbox-5.2.24.ebuild b/app-emulation/virtualbox/virtualbox-5.2.24.ebuild
1466 new file mode 100644
1467 index 00000000000..4464ccc84a0
1468 --- /dev/null
1469 +++ b/app-emulation/virtualbox/virtualbox-5.2.24.ebuild
1470 @@ -0,0 +1,480 @@
1471 +# Copyright 1999-2019 Gentoo Authors
1472 +# Distributed under the terms of the GNU General Public License v2
1473 +
1474 +EAPI=6
1475 +
1476 +PYTHON_COMPAT=( python2_7 )
1477 +inherit flag-o-matic gnome2-utils java-pkg-opt-2 linux-info pax-utils python-single-r1 tmpfiles toolchain-funcs udev xdg-utils
1478 +
1479 +MY_PV="${PV/beta/BETA}"
1480 +MY_PV="${MY_PV/rc/RC}"
1481 +MY_P=VirtualBox-${MY_PV}
1482 +
1483 +DESCRIPTION="Family of powerful x86 virtualization products for enterprise and home use"
1484 +HOMEPAGE="https://www.virtualbox.org/"
1485 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2
1486 + https://dev.gentoo.org/~polynomial-c/${PN}/patchsets/${PN}-5.2.16-patches-02.tar.xz"
1487 +
1488 +LICENSE="GPL-2"
1489 +SLOT="0"
1490 +KEYWORDS="~amd64 ~x86"
1491 +IUSE="alsa debug doc headless java libressl lvm +opus pam pax_kernel pulseaudio +opengl python +qt5 +sdk +udev vboxwebsrv vnc"
1492 +
1493 +RDEPEND="!app-emulation/virtualbox-bin
1494 + ~app-emulation/virtualbox-modules-${PV}
1495 + dev-libs/libIDL
1496 + >=dev-libs/libxslt-1.1.19
1497 + net-misc/curl
1498 + dev-libs/libxml2
1499 + media-libs/libpng:0=
1500 + media-libs/libvpx:0=
1501 + sys-libs/zlib:=
1502 + !headless? (
1503 + media-libs/libsdl:0[X,video]
1504 + x11-libs/libX11
1505 + x11-libs/libxcb:=
1506 + x11-libs/libXcursor
1507 + x11-libs/libXext
1508 + x11-libs/libXmu
1509 + x11-libs/libXt
1510 + opengl? ( virtual/opengl media-libs/freeglut )
1511 + qt5? (
1512 + dev-qt/qtcore:5
1513 + dev-qt/qtgui:5
1514 + dev-qt/qtprintsupport:5
1515 + dev-qt/qtwidgets:5
1516 + dev-qt/qtx11extras:5
1517 + opengl? ( dev-qt/qtopengl:5 )
1518 + x11-libs/libXinerama
1519 + )
1520 + )
1521 + libressl? ( dev-libs/libressl:= )
1522 + !libressl? ( dev-libs/openssl:0= )
1523 + lvm? ( sys-fs/lvm2 )
1524 + opus? ( media-libs/opus )
1525 + udev? ( >=virtual/udev-171 )
1526 + vnc? ( >=net-libs/libvncserver-0.9.9 )"
1527 +DEPEND="${RDEPEND}
1528 + >=dev-util/kbuild-0.1.9998.3127
1529 + >=dev-lang/yasm-0.6.2
1530 + sys-devel/bin86
1531 + sys-libs/libcap
1532 + sys-power/iasl
1533 + virtual/pkgconfig
1534 + alsa? ( >=media-libs/alsa-lib-1.0.13 )
1535 + doc? (
1536 + app-text/docbook-sgml-dtd:4.4
1537 + dev-texlive/texlive-basic
1538 + dev-texlive/texlive-latex
1539 + dev-texlive/texlive-latexrecommended
1540 + dev-texlive/texlive-latexextra
1541 + dev-texlive/texlive-fontsrecommended
1542 + dev-texlive/texlive-fontsextra
1543 + )
1544 + !headless? ( x11-libs/libXinerama )
1545 + java? ( >=virtual/jdk-1.6 )
1546 + pam? ( sys-libs/pam )
1547 + pax_kernel? ( sys-apps/elfix )
1548 + pulseaudio? ( media-sound/pulseaudio )
1549 + qt5? ( dev-qt/linguist-tools:5 )
1550 + vboxwebsrv? ( net-libs/gsoap[-gnutls(-)] )
1551 + ${PYTHON_DEPS}"
1552 +RDEPEND="${RDEPEND}
1553 + java? ( >=virtual/jre-1.6 )"
1554 +
1555 +QA_TEXTRELS_x86="usr/lib/virtualbox-ose/VBoxGuestPropSvc.so
1556 + usr/lib/virtualbox/VBoxSDL.so
1557 + usr/lib/virtualbox/VBoxSharedFolders.so
1558 + usr/lib/virtualbox/VBoxDD2.so
1559 + usr/lib/virtualbox/VBoxOGLrenderspu.so
1560 + usr/lib/virtualbox/VBoxPython.so
1561 + usr/lib/virtualbox/VBoxDD.so
1562 + usr/lib/virtualbox/VBoxDDU.so
1563 + usr/lib/virtualbox/VBoxREM64.so
1564 + usr/lib/virtualbox/VBoxSharedClipboard.so
1565 + usr/lib/virtualbox/VBoxHeadless.so
1566 + usr/lib/virtualbox/VBoxRT.so
1567 + usr/lib/virtualbox/VBoxREM.so
1568 + usr/lib/virtualbox/VBoxSettings.so
1569 + usr/lib/virtualbox/VBoxKeyboard.so
1570 + usr/lib/virtualbox/VBoxSharedCrOpenGL.so
1571 + usr/lib/virtualbox/VBoxVMM.so
1572 + usr/lib/virtualbox/VirtualBox.so
1573 + usr/lib/virtualbox/VBoxOGLhosterrorspu.so
1574 + usr/lib/virtualbox/components/VBoxC.so
1575 + usr/lib/virtualbox/components/VBoxSVCM.so
1576 + usr/lib/virtualbox/components/VBoxDDU.so
1577 + usr/lib/virtualbox/components/VBoxRT.so
1578 + usr/lib/virtualbox/components/VBoxREM.so
1579 + usr/lib/virtualbox/components/VBoxVMM.so
1580 + usr/lib/virtualbox/VBoxREM32.so
1581 + usr/lib/virtualbox/VBoxPython2_7.so
1582 + usr/lib/virtualbox/VBoxXPCOMC.so
1583 + usr/lib/virtualbox/VBoxOGLhostcrutil.so
1584 + usr/lib/virtualbox/VBoxNetDHCP.so
1585 + usr/lib/virtualbox/VBoxNetNAT.so"
1586 +
1587 +S="${WORKDIR}/${MY_P}"
1588 +
1589 +REQUIRED_USE="
1590 + java? ( sdk )
1591 + python? ( sdk )
1592 + vboxwebsrv? ( java )
1593 + ${PYTHON_REQUIRED_USE}
1594 +"
1595 +
1596 +pkg_pretend() {
1597 + if ! use headless && ! use qt5 ; then
1598 + einfo "No USE=\"qt5\" selected, this build will not include any Qt frontend."
1599 + elif use headless && use qt5 ; then
1600 + einfo "You selected USE=\"headless qt5\", defaulting to"
1601 + einfo "USE=\"headless\", this build will not include any X11/Qt frontend."
1602 + fi
1603 +
1604 + if ! use opengl ; then
1605 + einfo "No USE=\"opengl\" selected, this build will lack"
1606 + einfo "the OpenGL feature."
1607 + fi
1608 + if ! use python ; then
1609 + einfo "You have disabled the \"python\" USE flag. This will only"
1610 + einfo "disable the python bindings being installed."
1611 + fi
1612 +}
1613 +
1614 +pkg_setup() {
1615 + java-pkg-opt-2_pkg_setup
1616 + python-single-r1_pkg_setup
1617 +
1618 + tc-ld-disable-gold #bug 488176
1619 + tc-export CC CXX LD AR RANLIB
1620 + export HOST_CC="$(tc-getBUILD_CC)"
1621 +}
1622 +
1623 +src_prepare() {
1624 + # Remove shipped binaries (kBuild,yasm), see bug #232775
1625 + rm -r kBuild/bin tools || die
1626 +
1627 + # Replace pointless GCC version check with something less stupid.
1628 + # This is needed for the qt5 version check.
1629 + sed -e 's@^check_gcc$@cc_maj="$(gcc -dumpversion | cut -d. -f1)" ; cc_min="$(gcc -dumpversion | cut -d. -f2)"@' \
1630 + -i configure || die
1631 +
1632 + # Disable things unused or split into separate ebuilds
1633 + sed -e "s@MY_LIBDIR@$(get_libdir)@" \
1634 + "${FILESDIR}"/${PN}-5-localconfig > LocalConfig.kmk || die
1635 +
1636 + # Respect LDFLAGS
1637 + sed -e "s@_LDFLAGS\.${ARCH}*.*=@& ${LDFLAGS}@g" \
1638 + -i Config.kmk src/libs/xpcom18a4/Config.kmk || die
1639 +
1640 + # Do not use hard-coded ld (related to bug #488176)
1641 + sed -e '/QUIET)ld /s@ld @$(LD) @' \
1642 + -i src/VBox/Devices/PC/ipxe/Makefile.kmk || die
1643 +
1644 + # Use PAM only when pam USE flag is enbaled (bug #376531)
1645 + if ! use pam ; then
1646 + elog "Disabling PAM removes the possibility to use the VRDP features."
1647 + sed -i 's@^.*VBOX_WITH_PAM@#VBOX_WITH_PAM@' Config.kmk || die
1648 + sed -i 's@\(.*/auth/Makefile.kmk.*\)@#\1@' \
1649 + src/VBox/HostServices/Makefile.kmk || die
1650 + fi
1651 +
1652 + # add correct java path
1653 + if use java ; then
1654 + sed "s@/usr/lib/jvm/java-6-sun@$(java-config -O)@" \
1655 + -i "${S}"/Config.kmk || die
1656 + java-pkg-opt-2_src_prepare
1657 + fi
1658 +
1659 + # Only add nopie patch when we're on hardened
1660 + if gcc-specs-pie ; then
1661 + eapply "${FILESDIR}/050_virtualbox-5.2.8-nopie.patch"
1662 + fi
1663 +
1664 + # Only add paxmark patch when we're on pax_kernel
1665 + if use pax_kernel ; then
1666 + eapply "${FILESDIR}"/virtualbox-5.2.8-paxmark-bldprogs.patch
1667 + fi
1668 +
1669 + rm "${WORKDIR}/patches/008_virtualbox-4.3.14-missing_define.patch" || die
1670 + eapply "${WORKDIR}/patches"
1671 +
1672 + eapply_user
1673 +}
1674 +
1675 +doecho() {
1676 + echo "$@"
1677 + "$@" || die
1678 +}
1679 +
1680 +src_configure() {
1681 + local myconf=(
1682 + --with-gcc="$(tc-getCC)"
1683 + --with-g++="$(tc-getCXX)"
1684 + --disable-dbus
1685 + --disable-kmods
1686 + $(usex alsa '' --disable-alsa)
1687 + $(usex debug --build-debug '')
1688 + $(usex doc '' --disable-docs)
1689 + $(usex java '' --disable-java)
1690 + $(usex lvm '' --disable-devmapper)
1691 + $(usex opus --build-libopus '')
1692 + $(usex pulseaudio '' --disable-pulse)
1693 + $(usex python '' --disable-python)
1694 + $(usex vboxwebsrv --enable-webservice '')
1695 + $(usex vnc --enable-vnc '')
1696 + )
1697 + if ! use headless ; then
1698 + myconf+=(
1699 + $(usex opengl '' --disable-opengl)
1700 + $(usex qt5 '' --disable-qt)
1701 + )
1702 + else
1703 + myconf+=(
1704 + --build-headless
1705 + --disable-opengl
1706 + )
1707 + fi
1708 + if use amd64 && ! has_multilib_profile ; then
1709 + myconf+=( --disable-vmmraw )
1710 + fi
1711 + # not an autoconf script
1712 + doecho ./configure ${myconf[@]}
1713 +}
1714 +
1715 +src_compile() {
1716 + source ./env.sh || die
1717 +
1718 + # Force kBuild to respect C[XX]FLAGS and MAKEOPTS (bug #178529)
1719 + MAKEJOBS=$(grep -Eo '(\-j|\-\-jobs)(=?|[[:space:]]*)[[:digit:]]+' <<< ${MAKEOPTS}) #'
1720 + MAKELOAD=$(grep -Eo '(\-l|\-\-load-average)(=?|[[:space:]]*)[[:digit:]]+' <<< ${MAKEOPTS}) #'
1721 + MAKEOPTS="${MAKEJOBS} ${MAKELOAD}"
1722 + MAKE="kmk" emake \
1723 + VBOX_BUILD_PUBLISHER=_Gentoo \
1724 + TOOL_GCC3_CC="$(tc-getCC)" TOOL_GCC3_CXX="$(tc-getCXX)" \
1725 + TOOL_GCC3_AS="$(tc-getCC)" TOOL_GCC3_AR="$(tc-getAR)" \
1726 + TOOL_GCC3_LD="$(tc-getCXX)" TOOL_GCC3_LD_SYSMOD="$(tc-getLD)" \
1727 + TOOL_GCC3_CFLAGS="${CFLAGS}" TOOL_GCC3_CXXFLAGS="${CXXFLAGS}" \
1728 + VBOX_GCC_OPT="${CXXFLAGS}" \
1729 + TOOL_YASM_AS=yasm KBUILD_VERBOSE=2 \
1730 + all
1731 +}
1732 +
1733 +src_install() {
1734 + local binpath="release"
1735 + use debug && binpath="debug"
1736 + cd "${S}"/out/linux.${ARCH}/${binpath}/bin || die
1737 +
1738 + local vbox_inst_path="/usr/$(get_libdir)/${PN}" each fwfile size ico icofile
1739 +
1740 + vbox_inst() {
1741 + local binary="${1}"
1742 + local perms="${2:-0750}"
1743 + local path="${3:-${vbox_inst_path}}"
1744 +
1745 + [[ -n "${binary}" ]] || die "vbox_inst: No binray given!"
1746 + [[ ${perms} =~ ^[[:digit:]]+{4}$ ]] || die "vbox_inst: perms must consist of four digits."
1747 +
1748 + insinto ${path}
1749 + doins ${binary}
1750 + fowners root:vboxusers ${path}/${binary}
1751 + fperms ${perms} ${path}/${binary}
1752 + }
1753 +
1754 + # Create configuration files
1755 + insinto /etc/vbox
1756 + newins "${FILESDIR}/${PN}-4-config" vbox.cfg
1757 +
1758 + # Set the correct libdir
1759 + sed \
1760 + -e "s@MY_LIBDIR@$(get_libdir)@" \
1761 + -i "${ED%/}"/etc/vbox/vbox.cfg || die "vbox.cfg sed failed"
1762 +
1763 + # Install the wrapper script
1764 + exeinto ${vbox_inst_path}
1765 + newexe "${FILESDIR}/${PN}-ose-5-wrapper" "VBox"
1766 + fowners root:vboxusers ${vbox_inst_path}/VBox
1767 + fperms 0750 ${vbox_inst_path}/VBox
1768 +
1769 + # Install binaries and libraries
1770 + insinto ${vbox_inst_path}
1771 + doins -r components
1772 +
1773 + # *.rc files for x86_64 are only available on multilib systems
1774 + local rcfiles="*.rc"
1775 + if use amd64 && ! has_multilib_profile ; then
1776 + rcfiles=""
1777 + fi
1778 + for each in VBox{ExtPackHelperApp,Manage,SVC,Tunctl,XPCOMIPCD} *so *r0 ${rcfiles} ; do
1779 + vbox_inst ${each}
1780 + done
1781 +
1782 + # These binaries need to be suid root.
1783 + for each in VBox{Headless,Net{AdpCtl,DHCP,NAT}} ; do
1784 + vbox_inst ${each} 4750
1785 + done
1786 +
1787 + # Install EFI Firmware files (bug #320757)
1788 + pushd "${S}"/src/VBox/Devices/EFI/FirmwareBin &>/dev/null || die
1789 + for fwfile in VBoxEFI{32,64}.fd ; do
1790 + vbox_inst ${fwfile} 0644
1791 + done
1792 + popd &>/dev/null || die
1793 +
1794 + # VBoxSVC and VBoxManage need to be pax-marked (bug #403453)
1795 + # VBoxXPCOMIPCD (bug #524202)
1796 + for each in VBox{Headless,Manage,SVC,XPCOMIPCD} ; do
1797 + pax-mark -m "${ED%/}"${vbox_inst_path}/${each}
1798 + done
1799 +
1800 + # Symlink binaries to the shipped wrapper
1801 + for each in vbox{headless,manage} VBox{Headless,Manage,VRDP} ; do
1802 + dosym ${vbox_inst_path}/VBox /usr/bin/${each}
1803 + done
1804 + dosym ${vbox_inst_path}/VBoxTunctl /usr/bin/VBoxTunctl
1805 +
1806 + if use pam ; then
1807 + # VRDPAuth only works with this (bug #351949)
1808 + dosym VBoxAuth.so ${vbox_inst_path}/VRDPAuth.so
1809 + fi
1810 +
1811 + # set an env-variable for 3rd party tools
1812 + echo -n "VBOX_APP_HOME=${vbox_inst_path}" > "${T}/90virtualbox"
1813 + doenvd "${T}/90virtualbox"
1814 +
1815 + if ! use headless ; then
1816 + vbox_inst VBoxSDL 4750
1817 + pax-mark -m "${ED%/}"${vbox_inst_path}/VBoxSDL
1818 +
1819 + for each in vboxsdl VBoxSDL ; do
1820 + dosym ${vbox_inst_path}/VBox /usr/bin/${each}
1821 + done
1822 +
1823 + if use qt5 ; then
1824 + vbox_inst VirtualBox 4750
1825 + pax-mark -m "${ED%/}"${vbox_inst_path}/VirtualBox
1826 +
1827 + if use opengl ; then
1828 + vbox_inst VBoxTestOGL
1829 + pax-mark -m "${ED%/}"${vbox_inst_path}/VBoxTestOGL
1830 + fi
1831 +
1832 + for each in virtualbox VirtualBox ; do
1833 + dosym ${vbox_inst_path}/VBox /usr/bin/${each}
1834 + done
1835 +
1836 + insinto /usr/share/${PN}
1837 + doins -r nls
1838 + doins -r UnattendedTemplates
1839 +
1840 + newmenu "${FILESDIR}"/${PN}-ose.desktop-2 ${PN}.desktop
1841 + fi
1842 +
1843 + pushd "${S}"/src/VBox/Artwork/OSE &>/dev/null || die
1844 + for size in 16 32 48 64 128 ; do
1845 + newicon -s ${size} ${PN}-${size}px.png ${PN}.png
1846 + done
1847 + newicon ${PN}-48px.png ${PN}.png
1848 + doicon -s scalable ${PN}.svg
1849 + popd &>/dev/null || die
1850 + pushd "${S}"/src/VBox/Artwork/other &>/dev/null || die
1851 + for size in 16 24 32 48 64 72 96 128 256 512 ; do
1852 + for ico in hdd ova ovf vbox{,-extpack} vdi vdh vmdk ; do
1853 + icofile="${PN}-${ico}-${size}px.png"
1854 + if [[ -f "${icofile}" ]] ; then
1855 + newicon -s ${size} ${icofile} ${PN}-${ico}.png
1856 + fi
1857 + done
1858 + done
1859 + popd &>/dev/null || die
1860 + fi
1861 +
1862 + if use lvm ; then
1863 + vbox_inst VBoxVolInfo 4750
1864 + dosym ${vbox_inst_path}/VBoxVolInfo /usr/bin/VBoxVolInfo
1865 + fi
1866 +
1867 + if use sdk ; then
1868 + insinto ${vbox_inst_path}
1869 + doins -r sdk
1870 +
1871 + if use java ; then
1872 + java-pkg_regjar "${ED%/}/${vbox_inst_path}/sdk/bindings/xpcom/java/vboxjxpcom.jar"
1873 + java-pkg_regso "${ED%/}/${vbox_inst_path}/libvboxjxpcom.so"
1874 + fi
1875 + fi
1876 +
1877 + if use udev ; then
1878 + # New way of handling USB device nodes for VBox (bug #356215)
1879 + local udevdir="$(get_udevdir)"
1880 + insinto ${udevdir}
1881 + doins VBoxCreateUSBNode.sh
1882 + fowners root:vboxusers ${udevdir}/VBoxCreateUSBNode.sh
1883 + fperms 0750 ${udevdir}/VBoxCreateUSBNode.sh
1884 + insinto ${udevdir}/rules.d
1885 + sed "s@%UDEVDIR%@${udevdir}@" "${FILESDIR}"/10-virtualbox.rules \
1886 + > "${T}"/10-virtualbox.rules || die
1887 + doins "${T}"/10-virtualbox.rules
1888 + fi
1889 +
1890 + if use vboxwebsrv ; then
1891 + vbox_inst vboxwebsrv
1892 + dosym ${vbox_inst_path}/VBox /usr/bin/vboxwebsrv
1893 + newinitd "${FILESDIR}"/vboxwebsrv-initd vboxwebsrv
1894 + newconfd "${FILESDIR}"/vboxwebsrv-confd vboxwebsrv
1895 + fi
1896 +
1897 + if use doc ; then
1898 + dodoc UserManual.pdf
1899 + fi
1900 +
1901 + newtmpfiles "${FILESDIR}"/${PN}-vboxusb_tmpfilesd ${PN}-vboxusb.conf
1902 +}
1903 +
1904 +pkg_postinst() {
1905 + gnome2_icon_cache_update
1906 + xdg_desktop_database_update
1907 +
1908 + if use udev ; then
1909 + udevadm control --reload-rules \
1910 + && udevadm trigger --subsystem-match=usb
1911 + fi
1912 +
1913 + tmpfiles_process /usr/lib/tmpfiles.d/virtualbox-vboxusb.conf
1914 +
1915 + if ! use headless && use qt5 ; then
1916 + elog "To launch VirtualBox just type: \"virtualbox\"."
1917 + fi
1918 + elog "You must be in the vboxusers group to use VirtualBox."
1919 + elog ""
1920 + elog "The latest user manual is available for download at:"
1921 + elog "http://download.virtualbox.org/virtualbox/${PV}/UserManual.pdf"
1922 + elog ""
1923 + elog "For advanced networking setups you should emerge:"
1924 + elog "net-misc/bridge-utils and sys-apps/usermode-utilities"
1925 + elog ""
1926 + elog "Starting with version 4.0.0, ${PN} has USB-1 support."
1927 + elog "For USB-2 support, PXE-boot ability and VRDP support please emerge"
1928 + elog " app-emulation/virtualbox-extpack-oracle"
1929 + elog "package."
1930 + elog "Starting with version 5.0.0, ${PN} no longer has the \"additions\" and"
1931 + elog "the \"extension\" USE flag. For installation of the guest additions ISO"
1932 + elog "image, please emerge"
1933 + elog " app-emulation/virtualbox-additions"
1934 + elog "and for the USB2, USB3, VRDP and PXE boot ROM modules, please emerge"
1935 + elog " app-emulation/virtualbox-extpack-oracle"
1936 + if ! use udev ; then
1937 + elog ""
1938 + elog "WARNING!"
1939 + elog "Without USE=udev, USB devices will likely not work in ${PN}."
1940 + elif [ -e "${ROOT%/}/etc/udev/rules.d/10-virtualbox.rules" ] ; then
1941 + elog ""
1942 + elog "Please remove \"${ROOT%/}/etc/udev/rules.d/10-virtualbox.rules\""
1943 + elog "or else USB in ${PN} won't work."
1944 + fi
1945 +}
1946 +
1947 +pkg_postrm() {
1948 + gnome2_icon_cache_update
1949 + xdg_desktop_database_update
1950 +}
1951
1952 diff --git a/app-emulation/virtualbox/virtualbox-6.0.2.ebuild b/app-emulation/virtualbox/virtualbox-6.0.2.ebuild
1953 new file mode 100644
1954 index 00000000000..77317e5778d
1955 --- /dev/null
1956 +++ b/app-emulation/virtualbox/virtualbox-6.0.2.ebuild
1957 @@ -0,0 +1,483 @@
1958 +# Copyright 1999-2019 Gentoo Authors
1959 +# Distributed under the terms of the GNU General Public License v2
1960 +
1961 +EAPI=6
1962 +
1963 +PYTHON_COMPAT=( python2_7 )
1964 +inherit flag-o-matic gnome2-utils java-pkg-opt-2 linux-info pax-utils python-single-r1 tmpfiles toolchain-funcs udev xdg-utils
1965 +
1966 +MY_PV="${PV/beta/BETA}"
1967 +MY_PV="${MY_PV/rc/RC}"
1968 +MY_P=VirtualBox-${MY_PV}
1969 +
1970 +DESCRIPTION="Family of powerful x86 virtualization products for enterprise and home use"
1971 +HOMEPAGE="https://www.virtualbox.org/"
1972 +SRC_URI="https://download.virtualbox.org/virtualbox/${MY_PV}/${MY_P}.tar.bz2
1973 + https://dev.gentoo.org/~polynomial-c/${PN}/patchsets/${PN}-6.0.0_beta2-patches-01.tar.xz"
1974 +
1975 +LICENSE="GPL-2"
1976 +SLOT="0"
1977 +[[ "${PV}" == *_beta* ]] || [[ "${PV}" == *_rc* ]] || \
1978 +KEYWORDS="~amd64 ~x86"
1979 +IUSE="alsa debug doc headless java libressl lvm +opus pam pax_kernel pulseaudio +opengl python +qt5 +sdk +udev vboxwebsrv vnc"
1980 +
1981 +RDEPEND="!app-emulation/virtualbox-bin
1982 + ~app-emulation/virtualbox-modules-${PV}
1983 + dev-libs/libIDL
1984 + >=dev-libs/libxslt-1.1.19
1985 + net-misc/curl
1986 + dev-libs/libxml2
1987 + media-libs/libpng:0=
1988 + media-libs/libvpx:0=
1989 + sys-libs/zlib:=
1990 + !headless? (
1991 + media-libs/libsdl:0[X,video]
1992 + x11-libs/libX11
1993 + x11-libs/libxcb:=
1994 + x11-libs/libXcursor
1995 + x11-libs/libXext
1996 + x11-libs/libXmu
1997 + x11-libs/libXt
1998 + opengl? ( virtual/opengl media-libs/freeglut )
1999 + qt5? (
2000 + dev-qt/qtcore:5
2001 + dev-qt/qtgui:5
2002 + dev-qt/qtprintsupport:5
2003 + dev-qt/qtwidgets:5
2004 + dev-qt/qtx11extras:5
2005 + opengl? ( dev-qt/qtopengl:5 )
2006 + x11-libs/libXinerama
2007 + )
2008 + )
2009 + libressl? ( dev-libs/libressl:= )
2010 + !libressl? ( dev-libs/openssl:0= )
2011 + lvm? ( sys-fs/lvm2 )
2012 + opus? ( media-libs/opus )
2013 + udev? ( >=virtual/udev-171 )
2014 + vnc? ( >=net-libs/libvncserver-0.9.9 )"
2015 +DEPEND="${RDEPEND}
2016 + >=dev-util/kbuild-0.1.9998.3127
2017 + >=dev-lang/yasm-0.6.2
2018 + sys-devel/bin86
2019 + sys-libs/libcap
2020 + sys-power/iasl
2021 + virtual/pkgconfig
2022 + alsa? ( >=media-libs/alsa-lib-1.0.13 )
2023 + doc? (
2024 + app-text/docbook-sgml-dtd:4.4
2025 + dev-texlive/texlive-basic
2026 + dev-texlive/texlive-latex
2027 + dev-texlive/texlive-latexrecommended
2028 + dev-texlive/texlive-latexextra
2029 + dev-texlive/texlive-fontsrecommended
2030 + dev-texlive/texlive-fontsextra
2031 + )
2032 + !headless? ( x11-libs/libXinerama )
2033 + java? ( >=virtual/jdk-1.6 )
2034 + pam? ( sys-libs/pam )
2035 + pax_kernel? ( sys-apps/elfix )
2036 + pulseaudio? ( media-sound/pulseaudio )
2037 + qt5? ( dev-qt/linguist-tools:5 )
2038 + vboxwebsrv? ( net-libs/gsoap[-gnutls(-)] )
2039 + ${PYTHON_DEPS}"
2040 +RDEPEND="${RDEPEND}
2041 + java? ( >=virtual/jre-1.6 )"
2042 +
2043 +QA_TEXTRELS_x86="usr/lib/virtualbox-ose/VBoxGuestPropSvc.so
2044 + usr/lib/virtualbox/VBoxSDL.so
2045 + usr/lib/virtualbox/VBoxSharedFolders.so
2046 + usr/lib/virtualbox/VBoxDD2.so
2047 + usr/lib/virtualbox/VBoxOGLrenderspu.so
2048 + usr/lib/virtualbox/VBoxPython.so
2049 + usr/lib/virtualbox/VBoxDD.so
2050 + usr/lib/virtualbox/VBoxDDU.so
2051 + usr/lib/virtualbox/VBoxREM64.so
2052 + usr/lib/virtualbox/VBoxSharedClipboard.so
2053 + usr/lib/virtualbox/VBoxHeadless.so
2054 + usr/lib/virtualbox/VBoxRT.so
2055 + usr/lib/virtualbox/VBoxREM.so
2056 + usr/lib/virtualbox/VBoxSettings.so
2057 + usr/lib/virtualbox/VBoxKeyboard.so
2058 + usr/lib/virtualbox/VBoxSharedCrOpenGL.so
2059 + usr/lib/virtualbox/VBoxVMM.so
2060 + usr/lib/virtualbox/VirtualBox.so
2061 + usr/lib/virtualbox/VBoxOGLhosterrorspu.so
2062 + usr/lib/virtualbox/components/VBoxC.so
2063 + usr/lib/virtualbox/components/VBoxSVCM.so
2064 + usr/lib/virtualbox/components/VBoxDDU.so
2065 + usr/lib/virtualbox/components/VBoxRT.so
2066 + usr/lib/virtualbox/components/VBoxREM.so
2067 + usr/lib/virtualbox/components/VBoxVMM.so
2068 + usr/lib/virtualbox/VBoxREM32.so
2069 + usr/lib/virtualbox/VBoxPython2_7.so
2070 + usr/lib/virtualbox/VBoxXPCOMC.so
2071 + usr/lib/virtualbox/VBoxOGLhostcrutil.so
2072 + usr/lib/virtualbox/VBoxNetDHCP.so
2073 + usr/lib/virtualbox/VBoxNetNAT.so"
2074 +
2075 +S="${WORKDIR}/${MY_P}"
2076 +
2077 +REQUIRED_USE="
2078 + java? ( sdk )
2079 + python? ( sdk )
2080 + vboxwebsrv? ( java )
2081 + ${PYTHON_REQUIRED_USE}
2082 +"
2083 +
2084 +pkg_pretend() {
2085 + if ! use headless && ! use qt5 ; then
2086 + einfo "No USE=\"qt5\" selected, this build will not include any Qt frontend."
2087 + elif use headless && use qt5 ; then
2088 + einfo "You selected USE=\"headless qt5\", defaulting to"
2089 + einfo "USE=\"headless\", this build will not include any X11/Qt frontend."
2090 + fi
2091 +
2092 + if ! use opengl ; then
2093 + einfo "No USE=\"opengl\" selected, this build will lack"
2094 + einfo "the OpenGL feature."
2095 + fi
2096 + if ! use python ; then
2097 + einfo "You have disabled the \"python\" USE flag. This will only"
2098 + einfo "disable the python bindings being installed."
2099 + fi
2100 +}
2101 +
2102 +pkg_setup() {
2103 + java-pkg-opt-2_pkg_setup
2104 + python-single-r1_pkg_setup
2105 +
2106 + tc-ld-disable-gold #bug 488176
2107 + tc-export CC CXX LD AR RANLIB
2108 + export HOST_CC="$(tc-getBUILD_CC)"
2109 +}
2110 +
2111 +src_prepare() {
2112 + # Remove shipped binaries (kBuild,yasm), see bug #232775
2113 + rm -r kBuild/bin tools || die
2114 +
2115 + # Replace pointless GCC version check with something less stupid.
2116 + # This is needed for the qt5 version check.
2117 + sed -e 's@^check_gcc$@cc_maj="$(gcc -dumpversion | cut -d. -f1)" ; cc_min="$(gcc -dumpversion | cut -d. -f2)"@' \
2118 + -i configure || die
2119 +
2120 + # Disable things unused or split into separate ebuilds
2121 + sed -e "s@MY_LIBDIR@$(get_libdir)@" \
2122 + "${FILESDIR}"/${PN}-5-localconfig > LocalConfig.kmk || die
2123 +
2124 + # Respect LDFLAGS
2125 + sed -e "s@_LDFLAGS\.${ARCH}*.*=@& ${LDFLAGS}@g" \
2126 + -i Config.kmk src/libs/xpcom18a4/Config.kmk || die
2127 +
2128 + # Do not use hard-coded ld (related to bug #488176)
2129 + sed -e '/QUIET)ld /s@ld @$(LD) @' \
2130 + -i src/VBox/Devices/PC/ipxe/Makefile.kmk || die
2131 +
2132 + # Use PAM only when pam USE flag is enbaled (bug #376531)
2133 + if ! use pam ; then
2134 + elog "Disabling PAM removes the possibility to use the VRDP features."
2135 + sed -i 's@^.*VBOX_WITH_PAM@#VBOX_WITH_PAM@' Config.kmk || die
2136 + sed -i 's@\(.*/auth/Makefile.kmk.*\)@#\1@' \
2137 + src/VBox/HostServices/Makefile.kmk || die
2138 + fi
2139 +
2140 + # add correct java path
2141 + if use java ; then
2142 + sed "s@/usr/lib/jvm/java-6-sun@$(java-config -O)@" \
2143 + -i "${S}"/Config.kmk || die
2144 + java-pkg-opt-2_src_prepare
2145 + fi
2146 +
2147 + # Only add nopie patch when we're on hardened
2148 + if gcc-specs-pie ; then
2149 + eapply "${FILESDIR}/050_virtualbox-5.2.8-nopie.patch"
2150 + fi
2151 +
2152 + # Only add paxmark patch when we're on pax_kernel
2153 + if use pax_kernel ; then
2154 + eapply "${FILESDIR}"/virtualbox-5.2.8-paxmark-bldprogs.patch
2155 + fi
2156 +
2157 + rm "${WORKDIR}/patches/010_virtualbox-5.2.12-qt511.patch" || die
2158 + eapply "${WORKDIR}/patches"
2159 +
2160 + eapply_user
2161 +}
2162 +
2163 +doecho() {
2164 + echo "$@"
2165 + "$@" || die
2166 +}
2167 +
2168 +src_configure() {
2169 + local myconf=(
2170 + --with-gcc="$(tc-getCC)"
2171 + --with-g++="$(tc-getCXX)"
2172 + --disable-dbus
2173 + --disable-kmods
2174 + $(usex alsa '' --disable-alsa)
2175 + $(usex debug --build-debug '')
2176 + $(usex doc '' --disable-docs)
2177 + $(usex java '' --disable-java)
2178 + $(usex lvm '' --disable-devmapper)
2179 + $(usex opus '' --disable-libopus)
2180 + $(usex pulseaudio '' --disable-pulse)
2181 + $(usex python '' --disable-python)
2182 + $(usex vboxwebsrv --enable-webservice '')
2183 + $(usex vnc --enable-vnc '')
2184 + )
2185 + if ! use headless ; then
2186 + myconf+=(
2187 + $(usex opengl '' --disable-opengl)
2188 + $(usex qt5 '' --disable-qt)
2189 + )
2190 + else
2191 + myconf+=(
2192 + --build-headless
2193 + --disable-opengl
2194 + )
2195 + fi
2196 + if use amd64 && ! has_multilib_profile ; then
2197 + myconf+=( --disable-vmmraw )
2198 + fi
2199 + # not an autoconf script
2200 + doecho ./configure ${myconf[@]}
2201 +}
2202 +
2203 +src_compile() {
2204 + source ./env.sh || die
2205 +
2206 + # Force kBuild to respect C[XX]FLAGS and MAKEOPTS (bug #178529)
2207 + MAKEJOBS=$(grep -Eo '(\-j|\-\-jobs)(=?|[[:space:]]*)[[:digit:]]+' <<< ${MAKEOPTS}) #'
2208 + MAKELOAD=$(grep -Eo '(\-l|\-\-load-average)(=?|[[:space:]]*)[[:digit:]]+' <<< ${MAKEOPTS}) #'
2209 + MAKEOPTS="${MAKEJOBS} ${MAKELOAD}"
2210 + MAKE="kmk" emake \
2211 + VBOX_BUILD_PUBLISHER=_Gentoo \
2212 + TOOL_GCC3_CC="$(tc-getCC)" TOOL_GCC3_CXX="$(tc-getCXX)" \
2213 + TOOL_GCC3_AS="$(tc-getCC)" TOOL_GCC3_AR="$(tc-getAR)" \
2214 + TOOL_GCC3_LD="$(tc-getCXX)" TOOL_GCC3_LD_SYSMOD="$(tc-getLD)" \
2215 + TOOL_GCC3_CFLAGS="${CFLAGS}" TOOL_GCC3_CXXFLAGS="${CXXFLAGS}" \
2216 + VBOX_GCC_OPT="${CXXFLAGS}" \
2217 + TOOL_YASM_AS=yasm KBUILD_VERBOSE=2 \
2218 + all
2219 +}
2220 +
2221 +src_install() {
2222 + local binpath="release"
2223 + use debug && binpath="debug"
2224 + cd "${S}"/out/linux.${ARCH}/${binpath}/bin || die
2225 +
2226 + local vbox_inst_path="/usr/$(get_libdir)/${PN}" each size ico icofile
2227 +
2228 + vbox_inst() {
2229 + local binary="${1}"
2230 + local perms="${2:-0750}"
2231 + local path="${3:-${vbox_inst_path}}"
2232 +
2233 + [[ -n "${binary}" ]] || die "vbox_inst: No binary given!"
2234 + [[ ${perms} =~ ^[[:digit:]]+{4}$ ]] || die "vbox_inst: perms must consist of four digits."
2235 +
2236 + insinto ${path}
2237 + doins ${binary}
2238 + fowners root:vboxusers ${path}/${binary}
2239 + fperms ${perms} ${path}/${binary}
2240 + }
2241 +
2242 + # Create configuration files
2243 + insinto /etc/vbox
2244 + newins "${FILESDIR}/${PN}-4-config" vbox.cfg
2245 +
2246 + # Set the correct libdir
2247 + sed \
2248 + -e "s@MY_LIBDIR@$(get_libdir)@" \
2249 + -i "${ED%/}"/etc/vbox/vbox.cfg || die "vbox.cfg sed failed"
2250 +
2251 + # Install the wrapper script
2252 + exeinto ${vbox_inst_path}
2253 + newexe "${FILESDIR}/${PN}-ose-6-wrapper" "VBox"
2254 + fowners root:vboxusers ${vbox_inst_path}/VBox
2255 + fperms 0750 ${vbox_inst_path}/VBox
2256 +
2257 + # Install binaries and libraries
2258 + insinto ${vbox_inst_path}
2259 + doins -r components
2260 +
2261 + # *.rc files for x86_64 are only available on multilib systems
2262 + local rcfiles="*.rc"
2263 + if use amd64 && ! has_multilib_profile ; then
2264 + rcfiles=""
2265 + fi
2266 + for each in VBox{Autostart,BalloonCtrl,BugReport,CpuReport,ExtPackHelperApp,Manage,SVC,Tunctl,VMMPreload,XPCOMIPCD} *so *r0 ${rcfiles} iPxeBaseBin rdesktop-vrdp ; do
2267 + vbox_inst ${each}
2268 + done
2269 +
2270 + # These binaries need to be suid root.
2271 + for each in VBox{Headless,Net{AdpCtl,DHCP,NAT}} ; do
2272 + vbox_inst ${each} 4750
2273 + done
2274 +
2275 + # Install EFI Firmware files (bug #320757)
2276 + for each in VBoxEFI{32,64}.fd ; do
2277 + vbox_inst ${each} 0644
2278 + done
2279 +
2280 + # VBoxSVC and VBoxManage need to be pax-marked (bug #403453)
2281 + # VBoxXPCOMIPCD (bug #524202)
2282 + for each in VBox{Headless,Manage,SVC,XPCOMIPCD} ; do
2283 + pax-mark -m "${ED%/}"${vbox_inst_path}/${each}
2284 + done
2285 +
2286 + # Symlink binaries to the shipped wrapper
2287 + for each in vbox{autostart,balloonctrl,bugreport,headless,manage} VBox{Autostart,BalloonCtrl,BugReport,Headless,Manage,VRDP} ; do
2288 + dosym ${vbox_inst_path}/VBox /usr/bin/${each}
2289 + done
2290 + dosym ${vbox_inst_path}/VBoxTunctl /usr/bin/VBoxTunctl
2291 +
2292 + if use pam ; then
2293 + # VRDPAuth only works with this (bug #351949)
2294 + dosym VBoxAuth.so ${vbox_inst_path}/VRDPAuth.so
2295 + fi
2296 +
2297 + # set an env-variable for 3rd party tools
2298 + echo -n "VBOX_APP_HOME=${vbox_inst_path}" > "${T}/90virtualbox"
2299 + doenvd "${T}/90virtualbox"
2300 +
2301 + if ! use headless ; then
2302 + vbox_inst VBoxSDL 4750
2303 + pax-mark -m "${ED%/}"${vbox_inst_path}/VBoxSDL
2304 +
2305 + for each in vboxsdl VBoxSDL ; do
2306 + dosym ${vbox_inst_path}/VBox /usr/bin/${each}
2307 + done
2308 +
2309 + if use qt5 ; then
2310 + vbox_inst VirtualBox
2311 + vbox_inst VirtualBoxVM 4750
2312 + for each in VirtualBox{,VM} ; do
2313 + pax-mark -m "${ED%/}"${vbox_inst_path}/${each}
2314 + done
2315 +
2316 + if use opengl ; then
2317 + vbox_inst VBoxTestOGL
2318 + pax-mark -m "${ED%/}"${vbox_inst_path}/VBoxTestOGL
2319 + fi
2320 +
2321 + #for each in virtualbox{,vm} VirtualBox{,VM} ; do
2322 + for each in virtualbox VirtualBox ; do
2323 + dosym ${vbox_inst_path}/VBox /usr/bin/${each}
2324 + done
2325 +
2326 + insinto /usr/share/${PN}
2327 + doins -r nls
2328 + doins -r UnattendedTemplates
2329 +
2330 + domenu ${PN}.desktop
2331 + fi
2332 +
2333 + pushd "${S}"/src/VBox/Artwork/OSE &>/dev/null || die
2334 + for size in 16 32 48 64 128 ; do
2335 + newicon -s ${size} ${PN}-${size}px.png ${PN}.png
2336 + done
2337 + newicon ${PN}-48px.png ${PN}.png
2338 + doicon -s scalable ${PN}.svg
2339 + popd &>/dev/null || die
2340 + pushd "${S}"/src/VBox/Artwork/other &>/dev/null || die
2341 + for size in 16 24 32 48 64 72 96 128 256 512 ; do
2342 + for ico in hdd ova ovf vbox{,-extpack} vdi vdh vmdk ; do
2343 + icofile="${PN}-${ico}-${size}px.png"
2344 + if [[ -f "${icofile}" ]] ; then
2345 + newicon -s ${size} ${icofile} ${PN}-${ico}.png
2346 + fi
2347 + done
2348 + done
2349 + popd &>/dev/null || die
2350 + fi
2351 +
2352 + if use lvm ; then
2353 + vbox_inst VBoxVolInfo 4750
2354 + dosym ${vbox_inst_path}/VBoxVolInfo /usr/bin/VBoxVolInfo
2355 + fi
2356 +
2357 + if use sdk ; then
2358 + insinto ${vbox_inst_path}
2359 + doins -r sdk
2360 +
2361 + if use java ; then
2362 + java-pkg_regjar "${ED%/}/${vbox_inst_path}/sdk/bindings/xpcom/java/vboxjxpcom.jar"
2363 + java-pkg_regso "${ED%/}/${vbox_inst_path}/libvboxjxpcom.so"
2364 + fi
2365 + fi
2366 +
2367 + if use udev ; then
2368 + # New way of handling USB device nodes for VBox (bug #356215)
2369 + local udevdir="$(get_udevdir)"
2370 + insinto ${udevdir}
2371 + doins VBoxCreateUSBNode.sh
2372 + fowners root:vboxusers ${udevdir}/VBoxCreateUSBNode.sh
2373 + fperms 0750 ${udevdir}/VBoxCreateUSBNode.sh
2374 + insinto ${udevdir}/rules.d
2375 + sed "s@%UDEVDIR%@${udevdir}@" "${FILESDIR}"/10-virtualbox.rules \
2376 + > "${T}"/10-virtualbox.rules || die
2377 + doins "${T}"/10-virtualbox.rules
2378 + fi
2379 +
2380 + if use vboxwebsrv ; then
2381 + vbox_inst vboxwebsrv
2382 + dosym ${vbox_inst_path}/VBox /usr/bin/vboxwebsrv
2383 + newinitd "${FILESDIR}"/vboxwebsrv-initd vboxwebsrv
2384 + newconfd "${FILESDIR}"/vboxwebsrv-confd vboxwebsrv
2385 + fi
2386 +
2387 + if use doc ; then
2388 + dodoc UserManual.pdf
2389 + fi
2390 +
2391 + newtmpfiles "${FILESDIR}"/${PN}-vboxusb_tmpfilesd ${PN}-vboxusb.conf
2392 +}
2393 +
2394 +pkg_postinst() {
2395 + gnome2_icon_cache_update
2396 + xdg_desktop_database_update
2397 +
2398 + if use udev ; then
2399 + udevadm control --reload-rules \
2400 + && udevadm trigger --subsystem-match=usb
2401 + fi
2402 +
2403 + tmpfiles_process /usr/lib/tmpfiles.d/virtualbox-vboxusb.conf
2404 +
2405 + if ! use headless && use qt5 ; then
2406 + elog "To launch VirtualBox just type: \"virtualbox\"."
2407 + fi
2408 + elog "You must be in the vboxusers group to use VirtualBox."
2409 + elog ""
2410 + elog "The latest user manual is available for download at:"
2411 + elog "http://download.virtualbox.org/virtualbox/${PV}/UserManual.pdf"
2412 + elog ""
2413 + elog "For advanced networking setups you should emerge:"
2414 + elog "net-misc/bridge-utils and sys-apps/usermode-utilities"
2415 + elog ""
2416 + elog "Starting with version 4.0.0, ${PN} has USB-1 support."
2417 + elog "For USB-2 support, PXE-boot ability and VRDP support please emerge"
2418 + elog " app-emulation/virtualbox-extpack-oracle"
2419 + elog "package."
2420 + elog "Starting with version 5.0.0, ${PN} no longer has the \"additions\" and"
2421 + elog "the \"extension\" USE flag. For installation of the guest additions ISO"
2422 + elog "image, please emerge"
2423 + elog " app-emulation/virtualbox-additions"
2424 + elog "and for the USB2, USB3, VRDP and PXE boot ROM modules, please emerge"
2425 + elog " app-emulation/virtualbox-extpack-oracle"
2426 + if ! use udev ; then
2427 + elog ""
2428 + elog "WARNING!"
2429 + elog "Without USE=udev, USB devices will likely not work in ${PN}."
2430 + elif [ -e "${ROOT%/}/etc/udev/rules.d/10-virtualbox.rules" ] ; then
2431 + elog ""
2432 + elog "Please remove \"${ROOT%/}/etc/udev/rules.d/10-virtualbox.rules\""
2433 + elog "or else USB in ${PN} won't work."
2434 + fi
2435 +}
2436 +
2437 +pkg_postrm() {
2438 + gnome2_icon_cache_update
2439 + xdg_desktop_database_update
2440 +}