[1000] | 1 | #
|
---|
[1135] | 2 | # spec file for package
|
---|
[1000] | 3 | #
|
---|
[1135] | 4 | # Copyright (c) 2013 dass IT GmbH, Cologne, Germany.
|
---|
[1000] | 5 | #
|
---|
| 6 | # All modifications and additions to the file contributed by third parties
|
---|
| 7 | # remain the property of their copyright owners, unless otherwise agreed
|
---|
| 8 | # upon. The license for this file, and modifications and additions to the
|
---|
| 9 | # file, is the same license as for the pristine package itself (unless the
|
---|
| 10 | # license for the pristine package is not an Open Source License, in which
|
---|
| 11 | # case the license is the MIT License). An "Open Source License" is a
|
---|
| 12 | # license that conforms to the Open Source Definition (Version 1.9)
|
---|
| 13 | # published by the Open Source Initiative.
|
---|
| 14 |
|
---|
[1001] | 15 | # Please submit bugfixes or comments via packager@dass-it.de
|
---|
[1000] | 16 | #
|
---|
| 17 | # norootforbuild
|
---|
| 18 |
|
---|
| 19 | Name: wsusoffline
|
---|
| 20 | Group: System/Management
|
---|
[1136] | 21 | Version: 8.0.0
|
---|
[1135] | 22 | %define ver "80"
|
---|
[1000] | 23 | Release: 1
|
---|
| 24 | Summary: WSUS Offline Update: download Microsoft updates
|
---|
| 25 | License: GPLv2+
|
---|
| 26 | URL: http://www.wsusoffline.net/
|
---|
| 27 | Source: %{name}_%{version}.orig.tar.gz
|
---|
[1014] | 28 | #Source99: #{name}-rpmlintrc
|
---|
[1004] | 29 | BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
---|
[1017] | 30 | BuildRequires: unzip
|
---|
| 31 |
|
---|
| 32 | # for goupadd
|
---|
[1018] | 33 | %if 0%{?suse_version}
|
---|
[1020] | 34 | Requires(pre): pwdutils
|
---|
| 35 | %else
|
---|
[1018] | 36 | #Requires(pre): shadow-utils
|
---|
[1020] | 37 | Requires(pre): /usr/bin/groupadd
|
---|
[1017] | 38 | %endif
|
---|
| 39 |
|
---|
[1135] | 40 | Requires: cabextract md5deep xmlstarlet wget
|
---|
[1000] | 41 | BuildArch: noarch
|
---|
| 42 |
|
---|
| 43 | %description
|
---|
[1001] | 44 | "WSUS Offline Update" allows you to download most Microsoft updates and store them localy.
|
---|
[1002] | 45 | This includes Windows, Office and some extensions like dotnet or Powershell.
|
---|
[1001] | 46 | After downloading, they can be installed on any Microsoft Windows system without an Internet connection.
|
---|
| 47 | Also unattended/silient installation are possible, so the update be be included easily in a Windows software management system like http://www.opsi.org
|
---|
[1000] | 48 |
|
---|
| 49 | %prep
|
---|
| 50 | %setup -c
|
---|
| 51 |
|
---|
| 52 |
|
---|
| 53 | %build
|
---|
| 54 |
|
---|
| 55 |
|
---|
| 56 |
|
---|
| 57 | %install
|
---|
[1010] | 58 | %define DEST_DIR /var/lib/wsusoffline/
|
---|
[1000] | 59 | mkdir -p $RPM_BUILD_ROOT/var/lib/
|
---|
[1008] | 60 | unzip wsusoffline/%{name}%{ver}.zip -d $RPM_BUILD_ROOT/var/lib/
|
---|
[1142] | 61 | PATCH=$PWD/wsusoffline/download-updates.patch
|
---|
| 62 | cd $RPM_BUILD_ROOT/%{DEST_DIR}
|
---|
| 63 | patch -p1 < $PATCH
|
---|
| 64 | cd -
|
---|
[1016] | 65 | install -d $RPM_BUILD_ROOT/%{DEST_DIR}/temp/
|
---|
| 66 |
|
---|
| 67 |
|
---|
| 68 | # remove windows only stuff
|
---|
[1010] | 69 | rm -r $RPM_BUILD_ROOT/%{DEST_DIR}/*.exe
|
---|
| 70 | rm -r $RPM_BUILD_ROOT/%{DEST_DIR}/*.au3
|
---|
| 71 | rm -r $RPM_BUILD_ROOT/%{DEST_DIR}/bin
|
---|
| 72 | rm -r $RPM_BUILD_ROOT/%{DEST_DIR}/cmd
|
---|
[1013] | 73 |
|
---|
[1016] | 74 | # adapt permissions
|
---|
| 75 | chmod g+ws $RPM_BUILD_ROOT/%{DEST_DIR}
|
---|
| 76 | find $RPM_BUILD_ROOT/%{DEST_DIR}/client/ -type d -exec chmod g+ws {} \;
|
---|
| 77 | chmod g+ws $RPM_BUILD_ROOT/%{DEST_DIR}/exclude/
|
---|
| 78 | chmod g+ws $RPM_BUILD_ROOT/%{DEST_DIR}/log/
|
---|
| 79 | chmod g+ws $RPM_BUILD_ROOT/%{DEST_DIR}/iso/
|
---|
[1141] | 80 | # checkconnection downloads file into this directory
|
---|
| 81 | chmod g+ws $RPM_BUILD_ROOT/%{DEST_DIR}/sh/
|
---|
[1016] | 82 | chmod a+x $RPM_BUILD_ROOT/%{DEST_DIR}/sh/*
|
---|
[1140] | 83 | find $RPM_BUILD_ROOT/%{DEST_DIR}/static/ -type d -exec chmod g+ws {} \;
|
---|
[1016] | 84 | chmod g+ws $RPM_BUILD_ROOT/%{DEST_DIR}/temp/
|
---|
| 85 |
|
---|
| 86 |
|
---|
| 87 | # install start wrapper scripts
|
---|
[1001] | 88 | mkdir -p $RPM_BUILD_ROOT/usr/bin/
|
---|
[1011] | 89 | install wsusoffline/*.sh $RPM_BUILD_ROOT/usr/bin/
|
---|
[1000] | 90 |
|
---|
[1016] | 91 |
|
---|
| 92 |
|
---|
[1000] | 93 | %clean
|
---|
| 94 | rm -rf %{buildroot}
|
---|
| 95 |
|
---|
[1008] | 96 | %pre
|
---|
| 97 | getent group wsusoffline >/dev/null || groupadd -r wsusoffline
|
---|
| 98 |
|
---|
[1016] | 99 |
|
---|
[1000] | 100 | %files
|
---|
| 101 | %defattr(-,root,root)
|
---|
[1008] | 102 | /usr/bin/wsus-*.sh
|
---|
[1016] | 103 | %dir %{DEST_DIR}
|
---|
[1010] | 104 | # #{DEST_DIR}/bin
|
---|
| 105 | # #{DEST_DIR}/cmd
|
---|
[1138] | 106 | %{DEST_DIR}/doc/
|
---|
| 107 | %{DEST_DIR}/xslt/
|
---|
[1010] | 108 |
|
---|
[1008] | 109 | %defattr(-,root,wsusoffline)
|
---|
| 110 | %{DEST_DIR}/client/
|
---|
[1013] | 111 | %{DEST_DIR}/exclude/
|
---|
[1010] | 112 | %{DEST_DIR}/iso/
|
---|
| 113 | %{DEST_DIR}/log/
|
---|
[1144] | 114 | # write access required, but only for checkconnection
|
---|
| 115 | %{DEST_DIR}/sh/
|
---|
[1138] | 116 | %{DEST_DIR}/static
|
---|
[1010] | 117 | %{DEST_DIR}/temp/
|
---|
[1000] | 118 |
|
---|
| 119 | %changelog
|
---|