]>
Commit | Line | Data |
---|---|---|
48363591 | 1 | # |
2 | # TODO: | |
74268e47 | 3 | # - Find how to compile with PLD CFLAGS/CXXFLAGS/LDFLAGS. |
74268e47 | 4 | # - Package SDK. |
09c79ddb | 5 | # - Package utils (and write initscripts ?) for Guest OS. |
5f8b0a92 | 6 | # - Check License of VBoxGuestAdditions_*.iso, it's propably not GPL v2. |
7 | # If so check if it is distributable. | |
48363591 | 8 | # |
9 | # Conditional build: | |
10 | %bcond_without dist_kernel # without distribution kernel | |
d1c4ec5b | 11 | %bcond_without kernel # don't build kernel module |
d1c4ec5b | 12 | %bcond_without userspace # don't build userspace package |
b29bcb41 | 13 | %bcond_with verbose |
05f1b1f5 | 14 | |
ec875ac3 | 15 | %define rel 3 |
05f1b1f5 | 16 | |
8833bce1 | 17 | %if %{without kernel} |
18 | %undefine with_dist_kernel | |
19 | %endif | |
20 | ||
bd3faca3 | 21 | %if "%{_alt_kernel}" != "%{nil}" |
22 | %undefine with_userspace | |
23 | %endif | |
24 | ||
25 | %define pname VirtualBox | |
26 | ||
93ccc0e8 ER |
27 | Summary: VirtualBox OSE - x86 hardware virtualizer |
28 | Summary(pl.UTF-8): VirtualBox OSE - wirtualizator sprzętu x86 | |
bd3faca3 | 29 | Name: %{pname}%{_alt_kernel} |
a8a4385f | 30 | Version: 2.0.0 |
fe3d1798 | 31 | Release: %{rel} |
48363591 | 32 | License: GPL v2 |
33 | Group: Applications/Emulators | |
ec9242f0 | 34 | Source0: http://download.virtualbox.org/virtualbox/%{version}/%{pname}-%{version}-OSE.tar.bz2 |
a8a4385f | 35 | # Source0-md5: 1f53ebed0f55df129f6cf72dba646c3a |
e0b337ae | 36 | Source1: http://download.virtualbox.org/virtualbox/%{version}/UserManual.pdf |
a8a4385f | 37 | # Source1-md5: cf65a8164a18f7200520c1ec3399a918 |
38 | Source2: http://download.virtualbox.org/virtualbox/%{version}/VBoxGuestAdditions_%{version}.iso | |
39 | # Source2-md5: ae0512b8db853fdea9fc262fc04bd242 | |
67ad4c40 | 40 | Source3: %{pname}-vboxdrv.init |
41 | Source4: %{pname}-vboxadd.init | |
42 | Source5: %{pname}.desktop | |
43 | Source6: %{pname}.sh | |
bd3faca3 | 44 | Patch0: %{pname}-configure.patch |
45 | Patch1: %{pname}-qt-paths.patch | |
46 | Patch2: %{pname}-shared-libstdc++.patch | |
47 | Patch3: %{pname}-disable-xclient-build.patch | |
fddcb741 | 48 | Patch4: %{pname}-configure-spaces.patch |
ecace9c3 | 49 | Patch5: %{pname}-svn_fixes.patch |
48363591 | 50 | URL: http://www.virtualbox.org/ |
83ffcfa8 | 51 | %if %{with userspace} |
523e7409 | 52 | BuildRequires: OpenGL-devel |
cef75615 | 53 | BuildRequires: QtGui-devel |
c574efad | 54 | BuildRequires: SDL-devel >= 1.2.7 |
ba702945 | 55 | BuildRequires: alsa-lib-devel >= 1.0.6 |
e5aaadde | 56 | BuildRequires: bash |
48363591 | 57 | BuildRequires: bcc |
58 | BuildRequires: bin86 | |
eba4b2aa | 59 | BuildRequires: gcc >= 5:3.2.3 |
ae1bbc88 | 60 | %if "%{pld_release}" != "ti" |
b29bcb41 | 61 | BuildRequires: compat-gcc-34 |
ae1bbc88 | 62 | %endif |
48363591 | 63 | BuildRequires: iasl |
83ffcfa8 | 64 | %endif |
0d1f6cd5 AM |
65 | %if %{with dist_kernel} |
66 | BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.20 | |
0d1f6cd5 | 67 | %endif |
83ffcfa8 | 68 | %if %{with userspace} |
48363591 | 69 | BuildRequires: libIDL-devel |
ba702945 | 70 | BuildRequires: libpng >= 1.2.5 |
d22f0a53 | 71 | BuildRequires: libstdc++-devel >= 5:3.2.3 |
48363591 | 72 | BuildRequires: libuuid-devel |
ba702945 | 73 | BuildRequires: libxml2-devel >= 2.6.26 |
76ea5ecb | 74 | BuildRequires: libxslt-devel >= 1.1.17 |
ba702945 | 75 | BuildRequires: libxslt-progs >= 1.1.17 |
0bf43862 | 76 | BuildRequires: pkgconfig |
ba702945 | 77 | BuildRequires: pulseaudio-devel >= 0.9.0 |
523e7409 | 78 | BuildRequires: python-devel |
250583d4 | 79 | BuildRequires: qt4-build >= 4.2.0 |
2700662b | 80 | BuildRequires: qt4-linguist |
83ffcfa8 | 81 | %endif |
82 | BuildRequires: rpmbuild(macros) >= 1.379 | |
83 | %if %{with userspace} | |
0bf43862 | 84 | BuildRequires: which |
e5aaadde | 85 | BuildRequires: xalan-c-devel >= 1.10.0 |
e5aaadde | 86 | BuildRequires: xerces-c-devel >= 2.6.0 |
eba4b2aa | 87 | BuildRequires: xorg-lib-libXcursor-devel |
523e7409 | 88 | BuildRequires: xorg-lib-libXmu-devel |
e5aaadde | 89 | BuildRequires: zlib-devel >= 1.2.1 |
23d9d34e | 90 | %ifarch %{x8664} |
91 | BuildRequires: gcc-multilib | |
51d2ebb8 | 92 | BuildRequires: glibc-devel(i686) |
23d9d34e | 93 | BuildRequires: libstdc++-multilib-devel |
23d9d34e | 94 | %endif |
83ffcfa8 | 95 | %endif |
0afa64ad | 96 | Requires(post,preun): /sbin/chkconfig |
5f1cec1f ER |
97 | Requires(postun): /usr/sbin/groupdel |
98 | Requires(pre): /usr/bin/getgid | |
99 | Requires(pre): /usr/sbin/groupadd | |
fb661e50 | 100 | Suggests: gxmessage |
5f1cec1f | 101 | Provides: group(vbox) |
eba4b2aa | 102 | ExclusiveArch: %{ix86} %{x8664} |
48363591 | 103 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
104 | ||
eba4b2aa | 105 | %ifarch %{x8664} |
fe3d1798 | 106 | %define outdir amd64 |
5088674d | 107 | %else |
fe3d1798 | 108 | %define outdir x86 |
5088674d | 109 | %endif |
110 | ||
48363591 | 111 | %description |
93ccc0e8 | 112 | InnoTek VirtualBox OSE is a general-purpose full virtualizer for x86 |
48363591 | 113 | hardware. Targeted at server, desktop and embedded use, it is now the |
114 | only professional-quality virtualization solution that is also Open | |
115 | Source Software. | |
116 | ||
93ccc0e8 | 117 | Some of the features of VirtualBox OSE are: |
48363591 | 118 | |
93ccc0e8 | 119 | Modularity: VirtualBox OSE has an extremely modular design with |
48363591 | 120 | well-defined internal programming interfaces and a client/server |
121 | design. This makes it easy to control it from several interfaces at | |
122 | once: for example, you can start a virtual machine in a typical | |
123 | virtual machine GUI and then control that machine from the command | |
2df47f85 | 124 | line. VirtualBox OSE also comes with a full Software Development Kit: |
125 | even though it is Open Source Software, you don't have to hack the | |
126 | source to write a new interface for VirtualBox OSE. | |
48363591 | 127 | |
128 | Virtual machine descriptions in XML: the configuration settings of | |
129 | virtual machines are stored entirely in XML and are independent of the | |
130 | local machines. Virtual machine definitions can therefore easily be | |
131 | ported to other computers. | |
132 | ||
fd8fc899 | 133 | %description -l pl.UTF-8 |
93ccc0e8 | 134 | InnoTek VirtualBox OSE jest emulatorem sprzętu x86. Kierowany do |
fd8fc899 JR |
135 | zastosowań serwerowych, desktopowych oraz wbudowanych jest obecnie |
136 | jedynym wysokiej jakości rozwiązaniem wirtualizacyjnym dostępnym | |
137 | również jako Otwarte Oprogramowanie. | |
48363591 | 138 | |
fd8fc899 | 139 | Przykładowe cechy VirtualBoksa: |
48363591 | 140 | |
93ccc0e8 | 141 | Modularność: VirtualBox OSE jest wysoce zmodularyzowanym produktem z |
fd8fc899 JR |
142 | dobrze zaprojektowanym wewnętrznym interfejsem programowym typu |
143 | klient/serwer. Dzięki temu można łatwo kontrolować go za pomocą | |
144 | różnych interfejsów. Można na przykład uruchomić maszynę wirtualną z | |
145 | poziomu interfejsu graficznego, a później kontrolować ją z linii | |
2df47f85 | 146 | poleceń. VirtualBox OSE dostarcza również pełny pakiet deweloperski, |
147 | co pozwala stworzyć dowolny inny interfejs zarządzania maszyną | |
148 | wirtualną. | |
48363591 | 149 | |
fd8fc899 JR |
150 | Opisy maszyn wirtualnych w XML-u: konfiguracje poszczególnych maszyn |
151 | wirtualnych są w całości przechowywane w XML-u i są niezależne od | |
152 | lokalnej maszyny. Dzięki temu można szybko i łatwo przenieść | |
153 | konfigurację maszyny wirtualnej na inny komputer. | |
48363591 | 154 | |
abb636b9 | 155 | %package udev |
93ccc0e8 | 156 | Summary: udev rules for VirtualBox OSE kernel modules |
da083e45 | 157 | Summary(pl.UTF-8): Reguły udev dla modułów jądra Linuksa dla VirtualBoksa |
8512deca | 158 | Release: %{rel} |
abb636b9 | 159 | Group: Base/Kernel |
93bf3da1 | 160 | Requires: udev-core |
abb636b9 | 161 | |
162 | %description udev | |
2df47f85 | 163 | udev rules for VirtualBox OSE kernel modules. |
abb636b9 | 164 | |
165 | %description udev -l pl.UTF-8 | |
2df47f85 | 166 | Reguły udev dla modułów jądra Linuksa dla VirtualBoksa. |
abb636b9 | 167 | |
74268e47 | 168 | %package -n kernel%{_alt_kernel}-misc-vboxadd |
93ccc0e8 | 169 | Summary: Linux kernel module for VirtualBox OSE |
74268e47 | 170 | Summary(pl.UTF-8): Moduł jądra Linuksa dla VirtualBoksa |
fe3d1798 | 171 | Release: %{rel}@%{_kernel_ver_str} |
74268e47 | 172 | Group: Base/Kernel |
173 | Requires(post,postun): /sbin/depmod | |
174 | Requires: dev >= 2.9.0-7 | |
175 | %if %{with dist_kernel} | |
176 | %requires_releq_kernel | |
abb636b9 | 177 | #Requires(postun): %%releq_kernel |
74268e47 | 178 | %endif |
fe3d1798 | 179 | Provides: kernel(vboxadd) = %{version}-%{rel} |
74268e47 | 180 | |
181 | %description -n kernel%{_alt_kernel}-misc-vboxadd | |
93ccc0e8 | 182 | Linux kernel module vboxadd for VirtualBox OSE. |
74268e47 | 183 | |
184 | %description -n kernel%{_alt_kernel}-misc-vboxadd -l pl.UTF-8 | |
185 | Moduł jądra Linuksa vboxadd dla VirtualBoksa. | |
186 | ||
48363591 | 187 | %package -n kernel%{_alt_kernel}-misc-vboxdrv |
93ccc0e8 | 188 | Summary: Linux kernel module for VirtualBox OSE |
4dab3322 | 189 | Summary(pl.UTF-8): Moduł jądra Linuksa dla VirtualBoksa |
fe3d1798 | 190 | Release: %{rel}@%{_kernel_ver_str} |
48363591 | 191 | Group: Base/Kernel |
192 | Requires(post,postun): /sbin/depmod | |
193 | Requires: dev >= 2.9.0-7 | |
194 | %if %{with dist_kernel} | |
d6f0c54e | 195 | %requires_releq_kernel |
196 | Requires(postun): %releq_kernel | |
48363591 | 197 | %endif |
fe3d1798 | 198 | Provides: kernel(vboxdrv) = %{version}-%{rel} |
48363591 | 199 | |
200 | %description -n kernel%{_alt_kernel}-misc-vboxdrv | |
93ccc0e8 | 201 | Linux kernel module vboxdrv for VirtualBox OSE. |
48363591 | 202 | |
fd8fc899 JR |
203 | %description -n kernel%{_alt_kernel}-misc-vboxdrv -l pl.UTF-8 |
204 | Moduł jądra Linuksa vboxdrv dla VirtualBoksa. | |
48363591 | 205 | |
74268e47 | 206 | %package -n kernel%{_alt_kernel}-misc-vboxvfs |
93ccc0e8 | 207 | Summary: Linux kernel module for VirtualBox OSE |
74268e47 | 208 | Summary(pl.UTF-8): Moduł jądra Linuksa dla VirtualBoksa |
fe3d1798 | 209 | Release: %{rel}@%{_kernel_ver_str} |
74268e47 | 210 | Group: Base/Kernel |
211 | Requires(post,postun): /sbin/depmod | |
212 | Requires: dev >= 2.9.0-7 | |
213 | %if %{with dist_kernel} | |
214 | %requires_releq_kernel | |
215 | Requires(postun): %releq_kernel | |
216 | %endif | |
fe3d1798 | 217 | Provides: kernel(vboxvfs) = %{version}-%{rel} |
74268e47 | 218 | |
219 | %description -n kernel%{_alt_kernel}-misc-vboxvfs | |
93ccc0e8 | 220 | Linux kernel module vboxvfs for VirtualBox OSE. |
74268e47 | 221 | |
222 | %description -n kernel%{_alt_kernel}-misc-vboxvfs -l pl.UTF-8 | |
223 | Moduł jądra Linuksa vboxvfs dla VirtualBoksa. | |
224 | ||
09c79ddb | 225 | %package -n xorg-driver-input-vboxmouse |
93ccc0e8 | 226 | Summary: X.org mouse driver for VirtualBox OSE guest OS |
fe3d1798 JB |
227 | Summary(pl.UTF-8): Sterownik myszy dla systemu gościa w VirtualBoksie |
228 | Release: %{rel} | |
09c79ddb | 229 | Group: X11/Applications |
230 | Requires: xorg-xserver-server >= 1.0.99.901 | |
231 | ||
232 | %description -n xorg-driver-input-vboxmouse | |
93ccc0e8 | 233 | X.org mouse driver for VirtualBox OSE guest OS. |
09c79ddb | 234 | |
235 | %description -n xorg-driver-input-vboxmouse -l pl.UTF-8 | |
fe3d1798 | 236 | Sterownik myszy dla systemu gościa w VirtualBoksie. |
09c79ddb | 237 | |
238 | %package -n xorg-driver-video-vboxvideo | |
93ccc0e8 | 239 | Summary: X.org video driver for VirtualBox OSE guest OS |
fe3d1798 JB |
240 | Summary(pl.UTF-8): Sterownik grafiki dla systemu gościa w VirtualBoksie |
241 | Release: %{rel} | |
09c79ddb | 242 | Group: X11/Applications |
243 | Requires: xorg-xserver-server >= 1.0.99.901 | |
244 | ||
245 | %description -n xorg-driver-video-vboxvideo | |
93ccc0e8 | 246 | X.org video driver for VirtualBox OSE guest OS. |
09c79ddb | 247 | |
248 | %description -n xorg-driver-video-vboxvideo -l pl.UTF-8 | |
fe3d1798 | 249 | Sterownik grafiki dla systemu gościa w VirtualBoksie. |
09c79ddb | 250 | |
48363591 | 251 | %prep |
deb50564 | 252 | %setup -q -n %{pname}-%{version} |
e709ce6b | 253 | %patch0 -p1 |
254 | %patch1 -p1 | |
74268e47 | 255 | %patch2 -p1 |
23d9d34e | 256 | |
33233365 | 257 | %ifarch %{x8664} |
258 | %patch3 -p1 | |
259 | %endif | |
260 | ||
fddcb741 | 261 | %patch4 -p1 |
ecace9c3 | 262 | %patch5 -p1 |
fddcb741 | 263 | |
33233365 | 264 | cat <<'EOF' > udev.conf |
265 | KERNEL=="vboxdrv", NAME="%k", GROUP="vbox", MODE="0660" | |
67ad4c40 | 266 | KERNEL=="vboxadd", NAME="%k", GROUP="vbox", MODE="0660" |
33233365 | 267 | EOF |
23d9d34e | 268 | |
fdd1c725 | 269 | install %{SOURCE1} . |
fa19f650 | 270 | |
83ffcfa8 | 271 | rm -rf PLD-MODULE-BUILD && mkdir PLD-MODULE-BUILD && cd PLD-MODULE-BUILD |
272 | ../src/VBox/Additions/linux/export_modules modules.tar.gz | |
273 | tar -zxf modules.tar.gz && rm -f modules.tar.gz | |
274 | ../src/VBox/HostDrivers/Support/linux/export_modules modules.tar.gz && \ | |
275 | tar -zxf modules.tar.gz && rm -f modules.tar.gz | |
05f1b1f5 | 276 | |
fddcb741 | 277 | %build |
83ffcfa8 | 278 | %if %{with userspace} |
106d8451 | 279 | ./configure \ |
ae1bbc88 | 280 | --with-gcc="%{__cc}" \ |
2700662b | 281 | %if "%{pld_release}" != "ti" |
282 | --with-gcc-compat="gcc-3.4" \ | |
283 | %endif | |
ae1bbc88 | 284 | --with-g++="%{__cxx}" \ |
5a497466 | 285 | --disable-hardening \ |
286 | --disable-kmods \ | |
287 | --disable-qt3 | |
48363591 | 288 | |
0864aefd | 289 | . ./env.sh && \ |
c6fdbed7 | 290 | kmk -j1 %{?with_verbose:KBUILD_VERBOSE=3} |
48363591 | 291 | %endif |
74268e47 | 292 | |
293 | %if %{with kernel} | |
83ffcfa8 | 294 | cd PLD-MODULE-BUILD |
74268e47 | 295 | %build_kernel_modules -m vboxadd -C vboxadd |
296 | %build_kernel_modules -m vboxdrv -C vboxdrv | |
0da669b5 | 297 | cp -a vboxadd/Module.symvers vboxvfs |
83ffcfa8 | 298 | %build_kernel_modules -m vboxvfs -C vboxvfs -c |
74268e47 | 299 | cd .. |
d1c4ec5b | 300 | %endif |
48363591 | 301 | |
302 | %install | |
303 | rm -rf $RPM_BUILD_ROOT | |
304 | ||
d1c4ec5b | 305 | %if %{with userspace} |
48363591 | 306 | install -d \ |
d89980c7 | 307 | $RPM_BUILD_ROOT{%{_bindir},%{_pixmapsdir},%{_desktopdir}} \ |
67ad4c40 | 308 | $RPM_BUILD_ROOT%{_libdir}/VirtualBox |
a70507fb | 309 | |
67ad4c40 | 310 | install %{SOURCE6} $RPM_BUILD_ROOT%{_libdir}/VirtualBox/VirtualBox-wrapper.sh |
d9390c3b | 311 | for f in {VBox{BFE,Headless,Manage,SDL,SVC,Tunctl,XPCOMIPCD},VirtualBox,vditool}; do |
fe3d1798 | 312 | install out/linux.%{outdir}/release/bin/$f $RPM_BUILD_ROOT%{_libdir}/VirtualBox/$f |
fdd1c725 | 313 | ln -s %{_libdir}/VirtualBox/VirtualBox-wrapper.sh $RPM_BUILD_ROOT%{_bindir}/$f |
05f1b1f5 | 314 | done |
315 | ||
9a6c7384 AM |
316 | %ifarch %{x8664} |
317 | install out/linux.%{outdir}/release/bin/VBox*.rel \ | |
318 | $RPM_BUILD_ROOT%{_libdir}/VirtualBox | |
319 | %endif | |
320 | ||
5a497466 | 321 | install out/linux.%{outdir}/release/bin/VBox*.so \ |
48363591 | 322 | $RPM_BUILD_ROOT%{_libdir}/VirtualBox |
d9390c3b | 323 | install out/linux.%{outdir}/release/bin/{VBox{DD,DD2}{GC.gc,R0.r0},VMM{GC.gc,R0.r0}} \ |
48363591 | 324 | $RPM_BUILD_ROOT%{_libdir}/VirtualBox |
325 | ||
916ab34d | 326 | install -d $RPM_BUILD_ROOT%{_libdir}/VirtualBox/additions |
8833bce1 | 327 | install -d $RPM_BUILD_ROOT%{_libdir}/VirtualBox/nls |
916ab34d | 328 | |
5877f605 | 329 | install %{SOURCE2} $RPM_BUILD_ROOT%{_libdir}/VirtualBox/additions/VBoxGuestAdditions.iso |
fe3d1798 JB |
330 | cp -a out/linux.%{outdir}/release/bin/components $RPM_BUILD_ROOT%{_libdir}/VirtualBox |
331 | cp -a out/linux.%{outdir}/release/bin/nls/* $RPM_BUILD_ROOT%{_libdir}/VirtualBox/nls | |
8833bce1 | 332 | |
fe3d1798 | 333 | install out/linux.%{outdir}/release/bin/additions/mountvboxsf \ |
09c79ddb | 334 | $RPM_BUILD_ROOT%{_bindir} |
335 | ||
c7f37a9d ER |
336 | %ifnarch %{x8664} |
337 | install -d $RPM_BUILD_ROOT%{_libdir}/xorg/modules/{drivers,input} | |
53741724 | 338 | install out/linux.%{outdir}/release/bin/additions/vboxmouse_drv_14.so \ |
09c79ddb | 339 | $RPM_BUILD_ROOT%{_libdir}/xorg/modules/input/vboxmouse_drv.so |
53741724 | 340 | install out/linux.%{outdir}/release/bin/additions/vboxvideo_drv_14.so \ |
09c79ddb | 341 | $RPM_BUILD_ROOT%{_libdir}/xorg/modules/drivers/vboxvideo_drv.so |
c7f37a9d | 342 | %endif |
09c79ddb | 343 | |
fe3d1798 | 344 | install out/linux.%{outdir}/release/bin/VBox.png $RPM_BUILD_ROOT%{_pixmapsdir}/VBox.png |
67ad4c40 | 345 | install %{SOURCE5} $RPM_BUILD_ROOT%{_desktopdir}/%{pname}.desktop |
d1c4ec5b | 346 | |
33233365 | 347 | install -d $RPM_BUILD_ROOT/etc/udev/rules.d |
348 | install udev.conf $RPM_BUILD_ROOT/etc/udev/rules.d/virtualbox.rules | |
da083e45 | 349 | %endif |
33233365 | 350 | |
da083e45 | 351 | %if %{with kernel} |
70fe9387 | 352 | install -d $RPM_BUILD_ROOT/etc/rc.d/init.d |
67ad4c40 | 353 | install %{SOURCE3} $RPM_BUILD_ROOT/etc/rc.d/init.d/vboxdrv |
354 | install %{SOURCE4} $RPM_BUILD_ROOT/etc/rc.d/init.d/vboxadd | |
83ffcfa8 | 355 | %install_kernel_modules -m PLD-MODULE-BUILD/vboxadd/vboxadd -d misc |
356 | %install_kernel_modules -m PLD-MODULE-BUILD/vboxdrv/vboxdrv -d misc | |
357 | %install_kernel_modules -m PLD-MODULE-BUILD/vboxvfs/vboxvfs -d misc | |
d1c4ec5b | 358 | %endif |
05f1b1f5 | 359 | |
48363591 | 360 | %clean |
361 | rm -rf $RPM_BUILD_ROOT | |
362 | ||
3b63d3e8 | 363 | %pre |
364 | %groupadd -g 221 -r -f vbox | |
365 | ||
14561782 | 366 | %post |
d8ed80f4 | 367 | cat << 'EOF' |
368 | NOTE: You must also install kernel module for this software to work | |
7d4acef5 ER |
369 | kernel-misc-vboxdrv-%{version}-%{rel}@%{_kernel_ver_str} |
370 | kernel-desktop-misc-vboxdrv-%{version}-%{rel}@%{_kernel_ver_str} | |
371 | kernel-laptop-misc-vboxdrv-%{version}-%{rel}@%{_kernel_ver_str} | |
372 | kernel-vanilla-misc-vboxdrv-%{version}-%{rel}@%{_kernel_ver_str} | |
d8ed80f4 | 373 | etc. |
374 | ||
7d4acef5 | 375 | Depending on which kernel brand You use. |
d8ed80f4 | 376 | |
377 | EOF | |
378 | ||
3b63d3e8 | 379 | %postun |
380 | if [ "$1" = "0" ]; then | |
381 | %groupremove vbox | |
382 | fi | |
383 | ||
74268e47 | 384 | %post -n kernel%{_alt_kernel}-misc-vboxadd |
385 | %depmod %{_kernel_ver} | |
270f67bc | 386 | /sbin/chkconfig --add vboxadd |
387 | %service vboxadd restart "VirtualBox OSE guest additions driver" | |
74268e47 | 388 | |
389 | %postun -n kernel%{_alt_kernel}-misc-vboxadd | |
390 | %depmod %{_kernel_ver} | |
391 | ||
270f67bc | 392 | %preun -n kernel%{_alt_kernel}-misc-vboxadd |
393 | if [ "$1" = "0" ]; then | |
394 | %service vboxadd stop | |
395 | /sbin/chkconfig --del vboxadd | |
396 | fi | |
397 | ||
48363591 | 398 | %post -n kernel%{_alt_kernel}-misc-vboxdrv |
399 | %depmod %{_kernel_ver} | |
270f67bc | 400 | /sbin/chkconfig --add vboxdrv |
401 | %service vboxdrv restart "VirtualBox OSE driver" | |
48363591 | 402 | |
403 | %postun -n kernel%{_alt_kernel}-misc-vboxdrv | |
404 | %depmod %{_kernel_ver} | |
405 | ||
270f67bc | 406 | %preun -n kernel%{_alt_kernel}-misc-vboxdrv |
407 | if [ "$1" = "0" ]; then | |
408 | %service vboxdrv stop | |
409 | /sbin/chkconfig --del vboxdrv | |
410 | fi | |
411 | ||
74268e47 | 412 | %post -n kernel%{_alt_kernel}-misc-vboxvfs |
413 | %depmod %{_kernel_ver} | |
414 | ||
415 | %postun -n kernel%{_alt_kernel}-misc-vboxvfs | |
416 | %depmod %{_kernel_ver} | |
417 | ||
d1c4ec5b | 418 | %if %{with userspace} |
48363591 | 419 | %files |
420 | %defattr(644,root,root,755) | |
7d1c0a63 | 421 | %doc UserManual.pdf |
8833bce1 | 422 | %dir %{_libdir}/VirtualBox |
916ab34d | 423 | %dir %{_libdir}/VirtualBox/additions |
8833bce1 | 424 | %dir %{_libdir}/VirtualBox/components |
425 | %dir %{_libdir}/VirtualBox/nls | |
4c18fded | 426 | %attr(755,root,root) %{_bindir}/mountvboxsf |
427 | %attr(755,root,root) %{_bindir}/vditool | |
48363591 | 428 | %attr(755,root,root) %{_bindir}/VBox* |
429 | %attr(755,root,root) %{_bindir}/VirtualBox | |
fdd1c725 | 430 | %attr(755,root,root) %{_libdir}/VirtualBox/vditool |
05f1b1f5 | 431 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxSVC |
432 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxBFE | |
8bb99fd5 | 433 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxHeadless |
05f1b1f5 | 434 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxManage |
435 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxSDL | |
8bb99fd5 | 436 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxTunctl |
05f1b1f5 | 437 | %attr(755,root,root) %{_libdir}/VirtualBox/VBoxXPCOMIPCD |
8833bce1 | 438 | %attr(755,root,root) %{_libdir}/VirtualBox/VBox*.so |
9a6c7384 AM |
439 | %ifarch %{x8664} |
440 | %attr(755,root,root) %{_libdir}/VirtualBox/VBox*.rel | |
441 | %endif | |
fdd1c725 | 442 | %attr(755,root,root) %{_libdir}/VirtualBox/VirtualBox |
443 | %attr(755,root,root) %{_libdir}/VirtualBox/VirtualBox-wrapper.sh | |
05f1b1f5 | 444 | %{_libdir}/VirtualBox/*.gc |
445 | %{_libdir}/VirtualBox/*.r0 | |
916ab34d | 446 | %{_libdir}/VirtualBox/additions/* |
05f1b1f5 | 447 | %{_libdir}/VirtualBox/components/* |
89ce7412 | 448 | %lang(ar) %{_libdir}/VirtualBox/nls/*_ar.qm |
72d5ea57 | 449 | %lang(ca) %{_libdir}/VirtualBox/nls/*_ca.qm |
89ce7412 | 450 | %lang(cs) %{_libdir}/VirtualBox/nls/*_cs.qm |
451 | %lang(de) %{_libdir}/VirtualBox/nls/*_de.qm | |
452 | %lang(es) %{_libdir}/VirtualBox/nls/*_es.qm | |
453 | %lang(eu) %{_libdir}/VirtualBox/nls/*_eu.qm | |
454 | %lang(fi) %{_libdir}/VirtualBox/nls/*_fi.qm | |
455 | %lang(fr) %{_libdir}/VirtualBox/nls/*_fr.qm | |
456 | %lang(hu) %{_libdir}/VirtualBox/nls/*_hu.qm | |
72d5ea57 | 457 | %lang(id) %{_libdir}/VirtualBox/nls/*_id.qm |
89ce7412 | 458 | %lang(it) %{_libdir}/VirtualBox/nls/*_it.qm |
459 | %lang(ja) %{_libdir}/VirtualBox/nls/*_ja.qm | |
460 | %lang(ko) %{_libdir}/VirtualBox/nls/*_ko.qm | |
72d5ea57 | 461 | %lang(nl) %{_libdir}/VirtualBox/nls/*_nl.qm |
89ce7412 | 462 | %lang(pl) %{_libdir}/VirtualBox/nls/*_pl.qm |
52b59a1b | 463 | %lang(pt) %{_libdir}/VirtualBox/nls/*_pt.qm |
89ce7412 | 464 | %lang(pt_BR) %{_libdir}/VirtualBox/nls/*_pt_BR.qm |
89ce7412 | 465 | %lang(ro) %{_libdir}/VirtualBox/nls/*_ro.qm |
466 | %lang(ru) %{_libdir}/VirtualBox/nls/*_ru.qm | |
467 | %lang(sk) %{_libdir}/VirtualBox/nls/*_sk.qm | |
72d5ea57 | 468 | %lang(sr) %{_libdir}/VirtualBox/nls/*_sr.qm |
89ce7412 | 469 | %lang(sv) %{_libdir}/VirtualBox/nls/*_sv.qm |
72d5ea57 | 470 | %lang(tr) %{_libdir}/VirtualBox/nls/*_tr.qm |
89ce7412 | 471 | %lang(zh_CN) %{_libdir}/VirtualBox/nls/*_zh_CN.qm |
472 | %lang(zh_TW) %{_libdir}/VirtualBox/nls/*_zh_TW.qm | |
d89980c7 | 473 | %{_pixmapsdir}/VBox.png |
bd3faca3 | 474 | %{_desktopdir}/%{pname}.desktop |
09c79ddb | 475 | |
abb636b9 | 476 | %files udev |
477 | %defattr(644,root,root,755) | |
478 | %config(noreplace) %verify(not md5 mtime size) /etc/udev/rules.d/virtualbox.rules | |
479 | ||
23d9d34e | 480 | # Drivers are for Guest OS, which is 32-bit. |
481 | %ifnarch %{x8664} | |
09c79ddb | 482 | %files -n xorg-driver-input-vboxmouse |
483 | %defattr(644,root,root,755) | |
484 | %attr(755,root,root) %{_libdir}/xorg/modules/input/vboxmouse_drv.so | |
485 | ||
486 | %files -n xorg-driver-video-vboxvideo | |
487 | %defattr(644,root,root,755) | |
488 | %attr(755,root,root) %{_libdir}/xorg/modules/drivers/vboxvideo_drv.so | |
d1c4ec5b | 489 | %endif |
23d9d34e | 490 | %endif |
48363591 | 491 | |
d1c4ec5b | 492 | %if %{with kernel} |
74268e47 | 493 | %files -n kernel%{_alt_kernel}-misc-vboxadd |
494 | %defattr(644,root,root,755) | |
67ad4c40 | 495 | %attr(754,root,root) /etc/rc.d/init.d/vboxadd |
74268e47 | 496 | /lib/modules/%{_kernel_ver}/misc/vboxadd.ko* |
497 | ||
d1c4ec5b | 498 | %files -n kernel%{_alt_kernel}-misc-vboxdrv |
48363591 | 499 | %defattr(644,root,root,755) |
67ad4c40 | 500 | %attr(754,root,root) /etc/rc.d/init.d/vboxdrv |
d1c4ec5b | 501 | /lib/modules/%{_kernel_ver}/misc/vboxdrv.ko* |
74268e47 | 502 | |
503 | %files -n kernel%{_alt_kernel}-misc-vboxvfs | |
504 | %defattr(644,root,root,755) | |
505 | /lib/modules/%{_kernel_ver}/misc/vboxvfs.ko* | |
05f1b1f5 | 506 | %endif |