SPECS (AC-branch): glibc.spec - add code that makes it possible do...

glen glen at pld-linux.org
Wed Jun 15 13:39:38 CEST 2005


Author: glen                         Date: Wed Jun 15 11:39:38 2005 GMT
Module: SPECS                         Tag: AC-branch
---- Log message:
- add code that makes it possible do major upgrade (glibc 2.2 -> glibc 2.3) on systems with /lib/%{arch}

---- Files affected:
SPECS:
   glibc.spec (1.583.2.18 -> 1.583.2.19) 

---- Diffs:

================================================================
Index: SPECS/glibc.spec
diff -u SPECS/glibc.spec:1.583.2.18 SPECS/glibc.spec:1.583.2.19
--- SPECS/glibc.spec:1.583.2.18	Sun Jun 12 13:04:31 2005
+++ SPECS/glibc.spec	Wed Jun 15 13:39:32 2005
@@ -78,7 +78,7 @@
 Summary(uk):	GNU libc ×ĹŇÓŚ§ 2.3
 Name:		glibc
 Version:	2.3.5
-Release:	3
+Release:	3.1
 Epoch:		6
 License:	LGPL
 Group:		Libraries
@@ -96,6 +96,7 @@
 Source6:	%{name}-non-english-man-pages.tar.bz2
 # Source6-md5:	6159f0a9b6426b5f6fc1b0d8d21b9b76
 Source7:	%{name}-localedb-gen
+Source8:	%{name}-LD-path.c
 Patch0:		%{name}-info.patch
 Patch1:		%{name}-pl.po-update.patch
 Patch2:		%{name}-pld.patch
@@ -151,6 +152,7 @@
 BuildRequires:	rpmbuild(macros) >= 1.213
 BuildRequires:	sed >= 4.0.5
 BuildRequires:	texinfo
+BuildRequires:	dietlibc-static
 AutoReq:	false
 PreReq:		basesystem
 Requires:	glibc-misc = %{epoch}:%{version}-%{release}
@@ -878,6 +880,12 @@
 done
 %endif
 
+diet -Os %{__cc} %{SOURCE8} %{rpmcflags} -static -o glibc-postinst
+# compiling static using diet vs glibc saves 400k
+# TODO: use SOURCEX
+# TODO2: remove fprintf/fopen from postshell.c to save 7kb?
+diet -Os %{__cc} elf/postshell.c %{rpmcflags} -static -o postshell
+
 %install
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT{/etc/{logrotate.d,rc.d/init.d,sysconfig},%{_mandir}/man{3,8},/var/log,/var/{lib,run}/nscd}
@@ -902,10 +910,11 @@
 install $PICFILES				$RPM_BUILD_ROOT%{_libdir}
 install elf/soinit.os				$RPM_BUILD_ROOT%{_libdir}/soinit.o
 install elf/sofini.os				$RPM_BUILD_ROOT%{_libdir}/sofini.o
-
-install elf/postshell				$RPM_BUILD_ROOT/sbin
 cd ..
 
+install postshell					$RPM_BUILD_ROOT/sbin
+install glibc-postinst				$RPM_BUILD_ROOT/sbin
+
 %if %{with dual}
 env LANGUAGE=C LC_ALL=C \
 %{__make} -C builddir-nptl install \
@@ -1081,6 +1090,7 @@
 %else
 %post	-p /sbin/postshell
 %endif
+/sbin/glibc-postinst /%{_lib}/%{_host_cpu}
 /sbin/ldconfig
 -/sbin/telinit u
 
@@ -1164,6 +1174,7 @@
 %defattr(644,root,root,755)
 %doc README NEWS FAQ BUGS
 %attr(755,root,root) /sbin/postshell
+%attr(755,root,root) /sbin/glibc-postinst
 %attr(755,root,root) /sbin/ldconfig
 # ld* and libc.so.6 SONAME symlinks must be in package because of
 # chicken-egg problem (postshell is dynamically linked with libc);
@@ -1499,6 +1510,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.583.2.19  2005/06/15 11:39:32  glen
+- add code that makes it possible do major upgrade (glibc 2.2 -> glibc 2.3) on systems with /lib/%{arch}
+
 Revision 1.583.2.18  2005/06/12 11:04:31  paszczus
 - added BR: autoconf
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SPECS/glibc.spec?r1=1.583.2.18&r2=1.583.2.19&f=u




More information about the pld-cvs-commit mailing list