Implement DEB_BUILD_OPTIONS' noopt flag.
authorAlessio Treglia <alessio@debian.org>
Sat, 11 Feb 2012 11:08:56 +0000 (12:08 +0100)
committerAlessio Treglia <alessio@debian.org>
Sat, 11 Feb 2012 11:08:56 +0000 (12:08 +0100)
debian/rules

index 2a60832a6658bdf2180458932f038c271726316e..2041173ccd451d13d235cef69c2b1ca4b991aa4e 100755 (executable)
@@ -5,6 +5,10 @@ export REPACK_SH=$(CURDIR)/debian/repack.sh
 DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
 export GPAC_SVN_REVISION ?= $(shell dpkg-parsechangelog | grep Version | sed 's/Version:.*+svn\([0-9]\+\).*/\1/')
 
+ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
+DEB_CONFIGURE_EXTRA_FLAGS = --disable-opt
+endif
+
 %:
        dh $@ --parallel
 
@@ -16,7 +20,8 @@ override_dh_auto_configure:
            --extra-cflags="-Wall -fPIC -DPIC -I/usr/include/mozjs -DXP_UNIX" \
            --enable-joystick \
            --enable-debug \
-           --disable-ssl
+           --disable-ssl \
+           $(DEB_EXTRA_CONFIGURE_FLAGS)
        echo "#define GPAC_SVN_REVISION \"\"" >include/gpac/version.h
 
 override_dh_auto_install: