Pass rpmlint on spec file.

This commit is contained in:
Stuart Gathman
2008-10-09 02:43:16 +00:00
parent 0d1f2b7f4d
commit c86ad6f68c
3 changed files with 16 additions and 20 deletions
+14 -18
View File
@@ -2,9 +2,9 @@
# module. To compile all three on 32-bit Intel, use: # module. To compile all three on 32-bit Intel, use:
# rpmbuild -ba --target=i386,noarch pymilter.spec # rpmbuild -ba --target=i386,noarch pymilter.spec
%define __python python2.4 %define __python python
%define version 0.8.10 %define version 0.8.11
%define release 2%{?dist}.py24 %define release 1%{?dist}
# what version of RH are we building for? # what version of RH are we building for?
%define redhat7 0 %define redhat7 0
@@ -25,7 +25,7 @@
%ifos aix4.1 %ifos aix4.1
%define libdir /var/log/milter %define libdir /var/log/milter
%else %else
%define libdir /usr/lib/pymilter %define libdir %{_libdir}/pymilter
%endif %endif
%ifarch noarch %ifarch noarch
@@ -39,9 +39,7 @@ Source: pymilter-%{version}.tar.gz
License: GPL License: GPL
Group: Development/Libraries Group: Development/Libraries
BuildRoot: %{_tmppath}/%{name}-buildroot BuildRoot: %{_tmppath}/%{name}-buildroot
Prefix: %{_prefix}
Vendor: Stuart D. Gathman <stuart@bmsi.com> Vendor: Stuart D. Gathman <stuart@bmsi.com>
Packager: Stuart D. Gathman <stuart@bmsi.com>
Url: http://www.bmsi.com/python/milter.html Url: http://www.bmsi.com/python/milter.html
Requires: %{__python} >= 2.4, pyspf >= 2.0.4, pymilter Requires: %{__python} >= 2.4, pyspf >= 2.0.4, pymilter
%ifos Linux %ifos Linux
@@ -49,21 +47,23 @@ Requires: chkconfig
%endif %endif
%description -n milter %description -n milter
A complex but effective spam filtering, SPF checking, and reputation tracking A complex but effective spam filtering, SPF checking, greylisting,
mail application. It uses pydspam if installed for bayesian filtering. and reputation tracking mail application. It uses pydspam if installed for
bayesian filtering.
%package spf %package spf
Group: Applications/System Group: Applications/System
Summary: BMS spam and reputation milter Summary: BMS spam and reputation milter
Requires: pyspf >= 2.0.4, pymilter Requires: pyspf >= 2.0.4, pymilter
Obsoletes: pymilter-spf Obsoletes: pymilter-spf < 0.8.10
%description spf %description spf
A simple mail filter to add Received-SPF headers and reject forged mail. A simple mail filter to add Received-SPF headers and reject forged mail.
Rejection policy is configured via sendmail access file. Rejection policy is configured via sendmail access file and can be
tailored by domain.
%prep %prep
%setup -n pymilter-%{version} %setup -q -n pymilter-%{version}
#patch -p0 -b .bms #patch -p0 -b .bms
%install %install
@@ -201,9 +201,7 @@ Source: %{name}-%{version}.tar.gz
License: GPL License: GPL
Group: Development/Libraries Group: Development/Libraries
BuildRoot: %{_tmppath}/%{name}-buildroot BuildRoot: %{_tmppath}/%{name}-buildroot
Prefix: %{_prefix}
Vendor: Stuart D. Gathman <stuart@bmsi.com> Vendor: Stuart D. Gathman <stuart@bmsi.com>
Packager: Stuart D. Gathman <stuart@bmsi.com>
Url: http://www.bmsi.com/python/milter.html Url: http://www.bmsi.com/python/milter.html
Requires: %{__python} >= 2.4, sendmail >= 8.13 Requires: %{__python} >= 2.4, sendmail >= 8.13
BuildRequires: %{__python}-devel >= 2.4, sendmail-devel >= 8.13 BuildRequires: %{__python}-devel >= 2.4, sendmail-devel >= 8.13
@@ -215,7 +213,7 @@ modules provide for navigating and modifying MIME parts, sending
DSNs, and doing CBV. DSNs, and doing CBV.
%prep %prep
%setup %setup -q
#patch -p0 -b .bms #patch -p0 -b .bms
%build %build
@@ -235,8 +233,6 @@ mkdir -p $RPM_BUILD_ROOT%{libdir}
cat >$RPM_BUILD_ROOT%{libdir}/start.sh <<'EOF' cat >$RPM_BUILD_ROOT%{libdir}/start.sh <<'EOF'
#!/bin/sh #!/bin/sh
cd /var/log/milter cd /var/log/milter
# uncomment to enable sgmlop if installed
#export PYTHONPATH=/usr/local/lib/python2.1/site-packages
exec /usr/local/bin/python bms.py >>milter.log 2>&1 exec /usr/local/bin/python bms.py >>milter.log 2>&1
EOF EOF
%else # not aix4.1 %else # not aix4.1
@@ -252,7 +248,7 @@ EOF
%endif %endif
chmod a+x $RPM_BUILD_ROOT%{libdir}/start.sh chmod a+x $RPM_BUILD_ROOT%{libdir}/start.sh
%if !%{redhat7} %if !%{redhat7}
#grep '.pyc$' INSTALLED_FILES | sed -e 's/c$/o/' >>INSTALLED_FILES grep '.pyc$' INSTALLED_FILES | sed -e 's/c$/o/' >>INSTALLED_FILES
%endif %endif
# start.sh is used by spfmilter and milter, and could be used by # start.sh is used by spfmilter and milter, and could be used by
@@ -282,7 +278,7 @@ rm -rf $RPM_BUILD_ROOT
- Allow explicitly whitelisted email from banned_users. - Allow explicitly whitelisted email from banned_users.
- configure gossip TTL - configure gossip TTL
* Mon Sep 24 2007 Stuart Gathman <stuart@bmsi.com> 0.8.9-1 * Mon Sep 24 2007 Stuart Gathman <stuart@bmsi.com> 0.8.9-1
- Use %ifarch hack to build milter and milter-spf packages as noarch - Use ifarch hack to build milter and milter-spf packages as noarch
- Remove spf dependency from dsn.py, add dns.py - Remove spf dependency from dsn.py, add dns.py
* Fri Jan 05 2007 Stuart Gathman <stuart@bmsi.com> 0.8.8-1 * Fri Jan 05 2007 Stuart Gathman <stuart@bmsi.com> 0.8.8-1
- move AddrCache, parse_addr, iniplist to Milter package - move AddrCache, parse_addr, iniplist to Milter package
+1 -1
View File
@@ -1,5 +1,5 @@
[bdist_rpm] [bdist_rpm]
python=python2.4 #python=python2.4
doc_files=README NEWS TODO doc_files=README NEWS TODO
packager=Stuart D. Gathman <stuart@bmsi.com> packager=Stuart D. Gathman <stuart@bmsi.com>
release=1 release=1
+1 -1
View File
@@ -16,7 +16,7 @@ if sys.version < '2.2.3':
DistributionMetadata.download_url = None DistributionMetadata.download_url = None
# NOTE: importing Milter to obtain version fails when milter.so not built # NOTE: importing Milter to obtain version fails when milter.so not built
setup(name = "pymilter", version = '0.8.10', setup(name = "pymilter", version = '0.8.11',
description="Python interface to sendmail milter API", description="Python interface to sendmail milter API",
long_description="""\ long_description="""\
This is a python extension module to enable python scripts to This is a python extension module to enable python scripts to