]>
Commit | Line | Data |
---|---|---|
805671bc JR |
1 | # |
2 | # Conditional build: | |
0a8f5ff8 | 3 | %bcond_without clamav # clamav / virusfilter module |
805671bc JR |
4 | # |
5 | %ifarch x32 | |
6 | %undefine with_clamav | |
7 | %endif | |
029c6e45 | 8 | Summary: Modules for c-icap ICAP server |
0a8f5ff8 | 9 | Summary(pl.UTF-8): Moduły dla serwera ICAP c-icap |
029c6e45 | 10 | Name: c-icap-modules |
0a8f5ff8 JB |
11 | Version: 0.5.7 |
12 | Release: 1 | |
13 | License: GPL v2+ | |
b8c0d968 | 14 | Group: Networking/Daemons |
0a8f5ff8 JB |
15 | Source0: https://downloads.sourceforge.net/c-icap/c_icap_modules-%{version}.tar.gz |
16 | # Source0-md5: 08c4721a26840bb0ff95fcaa64b686c3 | |
029c6e45 | 17 | Patch0: %{name}-build.patch |
3b3f2bb1 | 18 | Patch1: clamav0.101.patch |
0a8f5ff8 JB |
19 | URL: https://c-icap.sourceforge.net/ |
20 | BuildRequires: autoconf >= 2.50 | |
21 | BuildRequires: automake | |
22 | BuildRequires: c-icap-devel >= 0.5 | |
23 | %{?with_clamav:BuildRequires: clamav-devel >= 0.90} | |
24 | BuildRequires: db-devel >= 4.2 | |
25 | BuildRequires: libtool >= 2:2 | |
029c6e45 | 26 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
27 | ||
28 | %description | |
0a8f5ff8 JB |
29 | Modules for c-icap ICAP server. |
30 | ||
31 | %description -l pl.UTF-8 | |
32 | Moduły dla serwera ICAP c-icap. | |
029c6e45 | 33 | |
34 | %package -n c-icap-srv_clamav | |
35 | Summary: ClamAV service for c-icap | |
0a8f5ff8 | 36 | Summary(pl.UTF-8): Usługa ClamAV dla c-icap |
b8c0d968 | 37 | Group: Networking/Daemons |
0a8f5ff8 | 38 | Requires: c-icap >= 0.5 |
029c6e45 | 39 | |
40 | %description -n c-icap-srv_clamav | |
41 | ClamAV service for c-icap. | |
42 | ||
0a8f5ff8 JB |
43 | %description -n c-icap-srv_clamav -l pl.UTF-8 |
44 | Usługa ClamAV dla c-icap. | |
45 | ||
029c6e45 | 46 | %package -n c-icap-srv_url_check |
47 | Summary: URL check service for c-icap | |
0a8f5ff8 | 48 | Summary(pl.UTF-8): Usługa sprawdzania URL-i dla c-icap |
b8c0d968 | 49 | Group: Networking/Daemons |
0a8f5ff8 | 50 | Requires: c-icap >= 0.5 |
029c6e45 | 51 | |
52 | %description -n c-icap-srv_url_check | |
53 | URL check service for c-icap. | |
54 | ||
0a8f5ff8 JB |
55 | %description -n c-icap-srv_url_check -l pl.UTF-8 |
56 | Usługa sprawdzania URL-i dla c-icap. | |
57 | ||
b8c0d968 JR |
58 | %package -n c-icap-srv_content_filtering |
59 | Summary: Content filtering service for c-icap | |
0a8f5ff8 | 60 | Summary(pl.UTF-8): Usługa filtrowania treści dla c-icap |
b8c0d968 | 61 | Group: Networking/Daemons |
0a8f5ff8 | 62 | Requires: c-icap >= 0.5 |
b8c0d968 JR |
63 | |
64 | %description -n c-icap-srv_content_filtering | |
65 | Content filtering service for c-icap. | |
029c6e45 | 66 | |
0a8f5ff8 JB |
67 | %description -n c-icap-srv_content_filtering -l pl.UTF-8 |
68 | Usługa filtrowania treści dla c-icap. | |
69 | ||
029c6e45 | 70 | %prep |
71 | %setup -q -n c_icap_modules-%{version} | |
72 | %patch0 -p1 | |
3b3f2bb1 | 73 | %patch1 -p1 |
029c6e45 | 74 | |
75 | %build | |
0a8f5ff8 JB |
76 | %{__libtoolize} |
77 | %{__aclocal} -I m4 | |
029c6e45 | 78 | %{__autoconf} |
0a8f5ff8 JB |
79 | %{__autoheader} |
80 | %{__automake} | |
3b3f2bb1 | 81 | export CFLAGS="%{rpmcflags} -I/usr/include/clamav" |
0eb38c0f | 82 | %configure |
b8c0d968 | 83 | |
029c6e45 | 84 | %{__make} |
85 | ||
86 | %install | |
87 | rm -rf $RPM_BUILD_ROOT | |
88 | ||
89 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/c-icap | |
90 | %{__make} install \ | |
91 | DESTDIR=$RPM_BUILD_ROOT | |
92 | ||
b8c0d968 JR |
93 | # Not installed by upstream |
94 | cp -a services/content_filtering/srv_content_filtering.conf.default \ | |
95 | $RPM_BUILD_ROOT%{_sysconfdir}/c-icap/srv_content_filtering.conf | |
96 | ||
97 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/c_icap/*.la | |
98 | ||
029c6e45 | 99 | %clean |
100 | rm -rf $RPM_BUILD_ROOT | |
101 | ||
805671bc | 102 | %if %{with clamav} |
029c6e45 | 103 | %files -n c-icap-srv_clamav |
104 | %defattr(644,root,root,755) | |
0a8f5ff8 | 105 | %doc README SPONSORS |
b8c0d968 JR |
106 | %attr(640,root,c-icap) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/c-icap/clamav_mod.conf |
107 | %attr(640,root,c-icap) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/c-icap/clamd_mod.conf | |
108 | %attr(640,root,c-icap) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/c-icap/virus_scan.conf | |
109 | %{_sysconfdir}/c-icap/clamav_mod.conf.default | |
110 | %{_sysconfdir}/c-icap/clamd_mod.conf.default | |
111 | %{_sysconfdir}/c-icap/virus_scan.conf.default | |
112 | %attr(755,root,root) %{_libdir}/c_icap/clamav_mod.so | |
113 | %attr(755,root,root) %{_libdir}/c_icap/clamd_mod.so | |
114 | %attr(755,root,root) %{_libdir}/c_icap/virus_scan.so | |
115 | %{_datadir}/c_icap/templates/virus_scan | |
805671bc | 116 | %endif |
029c6e45 | 117 | |
118 | %files -n c-icap-srv_url_check | |
119 | %defattr(644,root,root,755) | |
0a8f5ff8 | 120 | %doc README SPONSORS |
167bd907 | 121 | %attr(640,root,c-icap) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/c-icap/srv_url_check.conf |
b8c0d968 | 122 | %{_sysconfdir}/c-icap/srv_url_check.conf.default |
029c6e45 | 123 | %attr(755,root,root) %{_libdir}/c_icap/srv_url_check.so |
b8c0d968 JR |
124 | %{_datadir}/c_icap/templates/srv_url_check |
125 | %{_bindir}/c-icap-mods-sguardDB | |
126 | %{_mandir}/man8/c-icap-mods-sguardDB.8* | |
127 | ||
128 | %files -n c-icap-srv_content_filtering | |
129 | %defattr(644,root,root,755) | |
0a8f5ff8 | 130 | %doc README SPONSORS |
b8c0d968 JR |
131 | %attr(640,root,c-icap) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/c-icap/srv_content_filtering.conf |
132 | %{_sysconfdir}/c-icap/srv_content_filtering.conf.default | |
133 | %attr(755,root,root) %{_libdir}/c_icap/srv_content_filtering.so | |
134 | %{_datadir}/c_icap/templates/srv_content_filtering |