commit 701bf54ac77381aef13155fb9c62948d3469c018
Author: Sérgio M. Basto <sergio(a)serjux.com>
Date: Fri Sep 6 04:13:47 2019 +0100
Update VBox to 6.0.12
.gitignore | 1 +
...AutoMount-Change-Linux-mount-code-to-use-.patch | 2 +-
007-python2-path.patch | 2 +-
VirtualBox.spec | 27 +++++++++++-
sources | 2 +-
update_vbox.sh | 16 ++++---
vbox-python-detection.diff | 51 ++++++++++++++++++++++
7 files changed, 90 insertions(+), 11 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 4d5d9c2..eb80a5a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -39,3 +39,4 @@ VirtualBox-5.0.16.tar.bz2
/VirtualBox-6.0.6.tar.bz2
/VirtualBox-6.0.8.tar.bz2
/VirtualBox-6.0.10.tar.bz2
+/VirtualBox-6.0.12.tar.bz2
diff --git a/0001-VBoxServiceAutoMount-Change-Linux-mount-code-to-use-.patch
b/0001-VBoxServiceAutoMount-Change-Linux-mount-code-to-use-.patch
index 6bbabc3..6a15a33 100644
--- a/0001-VBoxServiceAutoMount-Change-Linux-mount-code-to-use-.patch
+++ b/0001-VBoxServiceAutoMount-Change-Linux-mount-code-to-use-.patch
@@ -143,7 +143,7 @@ diff --git
a/src/VBox/Additions/common/VBoxService/VBoxServiceAutoMount.cpp b/sr
- MntInfo.signature[1] = VBSF_MOUNT_SIGNATURE_BYTE_1;
- MntInfo.signature[2] = VBSF_MOUNT_SIGNATURE_BYTE_2;
- MntInfo.length = sizeof(MntInfo);
-- MntInfo.ttl = MntOpts.uid = -1 /*default*/;
+- MntInfo.ttl = MntOpts.ttl = -1 /*default*/;
- MntInfo.msDirCacheTTL= MntOpts.msDirCacheTTL = -1 /*default*/;
- MntInfo.msInodeTTL = MntOpts.msInodeTTL = -1 /*default*/;
- MntInfo.cMaxIoPages = MntOpts.cMaxIoPages = 0 /*default*/;
diff --git a/007-python2-path.patch b/007-python2-path.patch
index b7d19ce..005d582 100644
--- a/007-python2-path.patch
+++ b/007-python2-path.patch
@@ -3,7 +3,7 @@
+++ ./src/VBox/Frontends/VBoxShell/vboxshell.py 2019-01-03 22:05:42.645245995 +0000
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
-+#!/usr/bin/python2
++#!/usr/bin/python3
# -*- coding: utf-8 -*-
# $Id: vboxshell.py $
diff --git a/VirtualBox.spec b/VirtualBox.spec
index 8ff89a0..ccd95dd 100644
--- a/VirtualBox.spec
+++ b/VirtualBox.spec
@@ -32,9 +32,15 @@
%bcond_without guest_additions
%endif
+%if 0%{?fedora} > 30
+ %bcond_with python2
+%else
+ %bcond_without python2
+%endif
+
Name: VirtualBox
-Version: 6.0.10
-Release: 3%{?dist}
+Version: 6.0.12
+Release: 1%{?dist}
Summary: A general-purpose full virtualizer for PC hardware
License: GPLv2 or (GPLv2 and CDDL)
@@ -75,6 +81,8 @@ Patch51: VirtualBox-5.1.0-revert-VBox.sh.patch
# from Fedora
Patch60: VirtualBox-5.2.10-xclient.patch
Patch61: 0001-VBoxServiceAutoMount-Change-Linux-mount-code-to-use-.patch
+# from OpenSuse
+Patch70: vbox-python-detection.diff
BuildRequires: kBuild >= 0.1.9998.r3093
@@ -88,7 +96,9 @@ BuildRequires: xerces-c-devel
BuildRequires: libIDL-devel
BuildRequires: yasm
BuildRequires: pulseaudio-libs-devel
+%if %{with python2}
BuildRequires: python2-devel
+%endif
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: desktop-file-utils
BuildRequires: libcap-devel
@@ -175,6 +185,9 @@ Group: Development/Tools
Requires: %{name}-kmod = %{version}
Requires: hicolor-icon-theme
Provides: %{name}-kmod-common = %{version}-%{release}
+%if ! %{with python2}
+Obsoletes: python2-%{name}%{?isa} < %{version}-%{release}
+%endif
%description server
%{name} without Qt GUI part.
@@ -193,7 +206,9 @@ webservice GUI part for %{name}.
Summary: %{name} SDK
Group: Development/Libraries
Requires: %{name}-server%{?isa} = %{version}-%{release}
+%if %{with python2}
Requires: python2-%{name}%{?isa} = %{version}-%{release}
+%endif
%description devel
%{name} Software Development Kit.
@@ -301,6 +316,7 @@ rm -r src/libs/zlib-1.2.*/
%patch51 -p1 -b .revert-VBox.sh
%patch60 -p1 -b .xclient
%patch61 -p1 -b .automount
+%patch70 -p1 -b .python-detection
%build
./configure --disable-kmods \
@@ -471,8 +487,10 @@ install -p -m 0755 -t %{buildroot}%{_libdir}/virtualbox/nls \
# Python
pushd obj/bin/sdk/installer
+%if %{with python2}
VBOX_INSTALL_PATH=%{_libdir}/virtualbox \
%{__python2} vboxapisetup.py install --prefix %{_prefix} --root %{buildroot}
+%endif
VBOX_INSTALL_PATH=%{_libdir}/virtualbox \
%{__python3} vboxapisetup.py install --prefix %{_prefix} --root %{buildroot}
popd
@@ -770,10 +788,12 @@ getent passwd vboxadd >/dev/null || \
%files devel
%{_libdir}/virtualbox/sdk
+%if %{with python2}
%files -n python2-%{name}
%{_libdir}/virtualbox/*.py*
%{python2_sitelib}/vboxapi*
%{_libdir}/virtualbox/VBoxPython2_7.so
+%endif
%files -n python%{python3_pkgversion}-%{name}
%{_libdir}/virtualbox/*.py*
@@ -806,6 +826,9 @@ getent passwd vboxadd >/dev/null || \
%{_datadir}/%{name}-kmod-%{version}
%changelog
+* Thu Sep 05 2019 Sérgio Basto <sergio(a)serjux.com> - 6.0.12-1
+- Update VBox to 6.0.12
+
* Sat Aug 24 2019 Leigh Scott <leigh123linux(a)gmail.com> - 6.0.10-3
- Rebuild for python-3.8
diff --git a/sources b/sources
index a3d963f..e7840f7 100644
--- a/sources
+++ b/sources
@@ -1,2 +1,2 @@
-8428f7e27b244803df180213bc5d4a68 VirtualBox-6.0.10.tar.bz2
+465b52e516a6c57c8c19717bdd8e6456 VirtualBox-6.0.12.tar.bz2
cc249f95c62a734b011ce0043fe7180d UserManual.pdf
diff --git a/update_vbox.sh b/update_vbox.sh
index c9e29b9..c248cbb 100755
--- a/update_vbox.sh
+++ b/update_vbox.sh
@@ -1,6 +1,6 @@
-VERSION=6.0.10
+VERSION=6.0.12
REL=1
-RAWHIDE=31
+RAWHIDE=32
if [ -z "$1" ]
then
stage=0
@@ -32,14 +32,18 @@ fi
if test $stage -le 2
then
echo STAGE 2
+git checkout f31 && git merge master && git push && rfpkg build
--nowait; git checkout master
+echo Press enter to continue; read dummy;
git checkout f30 && git merge master && git push && rfpkg build
--nowait; git checkout master
echo Press enter to continue; read dummy;
+fi
+if test $stage -le 3
+then
+echo STAGE 3
git checkout f29 && git merge master && git push && rfpkg build
--nowait; git checkout master
-echo Press enter to continue; read dummy;
-git checkout f28 && git merge master && git push && rfpkg build
--nowait; git checkout master
+fi
echo Press enter to continue; read dummy;
git checkout el7 && git merge master && git push && rfpkg build
--nowait; git checkout master
-fi
cd ../VirtualBox-kmod/
if test $stage -le 5
@@ -48,4 +52,4 @@ echo STAGE 5
git pull
rpmdev-bumpspec -n $VERSION -c "Update VBox to $VERSION" VirtualBox-kmod.spec
rfpkg srpm && copr-cli build sergiomb/vboxfor23
VirtualBox-kmod-$VERSION-$REL.fc$RAWHIDE.src.rpm
-echo Continue in ..../VirtualBox-kmod/update_vbox.sh
+echo "Continue in ../VirtualBox-kmod/update_vbox.sh"
diff --git a/vbox-python-detection.diff b/vbox-python-detection.diff
new file mode 100644
index 0000000..37d34da
--- /dev/null
+++ b/vbox-python-detection.diff
@@ -0,0 +1,51 @@
+Index: VirtualBox-5.1.8/src/libs/xpcom18a4/python/gen_python_deps.py
+===================================================================
+--- VirtualBox-5.1.8.orig/src/libs/xpcom18a4/python/gen_python_deps.py
++++ VirtualBox-5.1.8/src/libs/xpcom18a4/python/gen_python_deps.py
+@@ -86,7 +86,7 @@ def main(argv):
+ else:
+ multi = 1
+
+- if multi == 0:
++ if not multi:
+ prefixes = ["/usr"]
+ versions = [str(sys.version_info[0])+'.'+str(sys.version_info[1]),
+
str(sys.version_info[0])+'.'+str(sys.version_info[1])+'m']
+@@ -114,24 +114,25 @@ def main(argv):
+ continue
+ for p in prefixes:
+ c = checkPair(p, v, dllpre, dllsuff, bitness_magic)
+- if c is not None:
++ if c:
+ known[v] = c
+ break
+- keys = list(known.keys())
+- # we want default to be the lowest versioned Python
+- keys.sort()
+- d = None
+ # We need separator other than newline, to sneak through $(shell)
+ sep = "|"
+- for k in keys:
+- if d is None:
+- d = k
+- vers = k.replace('.', '').upper()
+- print_vars(vers, known[k], sep, bitness_magic)
+- if d is not None:
+- print_vars("DEF", known[d], sep, bitness_magic)
++
++ if not known:
++ # this type of problem should be detected in configure
++ # print_vars("DEF", defaultpaths, sep, bitness_magic)
++ pass
+ else:
+ print(argv[0] + ": No Python development package found!",
file=sys.stderr)
++ if multi:
++ for ver, paths in known.items():
++ print_vars(ver.replace('.', '').upper(), paths, sep,
bitness_magic)
++ else:
++ ver = versions[0]
++ paths = known[ver]
++ print_vars(ver.replace('.', ''), paths, sep, bitness_magic)
+
+ if __name__ == '__main__':
+ main(sys.argv)