2011-08-16 15:53:43 +02:00
|
|
|
%define pck_majver %(echo %version | cut -d. -f1-3)
|
|
|
|
%define pck_minver %(echo %version | cut -d. -f4)
|
|
|
|
Name: virtualbox-extension-pack
|
2014-07-24 13:21:02 +02:00
|
|
|
Version: @SRPMVERSION@
|
|
|
|
Release: @SRPMRELEASE@
|
2011-08-16 15:53:43 +02:00
|
|
|
Epoch: 1
|
|
|
|
Summary: VirtualBox Extension Pack
|
|
|
|
Group: Applications/Emulators
|
|
|
|
Vendor: @vendor@
|
|
|
|
Distribution: @distribution@
|
|
|
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
|
|
|
URL: http://www.virtualbox.org/
|
|
|
|
Source: LICENSE
|
|
|
|
License: Not Distributable
|
|
|
|
Requires(post):VirtualBox
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
|
|
|
|
|
|
|
%description
|
|
|
|
VirtualBox Extension Pack.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -c -n %{name}-%{version} -T
|
|
|
|
|
|
|
|
[ -r /etc/sysconfig/@sysconfigfile@ ] || exit 1
|
2014-08-07 14:20:26 +02:00
|
|
|
declare -A SRPMVERSION SRPMRELEASE
|
2011-08-16 15:53:43 +02:00
|
|
|
. /etc/sysconfig/@sysconfigfile@
|
|
|
|
|
|
|
|
[ "${VIRTUALBOX_EXTENSION_PACK_PCK}" ] || exit 1
|
|
|
|
[ "${VIRTUALBOX_EXTENSION_PACK_URL}" ] || exit 1
|
|
|
|
|
|
|
|
wget -nv --timeout=10 --tries=2 \
|
|
|
|
${VIRTUALBOX_EXTENSION_PACK_URL}${VIRTUALBOX_EXTENSION_PACK_PCK} -O ${VIRTUALBOX_EXTENSION_PACK_PCK}
|
|
|
|
|
2021-03-02 20:25:23 +01:00
|
|
|
#wget -nv --timeout=10 --tries=2 \
|
|
|
|
# ${VIRTUALBOX_EXTENSION_PACK_URL}${VIRTUALBOX_GUEST_ADDITIONS_PCK} -O ${VIRTUALBOX_GUEST_ADDITIONS_PCK}
|
2020-12-10 14:03:11 +01:00
|
|
|
|
2011-08-16 15:53:43 +02:00
|
|
|
[ -f ${VIRTUALBOX_EXTENSION_PACK_PCK} ] || exit 1
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
%install
|
|
|
|
[ "%{buildroot}" != / ] && rm -rf %{buildroot}
|
2014-08-07 14:20:26 +02:00
|
|
|
declare -A SRPMVERSION SRPMRELEASE
|
2011-08-16 15:53:43 +02:00
|
|
|
. /etc/sysconfig/@sysconfigfile@
|
|
|
|
|
2015-08-26 15:15:45 +02:00
|
|
|
install -D -m0644 ${VIRTUALBOX_EXTENSION_PACK_PCK} %{buildroot}%{_libdir}/VirtualBox/extension/${VIRTUALBOX_EXTENSION_PACK_PCK}
|
2011-08-16 15:53:43 +02:00
|
|
|
cp %{S:0} LICENSE
|
|
|
|
|
2021-03-02 20:25:23 +01:00
|
|
|
#install -D -m0644 ${VIRTUALBOX_GUEST_ADDITIONS_PCK} %{buildroot}%{_libdir}/VirtualBox/additions/VBoxGuestAdditions.iso
|
|
|
|
#cp %{S:0} LICENSE
|
2020-12-10 14:03:11 +01:00
|
|
|
|
2011-08-16 15:53:43 +02:00
|
|
|
%clean
|
|
|
|
[ "%{buildroot}" != / ] && rm -rf %{buildroot}
|
2016-02-12 11:01:35 +01:00
|
|
|
rm -rf %{_builddir}/%{name}-*
|
|
|
|
:
|
2011-08-16 15:53:43 +02:00
|
|
|
|
|
|
|
%post
|
2012-09-19 12:55:39 +02:00
|
|
|
#VBoxManage extpack uninstall Oracle_VM_VirtualBox_Extension_Pack || true
|
2018-07-18 17:57:29 +02:00
|
|
|
echo y | VBoxManage extpack install %{_libdir}/VirtualBox/extension/Oracle_VM_VirtualBox_Extension_Pack-%{pck_majver}%{?pck_minver:%pck_minver}.vbox-extpack --replace
|
2012-09-19 12:55:39 +02:00
|
|
|
# not working
|
2011-08-16 15:53:43 +02:00
|
|
|
:
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2015-08-26 15:15:45 +02:00
|
|
|
%{_libdir}/VirtualBox/extension/Oracle_VM_VirtualBox_Extension_Pack-%{pck_majver}%{?pck_minver:%pck_minver}.vbox-extpack
|
2021-03-02 20:25:23 +01:00
|
|
|
#%{_libdir}/VirtualBox/additions/VBoxGuestAdditions.iso
|
2011-08-16 15:53:43 +02:00
|
|
|
%doc LICENSE
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
* Tue Aug 16 2011 Silvan Calarco <silvan.calarco@mambasoft.it> 4.1.2.73507-1mamba
|
|
|
|
- specfile created
|