]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commitdiff
debian: add make variable to prevent building udeb packages
authorTheodore Ts'o <tytso@mit.edu>
Thu, 6 Feb 2014 19:59:25 +0000 (14:59 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 6 Feb 2014 19:59:25 +0000 (14:59 -0500)
Setting SKIP_UDEBS=yes in rules.custom will prevent the debian/rules
makefile from building the udeb files for the debian installer.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
debian/control.in
debian/rules

index f4c915f55e72d454d40c161436070233aa4160e5..607eba3f7fd83bbf66c410b84d0be90cfd3179b9 100644 (file)
@@ -124,6 +124,7 @@ Description: runtime components for the Universally Unique ID library
  different CPU’s. It is used by libuuid as well as the uuidgen
  program.
 
+ifdef(`UDEV_PKGS',``
 Package: libuuid1-udeb
 XC-Package-Type: udeb
 Section: debian-installer
@@ -135,6 +136,7 @@ Description: stripped down universally unique id library, for debian-installer
  See RFC 4122 for more information.
  .
  This is a minimal package for debian-installer.
+'')dnl
 
 Package: uuid-dev
 Section: libdevel
@@ -159,6 +161,7 @@ Description: block device id library
  filesystems by hard-coded device names, but via a logical naming 
  system instead.
 
+ifdef(`UDEV_PKGS',``
 Package: libblkid1-udeb
 XC-Package-Type: udeb
 Section: debian-installer
@@ -173,6 +176,7 @@ Description: stripped down block device id library, for debian-installer
  system instead.
  .
  This is a minimal package for debian-installer.
+'')dnl
 
 Package: libblkid-dev
 Section: libdevel
@@ -189,6 +193,7 @@ Description: block device id library - headers and static libraries
  This package contains the development environment for the blkid library.
 '')dnl
 
+ifdef(`UDEV_PKGS',``
 Package: e2fsprogs-udeb
 XC-Package-Type: udeb
 Section: debian-installer
@@ -201,6 +206,7 @@ Description: stripped-down versions of e2fsprogs, for debian-installer
  .
  Don't attempt to install this package, it has no support for a couple of
  features you surely want.  Anyway it should refuse to install.
+'')dnl
 
 Package: e2fslibs
 Section: libs
index f5ee6a6e15e1fdbb83649169234480a55df4a389..2f722aa64ae6e2a2e120016f52b7fc91c2bc86db 100755 (executable)
@@ -139,6 +139,10 @@ BUILD_STATIC = build-static
 E2FSCK_STATIC = ${staticbuilddir}/e2fsck/e2fsck.static
 endif
 
+ifneq ($(SKIP_UDEB),)
+SKIP_BF ?= yes
+endif
+
 ifeq ($(SKIP_BF),yes)
 BUILD_BF =
 bfbuilddir     ?= ${stdbuilddir}
@@ -222,6 +226,13 @@ else
 M4_ARGS+=-UE2FSCK_STATIC
 endif
 
+ifeq ($(SKIP_UDEB),)
+INSTALL_UDEB = install-udeb
+M4_ARGS+=-DUDEB_PKGS
+else
+M4_ARGS+=-UUDEB_PKGS
+endif
+
 FILES_FIXUP= libcomerr2.files comerr-dev.files libss2.files ss-dev.files \
        libuuid1.files uuid-dev.files libblkid1.files libblkid-dev.files \
        e2fslibs.files e2fslibs-dev.files
@@ -469,7 +480,7 @@ binary-indep:
   # no arch-independant debs.
 
 binary-arch: DH_OPTIONS= -a
-binary-arch: install install-udeb
+binary-arch: install $(INSTALL_UDEB)
        dh_testdir
        dh_testroot
 
@@ -557,7 +568,9 @@ endif
 
        dh_fixperms
        dh_strip -pe2fsprogs --dbg-package=e2fsprogs-dbg
+ifneq ($(BUILD_E2FSCK_STATIC),no)
        dh_strip -pe2fsck-static --dbg-package=e2fsprogs-dbg
+endif
 ifneq ($(ismips),)
        dh_strip -pe2fslibs --dbg-package=e2fslibs-dbg -Xlib64ext2fs-nopic.a
 else
@@ -616,6 +629,7 @@ endif
        dh_compress
 
        dh_makeshlibs -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+ifeq ($(SKIP_UDEB),)
        dh_makeshlibs --add-udeb=e2fsprogs-udeb -plibcomerr${COMERR_SOVERSION} \
                -V 'libcomerr2 (>= 1.33-3)'
 ifneq ($(UTIL_LINUX_NG),yes)
@@ -623,14 +637,17 @@ ifneq ($(UTIL_LINUX_NG),yes)
        echo "udeb: libblkid 1 libblkid1-udeb" >> \
                debian/libblkid1/DEBIAN/shlibs
        echo "udeb: libuuid 1 libuuid1-udeb" >> debian/libuuid1/DEBIAN/shlibs
+endif
 endif
 
        dh_installdeb
        dh_shlibdeps -l${stdbuilddir}/lib
        dh_shlibdeps -pe2fsprogs -l${stdbuilddir}/lib \
                -u"-Ldebian/e2fsprogs.shlibs.local"
+ifeq ($(SKIP_UDEB),)
        dh_shlibdeps -pe2fsprogs-udeb -l${stdbuilddir}/lib \
                -u"-Ldebian/e2fsprogs-udeb.shlibs.local"
+endif
 
        dh_gencontrol -Ncomerr-dev -Nss-dev -Nuuid-dev \
                -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
@@ -642,24 +659,30 @@ ifneq ($(UTIL_LINUX_NG),yes)
        DH_OPTIONS= dh_gencontrol -puuid-dev \
          -u '-v${UUID_VERSION}-${MAIN_VERSION} -VmainBinary=${MAIN_VERSION}'
 endif
+ifeq ($(SKIP_UDEB),)
        dh_gencontrol   -pe2fsprogs-udeb -- -fdebian/files~
 ifneq ($(UTIL_LINUX_NG),yes)
        dh_gencontrol   -plibblkid1-udeb -- -fdebian/files~
        dh_gencontrol   -plibuuid1-udeb -- -fdebian/files~
 endif
+endif
 
+ifeq ($(SKIP_UDEB),)
        dpkg-distaddfile $(UDEB_NAME) debian-installer $(UDEB_PRIORITY)
 ifneq ($(UTIL_LINUX_NG),yes)
        dpkg-distaddfile $(BLKID_UDEB_NAME) debian-installer $(BLKID_UDEB_PRIORITY)
        dpkg-distaddfile $(UUID_UDEB_NAME) debian-installer $(UUID_UDEB_PRIORITY)
+endif
 endif
        dh_md5sums -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
        dh_builddeb -Ne2fsprogs-udeb -Nlibblkid1-udeb -Nlibuuid1-udeb
+ifeq ($(SKIP_UDEB),)
        dh_builddeb -pe2fsprogs-udeb --filename=$(UDEB_NAME)
 ifneq ($(UTIL_LINUX_NG),yes)
        dh_builddeb -plibblkid1-udeb --filename=$(BLKID_UDEB_NAME)
        dh_builddeb -plibuuid1-udeb --filename=$(UUID_UDEB_NAME)
 endif
+endif
 
 binary: binary-indep binary-arch