--- /dev/null
+Index: Config.kmk
+===================================================================
+--- Config.kmk (wersja 33269)
++++ Config.kmk (wersja 33316)
+@@ -567,6 +567,8 @@
+ ifdef VBOX_WITH_HARDENING
+ if1of ($(KBUILD_TARGET), solaris)
+ VBOX_PATH_APP_PRIVATE = /opt/VirtualBox/$(if-expr $(KBUILD_TARGET_ARCH) == "amd64",amd64,i386)
++ else ifeq ($(KBUILD_TARGET),linux)
++ VBOX_PATH_APP_PRIVATE = /opt/VirtualBox
+ else ifeq ($(KBUILD_TARGET),darwin)
+ VBOX_PATH_APP_PRIVATE = /Applications/VirtualBox.app/Contents/MacOS
+ else ifeq ($(KBUILD_TARGET),freebsd)
+@@ -599,7 +601,7 @@
+ # depending on the location of the object.)
+ #VBOX_WITH_RUNPATH = /usr/lib/virtualbox
+ ifdef VBOX_WITH_HARDENING
+- if1of ($(KBUILD_TARGET), freebsd solaris)
++ if1of ($(KBUILD_TARGET), freebsd linux solaris)
+ VBOX_WITH_RUNPATH = $(VBOX_PATH_APP_PRIVATE)
+ endif
+ endif
+@@ -607,12 +609,10 @@
+ # Because of the setuid usage on all ELF platforms when hardening the build
+ # things gets a bit complicated since the $ORIGIN+setuid policy differs.
+ #VBOX_WITH_ORIGIN=1
+-ifdef VBOX_WITH_HARDENING
+- if1of ($(KBUILD_TARGET), linux)
++ifndef VBOX_WITH_HARDENING
++ if1of ($(KBUILD_TARGET), linux solaris)
+ VBOX_WITH_ORIGIN = 1
+ endif
+-else if1of ($(KBUILD_TARGET), linux solaris)
+- VBOX_WITH_ORIGIN = 1
+ endif
+ # Enable the system wide support service/daemon.
+ # Work in progress, but required for hardening on Windows.
%define _enable_debug_packages 0
%endif
-%define rel 3
+%define rel 4
%define pname VirtualBox
Summary: VirtualBox OSE - x86 hardware virtualizer
Patch2: %{pname}-VBoxSysInfo.patch
Patch3: %{pname}-warning_workaround.patch
Patch4: %{pname}-vnc.patch
+Patch5: %{pname}-noorigin.patch
URL: http://www.virtualbox.org/
BuildRequires: rpmbuild(macros) >= 1.535
%if %{with userspace}
%patch2 -p1
%patch3 -p1
%patch4 -p1
+%patch5 -p0
%{__sed} -i -e 's,$VBOX_DOC_PATH,%{_docdir}/%{name}-%{version},' src/VBox/Installer/linux/virtualbox.desktop
%{__sed} -i -e 's/Categories=.*/Categories=Utility;Emulator;/' src/VBox/Installer/linux/virtualbox.desktop