source: spec/trunk/SPECS/hermes.spec@ 150

Last change on this file since 150 was 150, checked in by Yuri Dario, 15 years ago

spec: add target cpu field in cache file.

File size: 3.0 KB
Line 
1Summary: An anti-spam SMTP proxy
2Name: hermes
3Version: 1.6
4Release: 2%{?dist}
5License: GPL
6Group: System Environment/Daemons
7Packager: Veit Wahlich <cru@zodia.de>
8URL: http://www.hermes-project.com/
9Source0: http://www.iteisa.com/files/%{name}-%{version}.tar.gz
10Source1: %{name}-os2.zip
11
12Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root
13
14BuildRequires: sqlite-devel
15BuildRequires: openssl-devel
16BuildRequires: libspf2-devel
17BuildRequires: perl
18
19Patch1: hermes-os2.diff
20
21%description
22hermes is a generic, lightweight, portable and fast anti-spam smtp proxy.
23Supports greylisting, dns blacklisting/whitelisting, protocol throttling, banner delaying, spf and some
24other tricks to reject most spam before it even enters your system.
25
26%prep
27%setup -q -a1
28%patch001 -p1 -b .os2~
29
30%build
31export CONFIG_SHELL="/bin/sh" ; \
32export LDFLAGS="-Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp" ; \
33export LIBS="-lurpo -lmmap -lpthread" ; \
34%configure --docdir=%{_datadir}/doc/%{name}-%{version} \
35 --disable-dependency-tracking \
36 --enable-spf --with-logger-module=file \
37 --enable-shared --disable-static \
38 "--cache-file=%{_topdir}/cache/%{name}-%{_target_cpu}.cache"
39
40%__make %{?_smp_mflags}
41
42%install
43%__rm -rf %{buildroot}
44%__make DESTDIR=%{buildroot} install
45%__mkdir_p %{buildroot}%{_sysconfdir}/rc.d/init.d
46%__mkdir_p %{buildroot}%{_sysconfdir}/hermes
47%__mkdir_p %{buildroot}%{_localstatedir}/hermes
48%__install -m 0755 dists/fc_init %{buildroot}%{_sysconfdir}/rc.d/init.d/hermes
49%__install -m 0600 dists/hermesrc.example %{buildroot}%{_sysconfdir}/hermes/hermesrc
50
51%clean
52%__rm -rf %{buildroot}
53
54#%post
55#/sbin/chkconfig --add hermes
56
57#%preun
58#if [ $1 = 0 ]; then # execute this only if we are NOT doing an upgrade
59# %{_sysconfdir}/rc.d/init.d/hermes stop >/dev/null 2>&1
60# /sbin/chkconfig --del hermes
61#fi
62#exit 0
63
64%post
65%wps_object_create_begin
66HERMES_FOLDER:WPFolder|Hermes %version|<WP_DESKTOP>|TITLE=Hermes %version;
67HERMES_README:WPShadow|Readme 1st|<HERMES_FOLDER>|SHADOWID=((%_defaultdocdir/%name-%version/ReadMe.txt))
68HERMES_OPTIONS:WPShadow|Options|<HERMES_FOLDER>|SHADOWID=((%_defaultdocdir/%name-%version/hermes-options.html))
69HERMES_CONFIG:WPShadow|Options|<HERMES_FOLDER>|SHADOWID=((%_sysconfdir/hermes/hermesrc))
70HERMES_DAEMON:WPProgram|Hermes daemon|<HERMES_FOLDER>|EXENAME=((%_bindir/hermes.exe));STARTUPDIR=((%_bindir));ICONFILE=((%_defaultdocdir/%name-%version/hermes.ico));TITLE=Hermes daemon;
71%wps_object_create_end
72
73%postun
74%wps_object_delete_all
75
76%files
77%defattr(-, root, root, 0755)
78%doc ChangeLog TODO AUTHORS dists/hermesrc.example docs/hermes-options.html docs/installing-hermes.txt docs/gpl.txt
79%doc ReadMe.txt rotate.cmd white_host.cmd white_ips.cmd hermes.ico
80%{_bindir}/hermes.exe
81%{_sysconfdir}/rc.d/init.d/hermes
82%config %{_sysconfdir}/hermes/hermesrc
83%dir %attr(0700,nobody,nobody) %{_localstatedir}/hermes
84
85%changelog
Note: See TracBrowser for help on using the repository browser.