SPECS: e2fsprogs.spec - build static version blkid, using uClibc -...

undefine undefine at pld-linux.org
Thu Jan 3 19:40:09 CET 2008


Author: undefine                     Date: Thu Jan  3 18:40:09 2008 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- build static version blkid, using uClibc - for allow detect root=label and
  root=uuid by our initrd

---- Files affected:
SPECS:
   e2fsprogs.spec (1.166 -> 1.167) 

---- Diffs:

================================================================
Index: SPECS/e2fsprogs.spec
diff -u SPECS/e2fsprogs.spec:1.166 SPECS/e2fsprogs.spec:1.167
--- SPECS/e2fsprogs.spec:1.166	Thu Jan  3 11:45:05 2008
+++ SPECS/e2fsprogs.spec	Thu Jan  3 19:40:04 2008
@@ -4,6 +4,12 @@
 %bcond_with	allstatic	# link everything statically
 %bcond_without	static		# link e2fsck dynamically with libc
 %bcond_without	nls		# build without NLS
+%bcond_without	initrd		# don't build initrd version
+%bcond_without	uClibc		# link initrd version with static glibc instead of uClibc
+#
+%ifarch sparc64 sparc
+%undefine       with_uClibc
+%endif
 #
 Summary:	Utilities for managing the second extended (ext2) filesystem
 Summary(cs.UTF-8):	Nástroje pro správu souborových systémů typu ext2
@@ -54,6 +60,15 @@
 BuildRequires:	libselinux-static
 BuildRequires:	libsepol-static
 %endif
+%if %{with initrd}
+	%if %{with uClibc}
+		%ifarch ppc
+BuildRequires:  uClibc-static >= 2:0.9.29
+		%else
+BuildRequires:  uClibc-static >= 2:0.9.26
+		%endif
+	%endif
+%endif
 Requires(post,postun):	/sbin/ldconfig
 Requires:	fsck = %{version}-%{release}
 Requires:	libcom_err = %{version}-%{release}
@@ -62,6 +77,9 @@
 Obsoletes:	libext2fs2
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+# changing CFLAGS in the middle confuses confcache
+%undefine       configure_cache
+
 %description
 The e2fsprogs package contains a number of utilities for creating,
 checking, modifying and correcting any inconsistencies in second
@@ -526,6 +544,19 @@
 %description -n fsck -l pl.UTF-8
 Sprawdzenie i naprawa linuksowego systemu plików.
 
+%package initrd
+Summary:	blkid - initrd version
+Summary(pl.UTF-8):	blkid - wersja dla initrd
+Group:	Base
+
+%description initrd
+This package includes a blkid utility to recognize partitions by label or uuid
+- staticaly linked for initrd.
+
+%description initrd -l pl.UTF-8
+Pakiet ten zawiera narzędzie blkid do rozpozywania partycji przez etykietke lub
+uuid - statycznie skonsolidowane na potrzeby initrd.
+
 %prep
 %setup -q
 %patch0 -p1
@@ -546,6 +577,23 @@
 %{__gettextize}
 %{__aclocal}
 %{__autoconf}
+
+%if %{with initrd}
+%configure \
+	%{?with_uClibc:CC="%{_target_cpu}-uclibc-gcc"} \
+	ac_cv_lib_dl_dlopen=no \
+	--with-ccopts="-Os" \
+	--with-ldopts="-static" \
+	--disable-elf-shlibs \
+	--disable-selinux \
+	--disable-nls
+
+%{__make} -j1 libs
+%{__make} progs
+mv -f misc/blkid initrd-blkid
+%{__make} clean
+%endif
+
 %configure \
 	--with-root-prefix="" \
 	%{!?with_nls:--disable-nls} \
@@ -608,6 +656,8 @@
 rm -f $RPM_BUILD_ROOT%{_mandir}/README.e2fsprogs-non-english-man-pages
 touch $RPM_BUILD_ROOT%{_sysconfdir}/blkid.tab
 
+%{?with_initrd:install initrd-blkid $RPM_BUILD_ROOT/sbin/initrd-blkid}
+
 %clean
 rm -rf $RPM_BUILD_ROOT
 
@@ -749,12 +799,22 @@
 %lang(ko) %{_mandir}/ko/man8/fsck.8*
 %lang(pl) %{_mandir}/pl/man8/fsck.8*
 
+%if %{with initrd}
+%files initrd
+%defattr(644,root,root,755)
+%attr(755,root,root) /sbin/initrd-blkid
+%endif
+
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
 * %{date} PLD Team <feedback at pld-linux.org>
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.167  2008-01-03 18:40:04  undefine
+- build static version blkid, using uClibc - for allow detect root=label and
+  root=uuid by our initrd
+
 Revision 1.166  2008-01-03 10:45:05  glen
 - rel 2
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/e2fsprogs.spec?r1=1.166&r2=1.167&f=u



More information about the pld-cvs-commit mailing list