File: rules

package info (click to toggle)
gap-autodoc 2023.06.19-1
  • links: PTS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,360 kB
  • sloc: xml: 1,930; javascript: 155; makefile: 122; sh: 9
file content (55 lines) | stat: -rwxr-xr-x 1,400 bytes parent folder | download | duplicates (2)
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
46
47
48
49
50
51
52
53
54
55
#!/usr/bin/make -f
# Copyright 2018 Bill Allombert <ballombe@debian.org>

export SOURCE_DATE_EPOCH = $(shell date -d "$$(dpkg-parsechangelog -SDate)" +%s)
export FORCE_SOURCE_DATE = 1
export LC_ALL = C

build-indep-stamp:
	mkdir -p debian/gaproot/pkg
	ln -s ../../.. debian/gaproot/pkg/AutoDoc
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	gap -q -l "$$PWD/debian/gaproot;/usr/share/gap" < tst/testall.g | tee debian/gap.tst
	! grep "^########" debian/gap.tst
endif
	echo 'PushOptions(rec(relativePath:=true)); Read("makedoc.g");' \
	| gap -q -l 'debian/gaproot;/usr/share/gap' && touch build-indep-stamp
build-indep: build-indep-stamp
build-arch:
build: build-indep

clean:
	dh_testdir
	dh_testroot
	make -C doc clean
	rm -f build-indep-stamp
	rm -rf debian/gaproot
	rm -f debian/gap.tst
	rm -rf tst/worksheets/general.actual
	rm -rf tst/worksheets/autoplain.actual
	dh_clean

install: build
	dh_testdir
	dh_testroot
	dh_prep
	dh_installdirs
	dh_install *.g gap usr/share/gap/pkg/AutoDoc
	make -C doc install DESTDIR=../debian/gap-autodoc
binary-arch: build-arch
binary-indep: build-indep install
	dh_testdir
	dh_testroot
	dh_installdocs README.md TODO
	dh_installexamples
	dh_installchangelogs CHANGES
	dh_link
	dh_compress
	dh_fixperms
	dh_installdeb
	dh_gencontrol
	dh_md5sums
	dh_builddeb

binary: binary-indep binary-arch
.PHONY: build clean binary-indep binary-arch binary install configure