On Wed, 2012-03-07 at 09:33 +0100, Jan Cholasta wrote:
> On 6.3.2012 16:40, Stephen Gallagher wrote:
> > Jan Cholasta noticed that our upstream builder wasn't producing
> > experimental packages into the ipa-devel repository. This was due to the
> > builders not setting the enable_experimental variable. Patch 0003 in
> > this set now makes that the default in the spec file. I left it
> > conditionalized so that it's easy for other packagers to take the spec
> > and turn the experimental features back off.
> >
> > Patch 0001 makes a change that we made in Fedora some time ago to
> > properly handle filtering Provides: for our python library. The other
> > approach was long outdated and broke multilib on Fedora 17.
> 
> Missing a caret and a backslash:
> 
> %define __provides_exclude_from ^%{python_sitearch}.*\.so$
> 
> Besides that, ACK.
> 

The caret is not needed, according to http://goo.gl/XDx76
(Packaging:AutoProvidesAndRequiresFiltering)

However, you're right that the backslash should be there. Also, I need
to conditionalize this some more; RHEL5 doesn't have this macro, so we
still need to use the old version there.

New patch attached.

> >
> > Patch 0002 is a cleanup patch to make the set of files we're installing
> > explicit, so we can easily catch mistakes. Previously we were installing
> > files by glob, which meant we could have missed some if we didn't notice
> > that they hadn't built.
> 
> ACK.
> 
> >
> > Patch 0003 makes building the experimental features the default for
> > 'make rpms'.
> >
> 
> Please update the makefile too, "make rpms" and "make experimental-rpms" 
> now do exactly the same thing.

Thanks, fixed in new patch.


From 7d5c3c9843692cab544ebd3f01bd3775391eb11d Mon Sep 17 00:00:00 2001
From: Stephen Gallagher <sgall...@redhat.com>
Date: Tue, 6 Mar 2012 10:35:51 -0500
Subject: [PATCH 1/3] Prune python provides correctly

---
 contrib/sssd.spec.in |   15 +++++++++------
 1 files changed, 9 insertions(+), 6 deletions(-)

diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
index e82a56af0b6bc5f98b0b90d292b14c844e1a5c3d..8cde7884f7223da64aa8240492873d9664eb14b3 100644
--- a/contrib/sssd.spec.in
+++ b/contrib/sssd.spec.in
@@ -3,15 +3,18 @@
 %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
 %endif
 
-# we don't want to provide private python extension libs
-%{?filter_setup:
-%filter_provides_in %{python_sitearch}/.*\.so$ 
-%filter_setup
-}
-
 %if (0%{?rhel} == 5)
 %{!?is_rhel57: %global is_rhel57 %(%{__grep} -c "5\.[^0-6]" /etc/redhat-release)}
 %global with_unicode_lib --with-unicode-lib=glib2
+# we don't want to provide private python extension libs
+%{?filter_setup:
+%filter_provides_in %{python_sitearch}/.*\.so$
+%filter_setup
+}
+%else
+# Fedora and RHEL 6+
+# we don't want to provide private python extension libs
+%define __provides_exclude_from %{python_sitearch}.*\.so$
 %endif
 
 %if (0%{?enable_experimental} == 1)
-- 
1.7.7.6

From 399fb0555217072e57b82a7d10b554e6a952df44 Mon Sep 17 00:00:00 2001
From: Stephen Gallagher <sgall...@redhat.com>
Date: Tue, 6 Mar 2012 09:59:54 -0500
Subject: [PATCH 2/3] Make RPM spec more explicit

It will be easier to catch errors at build-time
---
 contrib/sssd.spec.in |   22 ++++++++++++++++++++--
 1 files changed, 20 insertions(+), 2 deletions(-)

diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
index 8cde7884f7223da64aa8240492873d9664eb14b3..d989e2e98c2ff54651dff3e7873e1fb074d256ea 100644
--- a/contrib/sssd.spec.in
+++ b/contrib/sssd.spec.in
@@ -287,8 +287,26 @@ rm -rf $RPM_BUILD_ROOT
 %doc src/examples/sssd-example.conf
 %{_initrddir}/%{name}
 %{_sbindir}/sssd
-%{_libexecdir}/%{servicename}/
-%{_libdir}/%{name}/
+
+%{_libexecdir}/%{servicename}/krb5_child
+%{_libexecdir}/%{servicename}/ldap_child
+%{_libexecdir}/%{servicename}/proxy_child
+%{_libexecdir}/%{servicename}/sssd_be
+%{_libexecdir}/%{servicename}/sssd_nss
+%{_libexecdir}/%{servicename}/sssd_pam
+
+%if (0%{?enable_experimental} == 1)
+%{_libexecdir}/%{servicename}/sssd_autofs
+%{_libexecdir}/%{servicename}/sssd_ssh
+%{_libexecdir}/%{servicename}/sssd_sudo
+%endif
+
+%{_libdir}/%{name}/libsss_ipa.so
+%{_libdir}/%{name}/libsss_krb5.so
+%{_libdir}/%{name}/libsss_ldap.so
+%{_libdir}/%{name}/libsss_proxy.so
+%{_libdir}/%{name}/libsss_simple.so
+
 %{ldb_modulesdir}/memberof.so
 %if (0%{?enable_experimental} == 1)
 %{_bindir}/sss_ssh_authorizedkeys
-- 
1.7.7.6

From b683fd41b407548133a3e7cf462cb8d7e08df83e Mon Sep 17 00:00:00 2001
From: Stephen Gallagher <sgall...@redhat.com>
Date: Tue, 6 Mar 2012 10:24:56 -0500
Subject: [PATCH 3/3] Build experimental features by default in RPMs

---
 Makefile.am          |    6 ------
 contrib/sssd.spec.in |    2 ++
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 30a640d140233b7dfe3c02ad24c2e41fedd011b3..7fcdeee5e17007bdcd1ac63dbe482320677736d9 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1454,12 +1454,6 @@ rpms: rpmbrprep
 	cd $(RPMBUILD); \
 	rpmbuild --define "_topdir $(RPMBUILD)" -ba SPECS/sssd.spec
 
-experimental-rpms: rpmbrprep
-	cd $(RPMBUILD); \
-	rpmbuild --define "_topdir $(RPMBUILD)"   \
-		 --define "enable_experimental 1" \
-		 -ba SPECS/sssd.spec
-
 if GIT_CHECKOUT
 prerelease-rpms:
 	cp $(srcdir)/version.m4 $(srcdir)/version.m4.orig
diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
index d989e2e98c2ff54651dff3e7873e1fb074d256ea..8d1cf41d4486d3893747455a67134e9cdcd0175c 100644
--- a/contrib/sssd.spec.in
+++ b/contrib/sssd.spec.in
@@ -17,6 +17,8 @@
 %define __provides_exclude_from %{python_sitearch}.*\.so$
 %endif
 
+%global enable_experimental 1
+
 %if (0%{?enable_experimental} == 1)
 %global experimental --enable-all-experimental-features
 %endif
-- 
1.7.7.6

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
sssd-devel mailing list
sssd-devel@lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/sssd-devel

Reply via email to