| 1 |
#!/usr/bin/make -f |
| 2 |
# -*- makefile -*- |
| 3 |
|
| 4 |
# Use debhelper default for all targets (but some are overridden below). |
| 5 |
%: |
| 6 |
dh $@ --buildsystem=cmake |
| 7 |
|
| 8 |
# Enable all hardening options (since grfcodec potentially handles |
| 9 |
# untrusted data files). |
| 10 |
export DEB_BUILD_MAINT_OPTIONS=hardening=+all |
| 11 |
|
| 12 |
# Build release |
| 13 |
CMAKE_CONFIG_ARGUMENTS += -DCMAKE_BUILD_TYPE=RelWithDebInfo |
| 14 |
|
| 15 |
# Explicitly mark dependencies as required or disabled, so an issue with |
| 16 |
# build dependencies does not silently remove a feature or add a |
| 17 |
# dependency |
| 18 |
CMAKE_CONFIG_ARGUMENTS += -DCMAKE_REQUIRE_FIND_PACKAGE_Boost=TRUE |
| 19 |
CMAKE_CONFIG_ARGUMENTS += -DCMAKE_REQUIRE_FIND_PACKAGE_PNG=TRUE |
| 20 |
|
| 21 |
override_dh_auto_configure: |
| 22 |
dh_auto_configure -- $(CMAKE_CONFIG_ARGUMENTS) |
| 23 |
|
| 24 |
execute_after_dh_install-arch: |
| 25 |
# Prevent installing duplicate license file |
| 26 |
rm debian/grfcodec/usr/share/doc/grfcodec/COPYING |