URL: https://github.com/freeipa/freeipa/pull/2325
Author: t-woerner
 Title: #2325: Adapt freeipa.spec.in for latest Fedora, fix python2 ipatests 
packaging bug
Action: opened

PR body:
"""
Added source 1 for asc file, added download link for source 0.
"""

To pull the PR as Git branch:
git remote add ghfreeipa https://github.com/freeipa/freeipa
git fetch ghfreeipa pull/2325/head:pr2325
git checkout pr2325
From f811bbfed7a0b721933dfc8cfb658946f30ea113 Mon Sep 17 00:00:00 2001
From: Thomas Woerner <twoer...@redhat.com>
Date: Tue, 4 Sep 2018 15:24:21 +0200
Subject: [PATCH] Adapt freeipa.spec.in for latest Fedora, fix python2 ipatests
 packaging bug

Added source 1 for asc file, added download link for source 0.
---
 freeipa.spec.in | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)

diff --git a/freeipa.spec.in b/freeipa.spec.in
index cffbccd72e..2544e55f43 100644
--- a/freeipa.spec.in
+++ b/freeipa.spec.in
@@ -1,7 +1,9 @@
 # 389-ds-base 1.4 no longer supports i686 platform, build only client
 # packages, https://bugzilla.redhat.com/show_bug.cgi?id=1544386
-%ifarch %{ix86}
-%{!?ONLY_CLIENT:%global ONLY_CLIENT 1}
+%if 0%{?fedora} >= 28 || 0%{?rhel} > 7
+    %ifarch %{ix86}
+        %{!?ONLY_CLIENT:%global ONLY_CLIENT 1}
+    %endif
 %endif
 
 # Define ONLY_CLIENT to only make the ipa-client and ipa-python
@@ -35,6 +37,9 @@
 %if 0%{?fedora} >= 29
     # F29 only supports Python 3 as default Python
     %global with_default_python 3
+    %if 0%{?fedora} >= 30
+        %global with_python2 0
+    %endif
 %endif
 
 %{!?with_default_python:%global with_default_python 3}
@@ -125,7 +130,8 @@ Summary:        The Identity, Policy and Audit system
 Group:          System Environment/Base
 License:        GPLv3+
 URL:            http://www.freeipa.org/
-Source0:        freeipa-%{version}.tar.gz
+Source0:        https://releases.pagure.org/freeipa/freeipa-%{version}.tar.gz
+Source1:        https://releases.pagure.org/freeipa/freeipa-%{version}.tar.gz.asc
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  openldap-devel
@@ -961,6 +967,8 @@ find \
 	-type f -exec grep -qsm1 '^#!.*\bpython' {} \; \
 	-exec sed -i -e '1 s|^#!.*\bpython[^ ]*|#!%{__python2}|' {} \;
 
+aclocal --force
+autoconf --force
 %configure --with-vendor-suffix=-%{release} \
            %{enable_server_option} \
            %{with_ipatests_option} \
@@ -970,6 +978,8 @@ popd
 
 export PYTHON=%{__python3}
 pushd %{_builddir}/freeipa-%{version}-python3
+aclocal --force
+autoconf --force
 %configure --with-vendor-suffix=-%{release} \
            %{enable_server_option} \
            %{with_ipatests_option} \
@@ -1016,7 +1026,7 @@ ln -rs %{buildroot}%{_bindir}/ipa-test-task-%{python3_version} %{buildroot}%{_bi
 pushd %{_builddir}/freeipa-%{version}-python2
 %{__make} python_install DESTDIR=%{?buildroot} INSTALL="%{__install} -p"
 popd
-%if 0%{?with_python2} && 0%{?fedora} < 29
+%if 0%{?with_ipatests} && 0%{?fedora} < 29
 # Fedora 29 workaround: don't ship ipatests binaries
 mv %{buildroot}%{_bindir}/ipa-run-tests %{buildroot}%{_bindir}/ipa-run-tests-%{python2_version}
 mv %{buildroot}%{_bindir}/ipa-test-config %{buildroot}%{_bindir}/ipa-test-config-%{python2_version}
_______________________________________________
FreeIPA-devel mailing list -- freeipa-devel@lists.fedorahosted.org
To unsubscribe send an email to freeipa-devel-le...@lists.fedorahosted.org
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedorahosted.org/archives/list/freeipa-devel@lists.fedorahosted.org

Reply via email to