#!/usr/bin/make -f # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 BUILDDIR = obj-$(DEB_HOST_GNU_TYPE) %: dh $@ --buildsystem=cmake override_dh_auto_clean: dh_auto_clean -B $(BUILDDIR) dh_auto_clean -B $(BUILDDIR)-static rm -rf Makefile Linux_*.d/ testdata.d/ docs/zzipdoc/*.pyc find . -name "*.pyc" -exec rm -f {} \; override_dh_auto_configure: # dynamically linked dh_auto_configure -B $(BUILDDIR) -- -DCMAKE_BUILD_TYPE=Release # statically linked dh_auto_configure -B $(BUILDDIR)-static -- -DBUILD_SHARED_LIBS=OFF override_dh_auto_build: # dynamically linked dh_auto_build -B $(BUILDDIR) # statically linked dh_auto_build -B $(BUILDDIR)-static execute_before_dh_install: # put the static libs together with the rest of the stuff cp -v $(BUILDDIR)-static/zzipwrap/*.a debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/ cp -v $(BUILDDIR)-static/zzip/*.a debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/ override_dh_install: # need to refresh patch and do it in debian/tmp/usr/share/man/man3 #cd $(CURDIR)/debian/libzzip-dev/usr/share/man/ \ # && tar xf $(CURDIR)/docs/zziplib-manpages.tar #cd $(CURDIR)/debian/libzzip-dev/usr/share/man/man3/ \ # && patch -p1 < $(CURDIR)/debian/man3.patch dh_install # remove pkg-config-bad-directive sed -i "s/\-D_FORTIFY_SOURCE=2//" `find debian/ -name '*.pc'` get-orig-source: uscan --download-current-version --rename