]> git.pld-linux.org Git - packages/clamav-database.git/blob - clamav-database.spec
ef150a39ea9838d5a80a0fef463e2e8a8aa293ae
[packages/clamav-database.git] / clamav-database.spec
1 %define         main_version            45
2 %define         daily_version           5854
3 %define         database_version        20080217
4 %define         rel     2
5 Summary:        Virus databases for clamav
6 Summary(pl.UTF-8):      Bazy wirusów dla clamava
7 Name:           clamav-database
8 Version:        %{main_version}.%{daily_version}
9 Release:        %{database_version}.%{rel}
10 License:        GPL
11 Group:          Applications/Databases
12 Source0:        http://db.local.clamav.net/daily.cvd
13 # Source0-md5:  a0999deace2c3bd8dc48a5e03523b7fa
14 Source1:        http://db.local.clamav.net/main.cvd
15 # Source1-md5:  5312db62b11f8faf48c669fb358488e0
16 URL:            http://www.clamav.net/
17 BuildRequires:  file
18 Requires:       clamav
19 BuildArch:      noarch
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
22 %description
23 Virus databases for clamav (updated %{database_version}).
24
25 %description -l pl.UTF-8
26 Bazy wirusów dla clamava (aktualizowane %{database_version}).
27
28 %prep
29 %setup -qcT
30 cp -a %{SOURCE0} %{SOURCE1} .
31
32 %build
33 main_version=$(file main.cvd | awk -F, '/version/{print $2}' | awk '{print $NF}')
34 daily_version=$(file daily.cvd | awk -F, '/version/{print $2}' | awk '{print $NF}')
35 if [ "$main_version" != %{main_version} ]; then
36         : Update %%define main_version $main_version, and retry
37         exit 1
38 fi
39 if [ "$daily_version" != %{daily_version} ]; then
40         : Update %%define daily_version $daily_version, and retry
41         exit 1
42 fi
43
44 %install
45 rm -rf $RPM_BUILD_ROOT
46 install -d $RPM_BUILD_ROOT/var/lib/clamav
47 install *.cvd $RPM_BUILD_ROOT/var/lib/clamav
48
49 %clean
50 rm -rf $RPM_BUILD_ROOT
51
52 %post   -p %{_sbindir}/clamav-post-updatedb
53
54 %files
55 %defattr(644,root,root,755)
56 %attr(644,clamav,root) %verify(not md5 mtime size) /var/lib/clamav/*.cvd
This page took 0.040711 seconds and 2 git commands to generate.