#!/usr/bin/make -f # Uncomment this to turn on verbose mode. export DH_VERBOSE=1 # This has to be exported to make some magic below work. export DH_OPTIONS export DH_PYCENTRAL=nomove DEB_BUILD_GNU_TYPE = $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) clean: dh_testdir dh_testroot rm -f build-stamp configure-stamp extract-stamp install-stamp # Remove (possibly stale) pre-built Qt-generated moc files; they will # be rebuilt using the current Qt moc. Perhaps this should actually be # part of 'make distclean' and these files not be distributed: rm -f ./gr-qtgui/src/lib/*_moc.cc if [ -f Makefile ]; \ then\ $(MAKE) maintainer-clean; \ fi dh_clean update: dh_testdir -test -r /usr/share/misc/config.sub && \ cp -f /usr/share/misc/config.sub config.sub -test -r /usr/share/misc/config.guess && \ cp -f /usr/share/misc/config.guess config.guess configure: configure-stamp configure-stamp: dh_testdir ./bootstrap ./configure \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr \ --mandir=\$${prefix}/share/man \ --infodir=\$${prefix}/share/info \ --enable-shared \ --sysconfdir=/etc \ --enable-all-components \ --disable-gr-audio-osx \ --disable-gr-audio-windows \ --disable-gcell --disable-gr-gcell \ --disable-gr-comedi --disable-usrp2-firmware touch configure-stamp build: build-stamp build-stamp: configure-stamp $(MAKE) $(MAKE) check touch $@ extract: extract-stamp extract-stamp: build-stamp debian/gen-install-files.sh dh_testdir chmod +x debian/gen-install-files.sh dtools/bin/extract_install_filenames debian/gen-install-files.sh touch $@ install: install-stamp install-stamp: extract-stamp debian/control dh_testdir dh_testroot dh_clean -k dh_installdirs $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp : # make python scripts starting with '#!' executable for i in `find debian -mindepth 2 -type f ! -perm 755`; do \ if head -1 $$i | grep -q '^#!'; then \ chmod 755 $$i; \ echo "made executable: $$i"; \ fi; \ done : # Deposit rule to allow group 'usrp' access to USRP hardware install -m 0644 -D debian/libusrp0.udev \ debian/tmp/lib/udev/rules.d/40-usrp.rules : # Deposit rule to allow group 'usrp' access to USRP2 hardware install -m 0644 -D debian/libusrp2-0.limits \ debian/tmp/etc/security/limits.d/libusrp2-0.limits : # Install custom grc.conf install -m 0644 -D debian/grc.conf \ debian/tmp/etc/gnuradio/conf.d/grc.conf dh_install --sourcedir=debian/tmp touch $@ # Must not depend on anything. This is to be called by # binary-arch/binary-indep # in another 'make' thread. binary-common: dh_testdir dh_testroot dh_installchangelogs ChangeLog dh_installdocs dh_python2 dh_link dh_strip dh_compress dh_fixperms dh_makeshlibs dh_installdeb dh_shlibdeps dh_gencontrol dh_md5sums dh_builddeb # Build architecture independant packages using the common target. binary-indep: build install $(MAKE) -f debian/rules DH_OPTIONS=-i binary-common # Build architecture dependant packages using the common target. binary-arch: build install $(MAKE) -f debian/rules DH_OPTIONS=-s binary-common binary: binary-arch binary-indep .PHONY: build clean binary-indep binary-arch binary install configure