Просмотр исходного кода

debian/rules: introduce a maintainer build mode

Adding "maintainer-build" to DEB_BUILD_OPTS changes some compilation
settings to make the build more useful for maintainers. For instance
it enables the silent rules so that it's easier to spot the warnings.

It would be nice to also enable -Werror but that requires further
investigation since enabling this option results in ./configure not
working any more due to warnings generated by several of the
test programs compiled by ./configure itself.
Raphaël Hertzog лет назад: 15
Родитель
Сommit
a372b6a165
1 измененных файлов с 3 добавлено и 2 удалено
  1. 3 2
      debian/rules

+ 3 - 2
debian/rules

@@ -33,7 +33,9 @@ DEB_HOST_ARCH_OS  ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
 ifeq ($(DEB_HOST_ARCH_OS),linux)
 	confflags += --with-selinux
 endif
-
+ifeq (,$(filter maintainer-build,$(DEB_BUILD_OPTIONS)))
+	confflags += --disable-silent-rules
+endif
 
 # Create configure script if necessary, automake handles rebuilding it.
 configure:
@@ -48,7 +50,6 @@ build-tree/config.status: configure
 	install -d build-tree
 	cd build-tree && ../configure $(confflags) \
 		CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" \
-		--disable-silent-rules \
 		--prefix=/usr \
 		--mandir=\$${datadir}/man \
 		--infodir=\$${datadir}/info \