]> git.pld-linux.org Git - packages/opendkim.git/blame - opendkim.spec
PLDize; default configs; init script; rel 0.2 (wip)
[packages/opendkim.git] / opendkim.spec
CommitLineData
a42a830d
AM
1Summary: A DomainKeys Identified Mail (DKIM) milter to sign and/or verify mail
2Name: opendkim
f05a0816 3Version: 2.10.3
76407ed7 4Release: 0.2
a42a830d
AM
5License: BSD and Sendmail
6Group: Daemons
a42a830d 7Source0: http://downloads.sourceforge.net/opendkim/%{name}-%{version}.tar.gz
76407ed7 8Source1: %{name}.conf
9Source2: %{name}.sysconfig
10Source3: %{name}.init
11Source4: signing.table
12Source5: key.table
13Source6: trusted.hosts
f05a0816 14# Source0-md5: 916e691cdd16cfabd1cd6efe745323f9
96702607 15URL: http://opendkim.org/
a42a830d 16BuildRequires: db-devel
f05a0816 17BuildRequires: libbsd-devel
a42a830d 18BuildRequires: libmemcached-devel
f05a0816 19BuildRequires: libmilter-devel
a42a830d
AM
20BuildRequires: openssl-devel
21BuildRequires: pkgconfig
a42a830d
AM
22BuildRequires: unbound-devel
23Requires: %{name}-libs = %{version}-%{release}
24BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25
76407ed7 26%define no_install_post_check_tmpfiles 1
27
a42a830d
AM
28%description
29OpenDKIM allows signing and/or verification of email through an open
30source library that implements the DKIM service, plus a milter-based
31filter application that can plug in to any milter-aware MTA, including
32sendmail, Postfix, or any other MTA that supports the milter protocol.
33
34%package libs
35Summary: An open source DKIM library
36Group: Libraries
37
38%description libs
39This package contains the library files required for running services
40built using libopendkim.
41
42%package libs-devel
43Summary: Development files for libopendkim
44Group: Development/Libraries
96702607 45Requires: %{name}-libs = %{version}-%{release}
a42a830d
AM
46
47%description libs-devel
48This package contains the static libraries, headers, and other support
49files required for developing applications against libopendkim.
50
51%prep
52%setup -q
53
54%build
55%configure \
56 --with-unbound \
57 --with-libmemcached \
58 --with-db \
59
60%install
61rm -rf $RPM_BUILD_ROOT
a42a830d
AM
62%{__make} install \
63 DESTDIR=$RPM_BUILD_ROOT
64
76407ed7 65install -d $RPM_BUILD_ROOT%{_sysconfdir}/{sysconfig,%{name}/keys}
a42a830d
AM
66install -d $RPM_BUILD_ROOT%{_initrddir}
67install -d $RPM_BUILD_ROOT%{systemdunitdir}
76407ed7 68install -d $RPM_BUILD_ROOT%{_localstatedir}/spool/%{name}
69install -d $RPM_BUILD_ROOT%{_localstatedir}/run/%{name}
70cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/%{name}
71cp -p %{SOURCE3} $RPM_BUILD_ROOT%{_initrddir}/%{name}
72cp -p %{SOURCE1} %{SOURCE4} %{SOURCE5} %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
73#cp -p contrib/systemd/%{name}.service $RPM_BUILD_ROOT%{systemdunitdir}/%{name}.service
a42a830d
AM
74cp -p contrib/init/redhat/%{name}-default-keygen $RPM_BUILD_ROOT%{_sbindir}/%{name}-default-keygen
75
a42a830d
AM
76%clean
77rm -rf $RPM_BUILD_ROOT
78
76407ed7 79%pre
80%groupadd -g 322 -r %{name}
81%useradd -r -u 322 -d /usr/share/empty -s /bin/false -c "OpenDKIM User" -g %{name} %{name}
82# MTA group in general?
83#%addusertogroup %{name} postfix
84
85%preun
86if [ "$1" = "0" ];then
87 %service %{name} stop
88 /sbin/chkconfig --del %{name}
89fi
90%systemd_preun %{name}.service
91
92%postun
93if [ "$1" = "0" ]; then
94 %userremove %{name}
95 %groupremove %{name}
96fi
97%systemd_reload
96702607 98
a42a830d
AM
99%files
100%defattr(644,root,root,755)
101%doc FEATURES KNOWNBUGS LICENSE LICENSE.Sendmail RELEASE_NOTES RELEASE_NOTES.Sendmail INSTALL
102%doc contrib/convert/convert_keylist.sh %{name}/*.sample
103%doc %{name}/%{name}.conf.simple-verify %{name}/%{name}.conf.simple
76407ed7 104%doc %{name}/README
105%attr(754,root,root) /etc/rc.d/init.d/%{name}
106%config(noreplace) %attr(640,%{name},%{name}) %{_sysconfdir}/%{name}/%{name}.conf
107%config(noreplace) %attr(640,%{name},%{name}) %{_sysconfdir}/%{name}/signing.table
108%config(noreplace) %attr(640,%{name},%{name}) %{_sysconfdir}/%{name}/key.table
109%config(noreplace) %attr(640,%{name},%{name}) %{_sysconfdir}/%{name}/trusted.hosts
a42a830d 110%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name}
76407ed7 111%dir %attr(700,%{name},%{name}) %{_sysconfdir}/%{name}/keys
112%attr(755,root,root) %{_sbindir}/%{name}*
113%{_mandir}/man*/*
a42a830d 114%dir %attr(-,%{name},%{name}) %{_localstatedir}/spool/%{name}
76407ed7 115%dir %attr(770,root,%{name}) %{_localstatedir}/run/%{name}
a42a830d 116%dir %attr(-,root,%{name}) %{_sysconfdir}/%{name}
76407ed7 117#%{systemdunitdir}/%{name}.service
a42a830d
AM
118
119%files libs
120%defattr(644,root,root,755)
121%doc LICENSE LICENSE.Sendmail README
122%{_libdir}/libopendkim.so.*
123
124%files libs-devel
125%defattr(644,root,root,755)
126%doc LICENSE LICENSE.Sendmail
127%doc libopendkim/docs/*.html
128%{_includedir}/%{name}
129%{_libdir}/*.so
130%{_pkgconfigdir}/*.pc
This page took 0.149793 seconds and 4 git commands to generate.