Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2
3 # DH_VERBOSE := 1
4
5 export DEB_BUILD_MAINT_OPTIONS=hardening=+all
6
7 # export QT_SELECT=qt5
8
9 include /usr/share/dpkg/default.mk
10
11 %:
12 dh $@ --sourcedirectory=warg
13
14 execute_before_dh_auto_configure:
15 cp -v warg/src/truth.xml warg/src/truth.xml.preserve
16
17 execute_after_dh_auto_clean:
18 test ! -e warg/src/truth.xml.preserve \
19 || mv -v warg/src/truth.xml.preserve warg/src/truth.xml
20
21 # GUI does not work - so there is no need to build it
22 # see https://lists.debian.org/debian-mentors/2017/12/msg00025.html
23 ifeq ($(QT_SELECT),qt5)
24 override_dh_auto_configure:
25 dh_auto_configure
26 cd gui && qmake
27
28 override_dh_auto_build:
29 dh_auto_build
30 cd gui && make
31 endif
32
33 override_dh_install:
34 dh_install
35 ifeq ($(QT_SELECT),qt5)
36 mkdir -p $(CURDIR)/debian/$(DEB_SOURCE)-gui/usr/bin
37 cp -a gui/gui $(CURDIR)/debian/$(DEB_SOURCE)-gui/usr/bin/$(DEB_SOURCE)-gui
38 endif
39 rename 's/\.pl//' debian/$(DEB_SOURCE)/usr/bin/*.pl