Debian Codegraph @

debian/rules

raw symbols SCIP
1 #! /usr/bin/make -f
2
3 # Enable hardening build flags
4 export DEB_BUILD_MAINT_OPTIONS=hardening=+all
5
6 include /usr/share/dpkg/pkg-info.mk
7
8 CFLAGS += $(CPPFLAGS)
9
10 ifneq (,$(findstring verbose,$(DEB_BUILD_OPTIONS)))
11 DH_VERBOSE=1
12 export DH_VERBOSE
13 endif
14
15 UPSTREAM_VERSION=$(shell echo $(DEB_VERSION_UPSTREAM) | sed -e 's/\+.*//')
16
17 BUILDDIR = $(CURDIR)/debian/build
18
19 CMAKE_OPTS = -DCMAKE_BUILD_TYPE=RelWithDebInfo \
20 -DCMAKE_C_FLAGS="-fstrict-aliasing $(CFLAGS)" \
21 -DCMAKE_INSTALL_PREFIX=/usr \
22 -DDCW_ROOT=/usr/share/gmt-dcw \
23 -DGSHHG_ROOT=/usr/share/gmt-gshhg \
24 -DNETCDF_ROOT=/usr \
25 -DFFTW3_ROOT=/usr \
26 -DGDAL_ROOT=/usr \
27 -DPCRE2_ROOT=/usr \
28 -DGMT_EXCLUDE_PCRE=on \
29 -DGMT_INSTALL_MODULE_LINKS=off \
30 -DGMT_INSTALL_TRADITIONAL_FOLDERNAMES=off \
31 -DWITH_GMT_UPDATE=off \
32 -DLICENSE_RESTRICTED=LGPL
33
34 %:
35 dh $@ --buildsystem cmake \
36 --sourcedirectory=$(CURDIR) \
37 --builddirectory=$(BUILDDIR)
38
39 override_dh_auto_configure:
40 dh_auto_configure -- $(CMAKE_OPTS)
41
42 execute_after_dh_auto_install:
43 # Remove executable bit from shell includes
44 chmod -x debian/tmp/usr/share/gmt/tools/gmt_aliases.csh
45
46 # Remove extra license files
47 rm -rf debian/tmp/usr/share/doc/gmt/copying/
48
49 # Fix bash-completion installation
50 mkdir -p debian/tmp/usr/share/bash-completion/completions
51 mv debian/tmp/usr/etc/bash_completion.d/gmt_completion.bash debian/tmp/usr/share/bash-completion/completions
52 rm -rf debian/tmp/usr/etc/bash_completion.d
53 rmdir debian/tmp/usr/etc/
54
55 # Strip RPATH
56 chrpath --delete \
57 debian/tmp/usr/lib/*/gmt/plugins/supplements.so \
58 debian/tmp/usr/lib/*/lib*.so.*.* \
59 debian/tmp/usr/bin/gmt
60
61 override_dh_compress:
62 # Don't compress the pdf files needed for the gmt-doc-pdf package, nor the examples
63 dh_compress -X.pdf -Xusr/share/doc/gmt-examples/examples/
64
65 override_dh_makeshlibs:
66 dh_makeshlibs -- -v$(UPSTREAM_VERSION)