| 1 |
#!/usr/bin/make -f |
| 2 |
|
| 3 |
export DEB_BUILD_MAINT_OPTIONS := hardening=+bindnow |
| 4 |
export DEB_CFLAGS_MAINT_APPEND := -Wall |
| 5 |
export DEB_CXXFLAGS_MAINT_APPEND := -Wall |
| 6 |
export DPKG_GENSYMBOLS_CHECK_LEVEL := 4 |
| 7 |
|
| 8 |
override_dh_auto_configure: |
| 9 |
dh_auto_configure --builddirectory=build --verbose -- \ |
| 10 |
--enable-ld-version-script --enable-static \ |
| 11 |
--enable-build-timestamp=$(SOURCE_DATE_EPOCH) |
| 12 |
|
| 13 |
%: |
| 14 |
dh $@ --builddirectory=build |
| 15 |
|
| 16 |
### "arch-independent" Windows builds: ### |
| 17 |
|
| 18 |
WIN_FLAGS=LDFLAGS="-Xlinker --no-insert-timestamp" CFLAGS="-g -Os -ffile-prefix-map=$(CURDIR)=." CPPFLAGS= |
| 19 |
|
| 20 |
override_dh_auto_build-indep: |
| 21 |
for cpu in i686 x86_64; do \ |
| 22 |
mkdir -p build-$$cpu-w64-mingw32 && \ |
| 23 |
cd build-$$cpu-w64-mingw32 && $(WIN_FLAGS) ../configure \ |
| 24 |
--prefix=/usr/$$cpu-w64-mingw32 \ |
| 25 |
--with-prefix=/usr/$$cpu-w64-mingw32 \ |
| 26 |
--with-libgpg-error-prefix=/usr/$$cpu-w64-mingw32 \ |
| 27 |
--enable-static \ |
| 28 |
--enable-build-timestamp=$(SOURCE_DATE_EPOCH) \ |
| 29 |
--host $$cpu-w64-mingw32 && \ |
| 30 |
$(WIN_FLAGS) $(MAKE) \ |
| 31 |
|| exit 1 ; \ |
| 32 |
cd .. ; \ |
| 33 |
done |
| 34 |
|
| 35 |
override_dh_auto_install-indep: |
| 36 |
for cpu in i686 x86_64; do \ |
| 37 |
cd build-$$cpu-w64-mingw32 && \ |
| 38 |
$(MAKE) install DESTDIR=$(shell pwd)/debian/tmp \ |
| 39 |
|| exit 1 ; \ |
| 40 |
cd .. ; \ |
| 41 |
done |
| 42 |
find debian/tmp -name lib*.la -type f -delete |