1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
|
#!/usr/bin/make -f
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
CC = gcc
DESTDIR=$(CURDIR)/debian/tmp
PKG_LIB = debian/libbg2
PKG_DEV = debian/libbg-dev
%:
dh $@
override_dh_dwz:
: Skipping dwz, compression not beneficial on bglibs binaries
override_dh_auto_configure:
echo $(CC) $(CFLAGS) $(CPPFLAGS) > conf-cc
echo $(CC) $(LDFLAGS) > conf-ld
echo $(DESTDIR)/usr/share/man > conf-man
echo $(DESTDIR)/usr/bin > conf-bin
echo $(CURDIR)/$(PKG_DEV)/usr/include > conf-include
echo $(CURDIR)/$(PKG_LIB)/usr/lib > conf-lib
override_dh_auto_build:
dh_auto_build -- libraries man programs
doxygen config.dxy
override_dh_auto_test:
dh_auto_test -- selftests
override_dh_auto_install:
$(MAKE) install
rm $(PKG_LIB)/usr/lib/*.la
# Static linking is part of development suite
mkdir $(PKG_DEV)/usr/lib
mv $(PKG_LIB)/usr/lib/*.a $(PKG_DEV)/usr/lib
mv $(PKG_LIB)/usr/lib/libbg.so $(PKG_DEV)/usr/lib
override_dh_gencontrol:
dh_gencontrol -- -Vmisc:Built-Using="$(shell dpkg-query -f '$${source:Package} (= $${source:Version})' -W libc-dev-bin)"
|