Split internal helper libraries into a shared object
- Significantly reduce disk-space usage
This commit is contained in:
parent
21a05ac540
commit
c0672862e6
134
0006-BUILD-Build-shared-components-as-an-internal-shared-.patch
Normal file
134
0006-BUILD-Build-shared-components-as-an-internal-shared-.patch
Normal file
@ -0,0 +1,134 @@
|
||||
From 96453f402831275a39d5fb89c33c9776e148d03f Mon Sep 17 00:00:00 2001
|
||||
From: Stephen Gallagher <sgallagh@redhat.com>
|
||||
Date: Fri, 22 Feb 2013 15:58:52 +0100
|
||||
Subject: [PATCH] BUILD: Build shared components as an internal shared library
|
||||
|
||||
There is a large amount of duplicated code being linked into multiple
|
||||
SSSD binaries. Instead of statically linking this code throughout the
|
||||
SSSD, we should instead create private shared libraries for them and
|
||||
drop this code on the system only once.
|
||||
---
|
||||
Makefile.am | 25 +++++++++++++++++++------
|
||||
contrib/sssd.spec.in | 8 ++++++++
|
||||
2 files changed, 27 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index 64708216103e48facf780f246de5668c8e0b26a7..4ff02b8e7f65876c6d42217e955053f420111132 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -176,7 +176,9 @@ krb5authdata_plugin_LTLIBRARIES = \
|
||||
sssd_pac_plugin.la
|
||||
endif
|
||||
|
||||
-noinst_LTLIBRARIES = \
|
||||
+noinst_LTLIBRARIES =
|
||||
+
|
||||
+pkglib_LTLIBRARIES = \
|
||||
libsss_crypt.la
|
||||
|
||||
if HAVE_NSS
|
||||
@@ -203,6 +205,8 @@ libsss_crypt_la_CFLAGS = \
|
||||
$(DHASH_CFLAGS)
|
||||
libsss_crypt_la_LIBADD = \
|
||||
$(SSS_CRYPT_LIBS)
|
||||
+libsss_crypt_la_LDFLAGS = \
|
||||
+ -avoid-version
|
||||
|
||||
if BUILD_PYTHON_BINDINGS
|
||||
pyexec_LTLIBRARIES = \
|
||||
@@ -471,15 +475,18 @@ endif
|
||||
#####################
|
||||
# Utility libraries #
|
||||
#####################
|
||||
-noinst_LTLIBRARIES += libsss_debug.la
|
||||
+pkglib_LTLIBRARIES += libsss_debug.la
|
||||
libsss_debug_la_SOURCES = \
|
||||
src/util/debug.c \
|
||||
src/util/sss_log.c
|
||||
+libsss_debug_la_LDFLAGS = \
|
||||
+ -avoid-version
|
||||
|
||||
-noinst_LTLIBRARIES += libsss_child.la
|
||||
+pkglib_LTLIBRARIES += libsss_child.la
|
||||
libsss_child_la_SOURCES = src/util/child_common.c
|
||||
+libsss_child_la_LDFLAGS = -avoid-version
|
||||
|
||||
-noinst_LTLIBRARIES += libsss_util.la
|
||||
+pkglib_LTLIBRARIES += libsss_util.la
|
||||
libsss_util_la_SOURCES = \
|
||||
src/confdb/confdb.c \
|
||||
src/db/sysdb.c \
|
||||
@@ -532,6 +539,7 @@ libsss_util_la_SOURCES += \
|
||||
src/db/sysdb_ssh.c \
|
||||
src/util/sss_ssh.c
|
||||
endif
|
||||
+libsss_util_la_LDFLAGS = -avoid-version
|
||||
|
||||
lib_LTLIBRARIES = libipa_hbac.la libsss_idmap.la
|
||||
dist_pkgconfig_DATA += src/providers/ipa/ipa_hbac.pc
|
||||
@@ -1251,7 +1259,7 @@ endif
|
||||
# Plugin Libraries #
|
||||
####################
|
||||
|
||||
-noinst_LTLIBRARIES += libsss_ldap_common.la
|
||||
+pkglib_LTLIBRARIES += libsss_ldap_common.la
|
||||
libsss_ldap_common_la_SOURCES = \
|
||||
src/providers/ldap/ldap_id.c \
|
||||
src/providers/ldap/ldap_id_enum.c \
|
||||
@@ -1278,6 +1286,8 @@ libsss_ldap_common_la_SOURCES = \
|
||||
src/providers/ldap/sdap_range.c \
|
||||
src/providers/ldap/sdap_reinit.c \
|
||||
src/providers/ldap/sdap.c
|
||||
+libsss_ldap_common_la_LDFLAGS = \
|
||||
+ -avoid-version
|
||||
|
||||
if BUILD_SUDO
|
||||
libsss_ldap_common_la_SOURCES += \
|
||||
@@ -1295,7 +1305,7 @@ libsss_ldap_common_la_SOURCES += \
|
||||
endif
|
||||
|
||||
|
||||
-noinst_LTLIBRARIES += libsss_krb5_common.la
|
||||
+pkglib_LTLIBRARIES += libsss_krb5_common.la
|
||||
libsss_krb5_common_la_SOURCES = \
|
||||
src/providers/krb5/krb5_utils.c \
|
||||
src/providers/krb5/krb5_become_user.c \
|
||||
@@ -1307,6 +1317,8 @@ libsss_krb5_common_la_SOURCES = \
|
||||
src/providers/krb5/krb5_access.c \
|
||||
src/providers/krb5/krb5_child_handler.c \
|
||||
src/providers/krb5/krb5_init_shared.c
|
||||
+libsss_krb5_common_la_LDFLAGS = \
|
||||
+ -avoid-version
|
||||
|
||||
libsss_ldap_la_SOURCES = \
|
||||
src/util/find_uid.c \
|
||||
@@ -1658,6 +1670,7 @@ installsssddirs::
|
||||
$(DESTDIR)$(dbusintrospectdir) \
|
||||
$(DESTDIR)$(pipepath)/private \
|
||||
$(DESTDIR)$(sssdlibdir) \
|
||||
+ $(DESTDIR)$(pkglibdir) \
|
||||
$(DESTDIR)$(sssdconfdir) \
|
||||
$(DESTDIR)$(sssddatadir) \
|
||||
$(DESTDIR)$(dbpath) \
|
||||
diff --git a/contrib/sssd.spec.in b/contrib/sssd.spec.in
|
||||
index 2a0401d1b8bb538fe596b2c762f7e0bbeb1abef9..7f124f5cd9dc602481cb5f4ae7a5a9418b6c8bf9 100644
|
||||
--- a/contrib/sssd.spec.in
|
||||
+++ b/contrib/sssd.spec.in
|
||||
@@ -385,6 +385,14 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%{_libdir}/%{name}/libsss_proxy.so
|
||||
%{_libdir}/%{name}/libsss_simple.so
|
||||
|
||||
+#Internal shared libraries
|
||||
+%{_libdir}/%{name}/libsss_child.so
|
||||
+%{_libdir}/%{name}/libsss_crypt.so
|
||||
+%{_libdir}/%{name}/libsss_debug.so
|
||||
+%{_libdir}/%{name}/libsss_krb5_common.so
|
||||
+%{_libdir}/%{name}/libsss_ldap_common.so
|
||||
+%{_libdir}/%{name}/libsss_util.so
|
||||
+
|
||||
%{ldb_modulesdir}/memberof.so
|
||||
%{_bindir}/sss_ssh_authorizedkeys
|
||||
%{_bindir}/sss_ssh_knownhostsproxy
|
||||
--
|
||||
1.8.1.2
|
||||
|
15
sssd.spec
15
sssd.spec
@ -16,7 +16,7 @@
|
||||
|
||||
Name: sssd
|
||||
Version: 1.9.4
|
||||
Release: 8%{?dist}
|
||||
Release: 9%{?dist}
|
||||
Group: Applications/System
|
||||
Summary: System Security Services Daemon
|
||||
License: GPLv3+
|
||||
@ -30,6 +30,7 @@ Patch0002: 0002-Don-t-use-srcdir-with-tests.patch
|
||||
Patch0003: 0003-krb5-include-backwards-compatible-declaration-of-krb.patch
|
||||
Patch0004: 0004-subdomains-replace-invalid-characters-with-underscor.patch
|
||||
Patch0005: 0005-Fix-the-krb5-password-expiration-warning.patch
|
||||
Patch0006: 0006-BUILD-Build-shared-components-as-an-internal-shared-.patch
|
||||
|
||||
Patch0501: 0501-FEDORA-Switch-the-default-ccache-location.patch
|
||||
|
||||
@ -356,6 +357,14 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%{_libdir}/%{name}/libsss_simple.so
|
||||
%{_libdir}/%{name}/libsss_ad.so
|
||||
|
||||
#Internal shared libraries
|
||||
%{_libdir}/%{name}/libsss_child.so
|
||||
%{_libdir}/%{name}/libsss_crypt.so
|
||||
%{_libdir}/%{name}/libsss_debug.so
|
||||
%{_libdir}/%{name}/libsss_krb5_common.so
|
||||
%{_libdir}/%{name}/libsss_ldap_common.so
|
||||
%{_libdir}/%{name}/libsss_util.so
|
||||
|
||||
%{ldb_modulesdir}/memberof.so
|
||||
%{_bindir}/sss_ssh_authorizedkeys
|
||||
%{_bindir}/sss_ssh_knownhostsproxy
|
||||
@ -529,6 +538,10 @@ fi
|
||||
%postun -n libsss_sudo -p /sbin/ldconfig
|
||||
|
||||
%changelog
|
||||
* Fri Mar 01 2013 Stpehen Gallagher <sgallagh@redhat.com> - 1.9.5-9
|
||||
- Split internal helper libraries into a shared object
|
||||
- Significantly reduce disk-space usage
|
||||
|
||||
* Thu Feb 14 2013 Jakub Hrozek <jhrozek@redhat.com> - 1.9.4-8
|
||||
- Fix the Kerberos password expiration warning (#912223)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user