Re: [PATCH] blkid: add --disable-libblkid (v2)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2009-04-16 at 12:22 +0200, Karel Zak wrote:

> On Tue, Mar 24, 2009 at 12:11:47PM +0000, Scott James Remnant wrote:
> > Karel Zak wrote:
> > 
> > > I found some bugs in my previous patches. Please, use the patch
> > > below. This patch includes all necessary changes. Sorry.
> > > 
> > When putting together an Ubuntu package with this patch, I found that it
> > ends up putting the pkg-config output into the make dependency variables
> > and thus fails because it can't make the "-L/lib" target.
> > 
> > The attached patch fixes that, and includes your previous patch.
> 
>  Ted, ping ping ping... :-) Please, we need your feedback.
> 
If it's any help, here's a complete difference including changes to the
debian directory to remove the blkid packages - this includes the v3
patch I sent to the ext4 list.

Scott
-- 
Scott James Remnant
scott@xxxxxxxxxx
diff -u e2fsprogs-1.41.4/debian/rules e2fsprogs-1.41.4/debian/rules
--- e2fsprogs-1.41.4/debian/rules
+++ e2fsprogs-1.41.4/debian/rules
@@ -30,8 +30,9 @@
 SS_SOVERSION = $(shell grep ELF_SO_VERSION lib/ss/Makefile.in | cut '-d ' -f3)
 UUID_VERSION = $(shell grep ELF_VERSION lib/uuid/Makefile.in | cut '-d ' -f3)
 UUID_SOVERSION = $(shell grep ELF_SO_VERSION lib/uuid/Makefile.in | cut '-d ' -f3)
-BLKID_VERSION = $(shell grep ELF_VERSION lib/blkid/Makefile.in | cut '-d ' -f3)
-BLKID_SOVERSION = $(shell grep ELF_SO_VERSION lib/blkid/Makefile.in | cut '-d ' -f3)
+# blkid moved to util-linux-ng
+#BLKID_VERSION = $(shell grep ELF_VERSION lib/blkid/Makefile.in | cut '-d ' -f3)
+#BLKID_SOVERSION = $(shell grep ELF_SO_VERSION lib/blkid/Makefile.in | cut '-d ' -f3)
 EXT2FS_SOVERSION = $(shell grep ELF_SO_VERSION lib/ext2fs/Makefile.in | cut '-d ' -f3)
 E2P_SOVERSION = $(shell grep ELF_SO_VERSION lib/e2p/Makefile.in | cut '-d ' -f3)
 
@@ -41,7 +42,8 @@
 debdir=${topdir}/debian
 tmpdir=${debdir}/tmp
 udebdir=${debdir}/e2fsprogs-udeb
-blkidudebdir=${debdir}/libblkid1-udeb
+# blkid moved to util-linux-ng
+#blkidudebdir=${debdir}/libblkid1-udeb
 uuidudebdir=${debdir}/libuuid1-udeb
 libcomerrdir=${debdir}/libcomerr${COMERR_SOVERSION}
 comerrdevdir=${debdir}/comerr-dev
@@ -49,9 +51,10 @@
 libssdir=${debdir}/libss${SS_SOVERSION}
 ssdevdir=${debdir}/ss-dev
 libssdbgdir=${debdir}/libss2-dbg
-libblkiddir=${debdir}/libblkid${BLKID_SOVERSION}
-libblkiddevdir=${debdir}/libblkid-dev
-libblkiddbgdir=${debdir}/libblkid1-dbg
+# blkid moved to util-linux-ng
+#libblkiddir=${debdir}/libblkid${BLKID_SOVERSION}
+#libblkiddevdir=${debdir}/libblkid-dev
+#libblkiddbgdir=${debdir}/libblkid1-dbg
 libuuiddir=${debdir}/libuuid${UUID_SOVERSION}
 uuiddevdir=${debdir}/uuid-dev
 libuuiddbgdir=${debdir}/libuuid1-dbg
@@ -75,8 +78,9 @@
 UDEB_NAME = $(package)-udeb_$(MAIN_VERSION)_$(DEB_HOST_ARCH).udeb
 UDEB_PRIORITY = $(shell grep '^Package: e2fsprogs-udeb' debian/control -A 10 | grep ^Priority: | cut -d ' ' -f 2)
 
-BLKID_UDEB_NAME = libblkid1-udeb_$(MAIN_VERSION)_$(DEB_HOST_ARCH).udeb
-BLKID_UDEB_PRIORITY = $(shell grep '^Package: libblkid1-udeb' debian/control -A 10 | grep ^Priority: | cut -d ' ' -f 2)
+# blkid moved to util-linux-ng
+#BLKID_UDEB_NAME = libblkid1-udeb_$(MAIN_VERSION)_$(DEB_HOST_ARCH).udeb
+#BLKID_UDEB_PRIORITY = $(shell grep '^Package: libblkid1-udeb' debian/control -A 10 | grep ^Priority: | cut -d ' ' -f 2)
 
 UUID_UDEB_NAME = libuuid1-udeb_$(MAIN_VERSION)_$(DEB_HOST_ARCH).udeb
 UUID_UDEB_PRIORITY = $(shell grep '^Package: libuuid1-udeb' debian/control -A 10 | grep ^Priority: | cut -d ' ' -f 2)
@@ -117,7 +121,7 @@
 BF_CCOPTS = -Os -fomit-frame-pointer
 
 COMMON_CONF_FLAGS =  \
-                --enable-elf-shlibs --infodir=/usr/share/info --enable-fsck
+                --enable-elf-shlibs --infodir=/usr/share/info --disable-libblkid --disable-fsck
 
 STD_CONF_FLAGS = --with-ccopts="${CCOPTS}" --enable-compression
 
@@ -327,8 +331,9 @@
 		ln -s e2fsck fsck.ext3 ; ln -s mke2fs mkfs.ext2 ; \
 		ln -s mke2fs mkfs.ext3 ; ln -s mke2fs mkfs.ext4)
 
-	mkdir -p ${blkidudebdir}/lib
-	mv ${udebdir}/lib/libblkid.* ${blkidudebdir}/lib
+# blkid moved to util-linux-ng
+#	mkdir -p ${blkidudebdir}/lib
+#	mv ${udebdir}/lib/libblkid.* ${blkidudebdir}/lib
 
 	mkdir -p ${uuidudebdir}/lib
 	mv ${udebdir}/lib/libuuid.* ${uuidudebdir}/lib
@@ -360,9 +365,10 @@
 
   # symlinks to prepare dh_installdocs run
 
-	mkdir -p ${debdir}/libblkid${BLKID_SOVERSION}/usr/share/doc/libblkid${BLKID_SOVERSION}
-	mkdir -p ${debdir}/libblkid-dev/usr/share/doc
-	ln -sf libblkid${BLKID_SOVERSION} ${debdir}/libblkid-dev/usr/share/doc/libblkid-dev
+# blkid moved to util-linux-ng
+#	mkdir -p ${debdir}/libblkid${BLKID_SOVERSION}/usr/share/doc/libblkid${BLKID_SOVERSION}
+#	mkdir -p ${debdir}/libblkid-dev/usr/share/doc
+#	ln -sf libblkid${BLKID_SOVERSION} ${debdir}/libblkid-dev/usr/share/doc/libblkid-dev
 
 	mkdir -p ${debdir}/libss${SS_SOVERSION}/usr/share/doc/libss${SS_SOVERSION}
 	mkdir -p ${debdir}/ss-dev/usr/share/doc
@@ -380,10 +386,13 @@
 	mkdir -p ${debdir}/e2fslibs-dev/usr/share/doc
 	ln -sf e2fslibs ${debdir}/e2fslibs-dev/usr/share/doc/e2fslibs-dev
 
-	$(INSTALL) -p -m 0644 debian/libblkid.copyright \
+# blkid moved to util-linux-ng
+#	$(INSTALL) -p -m 0644 debian/libblkid.copyright \
 		${debdir}/libblkid${BLKID_SOVERSION}/usr/share/doc/libblkid${BLKID_SOVERSION}/copyright
 
-	dh_installdocs -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+# blkid moved to util-linux-ng
+#	dh_installdocs -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+	dh_installdocs -Ne2fsprogs-udeb -Nlibuuid1-udeb
 
   # HTML docs
 	$(INSTALL) -d ${debdir}/e2fslibs-dev/usr/share/doc/e2fslibs/html-info/
@@ -417,12 +426,19 @@
 	dh_installinfo -pcomerr-dev ${stdbuilddir}/lib/et/com_err.info
 	dh_installinfo -pe2fslibs-dev ${stdbuilddir}/doc/libext2fs.info
 
+# blkid moved to util-linux-ng
+#	DH_OPTIONS= dh_installchangelogs -pe2fsprogs \
+#		-plibblkid${BLKID_SOVERSION} -plibcomerr${COMERR_SOVERSION} \
+#		-plibss${SS_SOVERSION} -plibuuid${UUID_SOVERSION} \
+#		-pe2fslibs -puuid-dev -puuid-runtime -pe2fsck-static \
+#		-pe2fsprogs-dbg -puuid-runtime-dbg -pe2fslibs-dbg \
+#		-plibcomerr2-dbg -plibss2-dbg -plibblkid1-dbg -plibuuid1-dbg
 	DH_OPTIONS= dh_installchangelogs -pe2fsprogs \
-		-plibblkid${BLKID_SOVERSION} -plibcomerr${COMERR_SOVERSION} \
+		-plibcomerr${COMERR_SOVERSION} \
 		-plibss${SS_SOVERSION} -plibuuid${UUID_SOVERSION} \
 		-pe2fslibs -puuid-dev -puuid-runtime -pe2fsck-static \
 		-pe2fsprogs-dbg -puuid-runtime-dbg -pe2fslibs-dbg \
-		-plibcomerr2-dbg -plibss2-dbg -plibblkid1-dbg -plibuuid1-dbg
+		-plibcomerr2-dbg -plibss2-dbg -plibuuid1-dbg
 
 	dh_fixperms
 ifneq ($(ismips),)
@@ -433,7 +449,8 @@
 
 	# debug package stuff
 	rm -rf ${udebdir}/usr
-	rm -rf ${blkidudebdir}/usr
+# blkid moved to util-linux-ng
+#	rm -rf ${blkidudebdir}/usr
 	rm -rf ${uuidudebdir}/usr
 
 	mkdir -p ${debugdir}/usr/lib
@@ -463,13 +480,16 @@
 	mv ${libuuiddir}/usr/lib/debug ${libuuiddbgdir}/usr/lib
 	rmdir ${libuuiddir}/usr/lib
 
-	mkdir -p ${libblkiddbgdir}/usr/lib
-	mv ${libblkiddir}/usr/lib/debug ${libblkiddbgdir}/usr/lib
-	rmdir ${libblkiddir}/usr/lib
+# blkid moved to util-linux-ng
+#	mkdir -p ${libblkiddbgdir}/usr/lib
+#	mv ${libblkiddir}/usr/lib/debug ${libblkiddbgdir}/usr/lib
+#	rmdir ${libblkiddir}/usr/lib
 
 	# dpkg symbol handling
 ifneq (,$(findstring update-symbols,$(DEB_BUILD_OPTIONS)))
-	for i in e2fslibs libcomerr2 libss2 libblkid1 libuuid1; \
+# blkid moved to util-linux-ng
+#	for i in e2fslibs libcomerr2 libss2 libblkid1 libuuid1;
+	for i in e2fslibs libcomerr2 libss2 libuuid1; \
 	do \
 		echo "Generating symbols for $$i..."; \
 		dpkg-gensymbols -p$$i -Pdebian/$$i > debian/$$i.tmp-patch; \
@@ -494,20 +514,24 @@
 	$(INSTALL) -p -m 0644 debian/libss2.copyright \
 		${libssdbgdir}/usr/share/doc/libss2-dbg/copyright
 
-	$(INSTALL) -p -m 0644 debian/libblkid.copyright \
-		${libblkiddbgdir}/usr/share/doc/libblkid1-dbg/copyright
+# blkid moved to util-linux-ng
+#	$(INSTALL) -p -m 0644 debian/libblkid.copyright \
+#		${libblkiddbgdir}/usr/share/doc/libblkid1-dbg/copyright
 
 	$(INSTALL) -p -m 0644 debian/libuuid1.copyright \
 		${libuuiddbgdir}/usr/share/doc/libuuid1-dbg/copyright
 
 	dh_compress
 
-	dh_makeshlibs -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+# blkid moved to util-linux-ng
+#	dh_makeshlibs -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+	dh_makeshlibs -Ne2fsprogs-udeb -Nlibuuid1-udeb
 	dh_makeshlibs -plibcomerr${COMERR_SOVERSION} \
 		-V 'libcomerr2 (>= 1.33-3)'
-	dh_makeshlibs -plibblkid${BLKID_SOVERSION} -V 'libblkid1 (>= 1.39-1)'
-	echo "udeb: libblkid 1 libblkid1-udeb" >> \
-		debian/libblkid1/DEBIAN/shlibs
+# blkid moved to util-linux-ng
+#	dh_makeshlibs -plibblkid${BLKID_SOVERSION} -V 'libblkid1 (>= 1.39-1)'
+#	echo "udeb: libblkid 1 libblkid1-udeb" >> \
+#		debian/libblkid1/DEBIAN/shlibs
 	echo "udeb: libuuid 1 libuuid1-udeb" >> debian/libuuid1/DEBIAN/shlibs
 
 	dh_installdeb
@@ -517,8 +541,11 @@
 	dh_shlibdeps -pe2fsprogs-udeb -l${stdbuilddir}/lib \
 		-u"-Ldebian/e2fsprogs-udeb.shlibs.local"
 
+# blkid moved to util-linux-ng
+#	dh_gencontrol -Ncomerr-dev -Nss-dev -Nuuid-dev \
+#		-Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
 	dh_gencontrol -Ncomerr-dev -Nss-dev -Nuuid-dev \
-		-Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+		-Ne2fsprogs-udeb -Nlibuuid1-udeb
 	DH_OPTIONS= dh_gencontrol -pcomerr-dev \
 	  -u '-v${COMERR_VERSION}-${MAIN_VERSION} -VmainBinary=${MAIN_VERSION}'
 	DH_OPTIONS= dh_gencontrol -pss-dev \
@@ -526,16 +553,22 @@
 	DH_OPTIONS= dh_gencontrol -puuid-dev \
 	  -u '-v${UUID_VERSION}-${MAIN_VERSION} -VmainBinary=${MAIN_VERSION}'
 	dh_gencontrol	-pe2fsprogs-udeb -- -fdebian/files~
-	dh_gencontrol	-plibblkid1-udeb -- -fdebian/files~
+# blkid moved to util-linux-ng
+#	dh_gencontrol	-plibblkid1-udeb -- -fdebian/files~
 	dh_gencontrol	-plibuuid1-udeb -- -fdebian/files~
 
 	dpkg-distaddfile $(UDEB_NAME) debian-installer $(UDEB_PRIORITY)
-	dpkg-distaddfile $(BLKID_UDEB_NAME) debian-installer $(BLKID_UDEB_PRIORITY)
+# blkid moved to util-linux-ng
+#	dpkg-distaddfile $(BLKID_UDEB_NAME) debian-installer $(BLKID_UDEB_PRIORITY)
 	dpkg-distaddfile $(UUID_UDEB_NAME) debian-installer $(UUID_UDEB_PRIORITY)
-	dh_md5sums -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
-	dh_builddeb -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+# blkid moved to util-linux-ng
+#	dh_md5sums -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+#	dh_builddeb -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+	dh_md5sums -Ne2fsprogs-udeb  -Nlibuuid1-udeb
+	dh_builddeb -Ne2fsprogs-udeb -Nlibuuid1-udeb
 	dh_builddeb -pe2fsprogs-udeb --filename=$(UDEB_NAME)
-	dh_builddeb -plibblkid1-udeb --filename=$(BLKID_UDEB_NAME)
+# blkid moved to util-linux-ng
+#	dh_builddeb -plibblkid1-udeb --filename=$(BLKID_UDEB_NAME)
 	dh_builddeb -plibuuid1-udeb --filename=$(UUID_UDEB_NAME)
 
 binary: binary-indep binary-arch
diff -u e2fsprogs-1.41.4/debian/control e2fsprogs-1.41.4/debian/control
--- e2fsprogs-1.41.4/debian/control
+++ e2fsprogs-1.41.4/debian/control
@@ -3,7 +3,7 @@
 Priority: required
 Maintainer: Ubuntu Core Developers <ubuntu-devel-discuss@xxxxxxxxxxxxxxxx>
 XSBC-Original-Maintainer: Theodore Y. Ts'o <tytso@xxxxxxx>
-Build-Depends: texi2html (>= 1.76), gettext, texinfo, dc, pkg-config, debhelper (>= 4.2)
+Build-Depends: texi2html (>= 1.76), gettext, texinfo, dc, pkg-config, debhelper (>= 4.2), libblkid-dev (>= 2.15~rc1)
 Standards-Version: 3.8.0.0
 
 Package: e2fsck-static
@@ -128,47 +128,6 @@
  .
  This package contains the development environment for the uuid library.
 
-Package: libblkid1
-Section: libs
-Priority: required
-Depends: ${shlibs:Depends}
-Architecture: any
-Description: block device id library
- The blkid library which allows system programs like fsck and 
- mount to quickly and easily find block devices by filesystem UUID and 
- LABEL.  This allows system administrators to avoid specifying 
- filesystems by hard-coded device names, but via a logical naming 
- system instead.
-
-Package: libblkid1-udeb
-XC-Package-Type: udeb
-Section: debian-installer
-Priority: optional
-Depends: ${shlibs:Depends}
-Architecture: any
-Description: block device id library
- The blkid library which allows system programs like fsck and 
- mount to quickly and easily find block devices by filesystem UUID and 
- LABEL.  This allows system administrators to avoid specifiying 
- filesystems by hard-coded device names, but via a logical naming 
- system instead.
- .
- This is a minimal package for debian-installer.
-
-Package: libblkid-dev
-Section: libdevel
-Priority: extra
-Depends: libc6-dev | libc-dev, libblkid1 (= ${binary:Version})
-Architecture: any
-Description: block device id library - headers and static libraries
- The blkid library which allows system programs like fsck and 
- mount to quickly and easily find block devices by filesystem UUID and 
- LABEL.  This allows system administrators to avoid specifiying 
- filesystems by hard-coded device names, but via a logical naming 
- system instead.
- .
- This package contains the development environment for the blkid library.
-
 Package: e2fsprogs-udeb
 XC-Package-Type: udeb
 Section: debian-installer
@@ -282,16 +241,6 @@
  ss library, contained in the libss2 package.  The debug information
  is used for execution tracing and core dump analysis.
 
-Package: libblkid1-dbg
-Section: libdevel
-Priority: extra
-Depends: libblkid1 (= ${binary:Version})
-Architecture: any
-Description: Debugging information for libblkid1
- This package includes the debug information useful for debugging the
- blkid library, contained in the libblkid1 package.  The debug
- information is used for execution tracing and core dump analysis.
-
 Package: libuuid1-dbg
 Section: libdevel
 Priority: extra
only in patch2:
unchanged:
--- e2fsprogs-1.41.4.orig/Makefile.in
+++ e2fsprogs-1.41.4/Makefile.in
@@ -11,8 +11,9 @@
 
 @RESIZER_CMT@RESIZE_DIR= resize
 @DEBUGFS_CMT@DEBUGFS_DIR= debugfs
+@BLKID_CMT@BLKID_LIB_SUBDIR= lib/blkid
 
-LIB_SUBDIRS=lib/et lib/ss lib/e2p lib/uuid lib/ext2fs lib/blkid intl
+LIB_SUBDIRS=lib/et lib/ss lib/e2p lib/uuid lib/ext2fs $(BLKID_LIB_SUBDIR) intl
 PROG_SUBDIRS=e2fsck $(DEBUGFS_DIR) misc $(RESIZE_DIR) tests/progs po
 SUBDIRS=util $(LIB_SUBDIRS) $(PROG_SUBDIRS) tests
 
only in patch2:
unchanged:
--- e2fsprogs-1.41.4.orig/configure.in
+++ e2fsprogs-1.41.4/configure.in
@@ -276,6 +276,39 @@
 AC_SUBST(BSDLIB_CMT)
 AC_SUBST_FILE(MAKEFILE_BSDLIB)
 dnl
+dnl handle --disable-libblkid
+dnl
+PKG_PROG_PKG_CONFIG
+BLKID_LIBS=
+STATIC_BLKID_LIBS=
+BLKID_CMT=
+AC_ARG_ENABLE([libblkid],
+[  --disable-libblkid	  do not build private blkid library],
+if test "$enableval" = "no"
+then
+	if test -z "$PKG_CONFIG"; then
+		AC_MSG_ERROR([pkg-config not installed; please install it.])
+	fi
+
+	AC_CHECK_LIB(blkid, blkid_get_cache,
+		[BLKID_LIBS=`$PKG_CONFIG --libs blkid`;
+		 STATIC_BLKID_LIBS=`$PKG_CONFIG --static --libs blkid`],
+		[AC_MSG_ERROR([external blkid library not found])],
+		[$BLKID_LIBS])
+	BLKID_CMT=#
+	AC_MSG_RESULT([Disabling private blkid library])
+else
+	AC_DEFINE(CONFIG_BUILD_FINDFS)
+	AC_MSG_RESULT([Enabling private blkid library])
+fi
+,
+AC_DEFINE(CONFIG_BUILD_FINDFS)
+AC_MSG_RESULT([Enabling private blkid library by default])
+)
+AC_SUBST(BLKID_CMT)
+AC_SUBST(BLKID_LIBS)
+AC_SUBST(STATIC_BLKID_LIBS)
+dnl
 dnl handle --enable-profile
 dnl
 AC_ARG_ENABLE([profile],
only in patch2:
unchanged:
--- e2fsprogs-1.41.4.orig/MCONFIG.in
+++ e2fsprogs-1.41.4/MCONFIG.in
@@ -69,36 +69,52 @@
 #
 # Library definitions
 #
+@BLKID_CMT@PRIVATE_LIBBLKID = yes
+
+# public libblkid options
+BLKID_LIBS = @BLKID_LIBS@
+STATIC_BLKID_LIBS = @STATIC_BLKID_LIBS@
+
+ifdef PRIVATE_LIBBLKID
+LIBBLKID = $(LIB)/libblkid@LIB_EXT@ @PRIVATE_LIBS_CMT@ $(LIBUUID)
+DEPLIBBLKID = $(LIB)/libblkid@LIB_EXT@ @PRIVATE_LIBS_CMT@ $(LIBUUID)
+STATIC_LIBBLKID = $(LIB)/libblkid@STATIC_LIB_EXT@ $(STATIC_LIBUUID)
+DEPSTATIC_LIBBLKID = $(LIB)/libblkid@STATIC_LIB_EXT@
+PROFILED_LIBBLKID = $(LIB)/libblkid@PROFILED_LIB_EXT@ $(PROFILED_LIBUUID)
+DEPPROFILED_LIBBLKID = $(LIB)/libblkid@PROFILED_LIB_EXT@
+else
+LIBBLKID = $(BLKID_LIBS) @PRIVATE_LIBS_CMT@ $(LIBUUID)
+DEPLIBBLKID = @PRIVATE_LIBS_CMT@ $(LIBUUID)
+STATIC_LIBBLKID = $(STATIC_BLKID_LIBS) $(STATIC_LIBUUID)
+DEPSTATIC_LIBBLKID = 
+PROFILED_LIBBLKID = $(BLKID_LIBS) $(PROFILED_LIBUUID)
+DEPPROFILED_LIBBLKID =
+endif
+
 LIB = $(top_builddir)/lib
 LIBSS = $(LIB)/libss@LIB_EXT@ @PRIVATE_LIBS_CMT@ @DLOPEN_LIB@
 LIBCOM_ERR = $(LIB)/libcom_err@LIB_EXT@ @PRIVATE_LIBS_CMT@ @SEM_INIT_LIB@
 LIBE2P = $(LIB)/libe2p@LIB_EXT@
 LIBEXT2FS = $(LIB)/libext2fs@LIB_EXT@
 LIBUUID = $(LIB)/libuuid@LIB_EXT@ @SOCKET_LIB@
-LIBBLKID = $(LIB)/libblkid@LIB_EXT@ @PRIVATE_LIBS_CMT@ $(LIBUUID)
 LIBINTL = @LIBINTL@
 DEPLIBSS = $(LIB)/libss@LIB_EXT@
 DEPLIBUUID = $(LIB)/libuuid@LIB_EXT@
-DEPLIBBLKID = $(LIB)/libblkid@LIB_EXT@ @PRIVATE_LIBS_CMT@ $(LIBUUID)
 
 STATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@ @DLOPEN_LIB@
 STATIC_LIBCOM_ERR = $(LIB)/libcom_err@STATIC_LIB_EXT@ @SEM_INIT_LIB@
 STATIC_LIBE2P = $(LIB)/libe2p@STATIC_LIB_EXT@
 STATIC_LIBEXT2FS = $(LIB)/libext2fs@STATIC_LIB_EXT@
 STATIC_LIBUUID = $(LIB)/libuuid@STATIC_LIB_EXT@ @SOCKET_LIB@ 
-STATIC_LIBBLKID = $(LIB)/libblkid@STATIC_LIB_EXT@ $(STATIC_LIBUUID)
 DEPSTATIC_LIBSS = $(LIB)/libss@STATIC_LIB_EXT@
 DEPSTATIC_LIBUUID = $(LIB)/libuuid@STATIC_LIB_EXT@
-DEPSTATIC_LIBBLKID = $(LIB)/libblkid@STATIC_LIB_EXT@
 
 PROFILED_LIBSS = $(LIB)/libss@PROFILED_LIB_EXT@ @DLOPEN_LIB@
 PROFILED_LIBCOM_ERR = $(LIB)/libcom_err@PROFILED_LIB_EXT@ @SEM_INIT_LIB@
 PROFILED_LIBE2P = $(LIB)/libe2p@PROFILED_LIB_EXT@
 PROFILED_LIBEXT2FS = $(LIB)/libext2fs@PROFILED_LIB_EXT@
 PROFILED_LIBUUID = $(LIB)/libuuid@PROFILED_LIB_EXT@ @SOCKET_LIB@ 
-PROFILED_LIBBLKID = $(LIB)/libblkid@PROFILED_LIB_EXT@ $(PROFILED_LIBUUID)
 DEPPROFILED_LIBUUID = $(LIB)/libuuid@PROFILED_LIB_EXT@
-DEPPROFILED_LIBBLKID = $(LIB)/libblkid@PROFILED_LIB_EXT@
 
 # An include directive pointing to a directory holding enough linux-like
 # include files to satisfy some programs here
only in patch2:
unchanged:
--- e2fsprogs-1.41.4.orig/misc/Makefile.in
+++ e2fsprogs-1.41.4/misc/Makefile.in
@@ -17,11 +17,18 @@
 @UUIDD_CMT@UUIDD_PROG= uuidd
 @UUIDD_CMT@UUIDD_MAN= uuidd.8
 
-SPROGS=		mke2fs badblocks tune2fs dumpe2fs blkid logsave \
+@BLKID_CMT@BLKID_PROG= blkid
+@BLKID_CMT@BLKID_MAN= blkid.8
+@BLKID_CMT@BLKID_PROFILED= blkid.profiled
+
+@BLKID_CMT@FINDFS_LINK= findfs
+@BLKID_CMT@FINDFS_MAN= findfs.8
+
+SPROGS=		mke2fs badblocks tune2fs dumpe2fs $(BLKID_PROG) logsave \
 			$(E2IMAGE_PROG) @FSCK_PROG@ e2undo
 USPROGS=	mklost+found filefrag $(UUIDD_PROG)
 SMANPAGES=	tune2fs.8 mklost+found.8 mke2fs.8 dumpe2fs.8 badblocks.8 \
-			e2label.8 findfs.8 blkid.8 $(E2IMAGE_MAN) \
+			e2label.8 $(FINDFS_MAN) $(BLKID_MAN) $(E2IMAGE_MAN) \
 			logsave.8 filefrag.8 e2undo.8 $(UUIDD_MAN) @FSCK_MAN@
 FMANPAGES=	mke2fs.conf.5
 
@@ -94,7 +101,7 @@
 all:: profiled $(SPROGS) $(UPROGS) $(USPROGS) $(SMANPAGES) $(UMANPAGES) \
 	$(FMANPAGES) $(LPROGS)
 
-@PROFILE_CMT@all:: tune2fs.profiled blkid.profiled e2image.profiled \
+@PROFILE_CMT@all:: tune2fs.profiled $(BLKID_PROFILED) e2image.profiled \
 	e2undo.profiled mke2fs.profiled dumpe2fs.profiled fsck.profiled \
 	logsave.profiled filefrag.profiled uuidgen.profiled uuidd.profiled \
 	e2image.profiled
@@ -397,9 +404,11 @@
 	@echo "	LINK $(root_sbindir)/e2label"
 	@$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \
 		$(DESTDIR)$(root_sbindir)/e2label
-	@echo "	LINK $(root_sbindir)/findfs"
-	@$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \
-		$(DESTDIR)$(root_sbindir)/findfs
+	@if test -n "$(FINDFS_LINK)"; then \
+		echo "	LINK $(root_sbindir)/findfs"; \
+		$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \
+			$(DESTDIR)$(root_sbindir)/findfs; \
+	fi
 	@for i in $(UPROGS); do \
 		echo "	INSTALL $(bindir)/$$i"; \
 		$(INSTALL_PROGRAM) $$i $(DESTDIR)$(bindir)/$$i; \
@@ -509,7 +518,7 @@
 	for i in $(UMANPAGES); do \
 		$(RM) -f $(DESTDIR)$(man1dir)/$$i; \
 	done
-	for i in findfs e2label ; do \
+	for i in $(FINDFS_LINK) e2label ; do \
 		$(RM) -f $(DESTDIR)$(root_sbindir)/$$i; \
 	done
 	for i in $(FMANPAGES); do \
only in patch2:
unchanged:
--- e2fsprogs-1.41.4.orig/misc/tune2fs.c
+++ e2fsprogs-1.41.4/misc/tune2fs.c
@@ -95,7 +95,9 @@
 
 static const char *please_fsck = N_("Please run e2fsck on the filesystem.\n");
 
+#ifdef CONFIG_BUILD_FINDFS
 void do_findfs(int argc, char **argv);
+#endif
 
 static void usage(void)
 {
@@ -836,6 +838,7 @@
 	}
 }
 
+#ifdef CONFIG_BUILD_FINDFS
 void do_findfs(int argc, char **argv)
 {
 	char	*dev;
@@ -854,6 +857,7 @@
 	puts(dev);
 	exit(0);
 }
+#endif
 
 static void parse_extended_opts(ext2_filsys fs, const char *opts)
 {
@@ -1492,8 +1496,10 @@
 		program_name = *argv;
 	add_error_table(&et_ext2_error_table);
 
+#ifdef CONFIG_BUILD_FINDFS
 	if (strcmp(get_progname(argv[0]), "findfs") == 0)
 		do_findfs(argc, argv);
+#endif
 	if (strcmp(get_progname(argv[0]), "e2label") == 0)
 		parse_e2label_options(argc, argv);
 	else

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


[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux