File: rules

package info (click to toggle)
puppetdb 7.12.1-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 9,484 kB
  • sloc: javascript: 23,285; ruby: 5,541; sh: 3,459; python: 389; xml: 181; makefile: 114
file content (45 lines) | stat: -rwxr-xr-x 1,140 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
# See debhelper(7) (uncomment to enable)
# output every command that modifies files on the build system.
#export DH_VERBOSE = 1

include /usr/share/javahelper/java-vars.mk
include /usr/share/dpkg/pkg-info.mk

export LEIN_HOME=$(CURDIR)/.lein
export LEIN_OFFLINE=true
NAME=puppetdb

%:
	dh $@ --with=javahelper --with maven_repo_helper

override_dh_auto_configure:
	cd debian && ln -sf /usr/share/maven-repo .

override_dh_auto_build:
	lein pom debian/pom.xml
	lein jar
	cd target && mv $(NAME)-$(DEB_VERSION_UPSTREAM).jar $(NAME).jar

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	export pg_ver=$$(/usr/share/postgresql-common/supported-versions --installed); \
	export PATH=$$PATH:$(CURDIR)/debian/bin && \
	./ext/bin/with-pdbbox \
		--box $$(mktemp -d "core-test-XXXXXX")/box \
		--pgbin /usr/lib/postgresql/$$pg_ver/bin \
		--pgport 5432 \
		-- lein test
endif

execute_after_dh_install:
	rm debian/puppetdb/etc/puppetdb/conf.d/database.ini

override_dh_installsystemd:
	dh_installsystemd --no-enable

override_dh_clean:
	rm -f debian/maven-repo
	rm -Rf target
	rm -f debian/pom.xml
	dh_clean