From 9895b886e6f0ffce4865904a88fa6ddb245e0b52 Mon Sep 17 00:00:00 2001 From: Stuart D. Gathman Date: Aug 04 2018 23:00:42 +0000 Subject: Add python34 subpackage on el7 --- diff --git a/python-pymilter.spec b/python-pymilter.spec index 905ad30..26d5cdc 100644 --- a/python-pymilter.spec +++ b/python-pymilter.spec @@ -1,11 +1,16 @@ # we don't want to provide private python extension libs %global sum Python interface to sendmail milter API %global __provides_exclude_from ^(%{python2_sitearch})/.*\\.so$ +%if 0%{?epel} == 7 +%global python3 python34 +%else +%global python3 python3 +%endif Summary: %{sum} Name: python-pymilter Version: 1.0.2 -Release: 1%{?dist} +Release: 2%{?dist} Url: http://bmsi.com/pymilter Source: https://github.com/sdgathman/pymilter/archive/pymilter-%{version}.tar.gz Source1: tmpfiles-python-pymilter.conf @@ -13,7 +18,7 @@ Source1: tmpfiles-python-pymilter.conf Patch: pymilter-dns_dsn.patch License: GPLv2+ Group: Development/Libraries -BuildRequires: python2-devel, python3-devel, sendmail-devel >= 8.13 +BuildRequires: python2-devel, %{python3}-devel, sendmail-devel >= 8.13 # python-2.6.4 gets RuntimeError: not holding the import lock # Need python2.6 specific pydns, not the version for system python BuildRequires: gcc @@ -34,13 +39,13 @@ Requires: %{name}-common = %{version}-%{release} %description -n python2-pymilter %_description -%package -n python3-pymilter +%package -n %{python3}-pymilter Summary: %{sum} -Requires: python3-py3dns +Requires: %{python3}-py3dns Requires: %{name}-common = %{version}-%{release} -%{?python_provide:%python_provide python3-pymilter} +%{?python_provide:%python_provide %{python3}-pymilter} -%description -n python3-pymilter %_description +%description -n %{python3}-pymilter %_description %package common Summary: Common files and directories for python milters @@ -99,7 +104,7 @@ cp -p pymilter.pp %{buildroot}%{_datadir}/selinux/targeted %doc README ChangeLog NEWS TODO CREDITS sample.py milter-template.py %{python2_sitearch}/* -%files -n python3-pymilter +%files -n %{python3}-pymilter %license COPYING %doc README ChangeLog NEWS TODO CREDITS sample.py milter-template.py %{python3_sitearch}/* @@ -124,6 +129,9 @@ if [ $1 -eq 0 ] ; then fi %changelog +* Sat Aug 4 2018 Stuart Gathman - 1.0.2-2 +- add python34 subpackage on el7 + * Sat Aug 4 2018 Stuart Gathman - 1.0.2-1 - build for both python2 and python3 - add selinux policy allowing sendmail_t access to milters