SPECS: cryptsetup-luks.spec - rel 9 - added dietlibc bcond - build initrd p...

baggins baggins at pld-linux.org
Wed Mar 18 21:44:38 CET 2009


Author: baggins                      Date: Wed Mar 18 20:44:38 2009 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- rel 9
- added dietlibc bcond
- build initrd package with dietlibc by default
- disabled selinux on initrd dietlibc

---- Files affected:
SPECS:
   cryptsetup-luks.spec (1.36 -> 1.37) 

---- Diffs:

================================================================
Index: SPECS/cryptsetup-luks.spec
diff -u SPECS/cryptsetup-luks.spec:1.36 SPECS/cryptsetup-luks.spec:1.37
--- SPECS/cryptsetup-luks.spec:1.36	Thu Feb 26 16:20:23 2009
+++ SPECS/cryptsetup-luks.spec	Wed Mar 18 21:44:32 2009
@@ -1,14 +1,15 @@
 # $Revision$, $Date$
 #
 # Conditonal build:
-%bcond_without	initrd	# don't build initrd version
+%bcond_without	initrd		# don't build initrd version
+%bcond_without	dietlibc	# build initrd version with static glibc instead of dietlibc
 #
 %define	realname	cryptsetup
 Summary:	LUKS for dm-crypt implemented in cryptsetup
 Summary(pl.UTF-8):	LUKS dla dm-crypta zaimplementowany w cryptsetup
 Name:		cryptsetup-luks
 Version:	1.0.6
-Release:	8
+Release:	9
 License:	GPL v2
 Group:		Base
 Source0:	http://luks.endorphin.org/source/%{realname}-%{version}.tar.bz2
@@ -32,13 +33,20 @@
 BuildRequires:	libuuid-devel
 BuildRequires:	popt-devel
 %if %{with initrd}
+BuildRequires:	libgpg-error-static
+	%if %{with dietlibc}
+BuildRequires:	device-mapper-dietlibc
+BuildRequires:	libgcrypt-dietlibc
+BuildRequires:	libuuid-dietlibc
+BuildRequires:	popt-dietlibc
+	%else
 BuildRequires:	device-mapper-static >= 1.02.07
 BuildRequires:	libgcrypt-static >= 1.1.42
-BuildRequires:	libgpg-error-static
 BuildRequires:	libselinux-static
 BuildRequires:	libsepol-static
 BuildRequires:	libuuid-static
 BuildRequires:	popt-static
+	%endif
 %endif
 Provides:	cryptsetup = %{version}
 Obsoletes:	cryptsetup
@@ -141,12 +149,30 @@
 
 %if %{with initrd}
 %configure \
+%if %{with dietlibc}
+	CC="diet %{__cc} -Os %{rpmldflags}" \
+	ac_cv_lib_popt_poptConfigFileToString=yes \
+	ac_cv_lib_sepol_sepol_bool_set=no \
+	ac_cv_lib_selinux_is_selinux_enabled=no \
+%endif
 	--disable-shared-library \
 	--enable-static \
 	--enable-static-cryptsetup \
 	--disable-nls
-%{__make}
+
+%{__make} -C luks
+%{__make} -C lib
+
+%if %{with dietlibc}
+# we have to do it by hand cause libtool "know better" and forces
+# static libs from /usr/lib
+diet %{__cc} -Os -I./lib -static -o cryptsetup-initrd src/cryptsetup.c \
+	./lib/.libs/libcryptsetup.a -lpopt -lgcrypt -lgpg-error -ldevmapper -luuid -lcompat
+%else
+%{__make} -C src
 mv src/cryptsetup cryptsetup-initrd
+%endif
+
 %{__make} clean
 %endif
 
@@ -221,6 +247,12 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.37  2009/03/18 20:44:32  baggins
+- rel 9
+- added dietlibc bcond
+- build initrd package with dietlibc by default
+- disabled selinux on initrd dietlibc
+
 Revision 1.36  2009/02/26 15:20:23  baggins
 - rel 8
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/cryptsetup-luks.spec?r1=1.36&r2=1.37&f=u



More information about the pld-cvs-commit mailing list