summaryrefslogtreecommitdiff
path: root/debian/rules
blob: a64e2c5ac7767cae69d42a22ddce5abb12af604b (plain)
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
#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

export VALAFLAGS:=$(foreach w,$(CPPFLAGS) $(CFLAGS) $(LDFLAGS),-X $(w))

CHDATE:=$(shell dpkg-parsechangelog --show-field=Date)

%:
	dh $@

override_dh_auto_configure:
	./configure --prefix=/usr --libexec=/usr/lib --disable-schemas-compile 

override_dh_install:
	dh_install
	# touch temporary c files with date of d/changelog
	# find -type f -name '*.c' -exec touch -r $(CURDIR)/debian/changelog {} \;
	# install temporary c files for debuging
	mkdir -p debian/shotwell-dbg/usr/share/doc/shotwell-dbg/temp-source
	find -type f -name '*.c' -exec cp --parent '{}' debian/shotwell-dbg/usr/share/doc/shotwell-dbg/temp-source/ ';'
	cd debian/shotwell-dbg/usr/share/doc/shotwell-dbg && \
	tar --mtime="$(CHDATE)" -cJf temp-source.tar.xz temp-source
	rm -fr debian/shotwell-dbg/usr/share/doc/shotwell-dbg/temp-source

override_dh_installchangelogs:
	dh_installchangelogs NEWS

override_dh_strip:
	dh_strip --dbg-package=shotwell-dbg

override_dh_compress:
	dh_compress -X.tar.xz