File: rules

package info (click to toggle)
pstoedit 3.70-3
  • links: PTS
  • area: main
  • in suites: stretch
  • size: 6,428 kB
  • ctags: 4,522
  • sloc: cpp: 28,281; sh: 10,420; perl: 4,062; ansic: 968; java: 860; makefile: 451
file content (45 lines) | stat: -rwxr-xr-x 1,232 bytes parent folder | download
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
40
41
42
43
44
45
#!/usr/bin/make -f

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

include /usr/share/dpkg/architecture.mk

ifeq ($(DEB_BUILD_ARCH_OS),hurd)
HURD_LIBPTHREAD += -lpthread
endif

%:
	dh $@ --parallel --with autoreconf

override_dh_auto_configure:
	CXX="c++ $(HURD_LIBPTHREAD) -Wl,--as-needed -Wl,-O1" dh_auto_configure

override_dh_auto_build:
	cd doc && latex2man -M -t pstoedit.trans pstoedit.tex pstoedit.1
	cd doc && latex2man -H -t pstoedit.trans pstoedit.tex pstoedit.htm
	dh_auto_build

override_dh_auto_clean:
	dh_auto_clean
	rm -f debian/buildinfo
	rm -rf autom4te.cache
	rm -f doc/pstoedit.1 doc/pstoedit.htm

override_dh_auto_install:
	dh_auto_install
	
	@for plugin in libp2edrvstd libp2edrvmagick++ libp2edrvlplot ; do \
		if ! test -r $(CURDIR)/debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/pstoedit/$$plugin.la ; then \
			echo "" ; \
			echo "pstoedit plugins \"$$plugin\" didn't get installed properly" ; \
			echo "Please investigate" ; \
			exit 1; \
		fi ; \
		sed -i "/dependency_libs/ s/'.*'/''/" $(CURDIR)/debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/pstoedit/$$plugin.la ; \
	done

override_dh_installchangelogs:
	dh_installchangelogs doc/changelog.htm