summaryrefslogtreecommitdiff
path: root/debian/rules
blob: e72cc505166b31d71154259f465e5452d2f834f0 (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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/usr/bin/make -f
# -*- makefile -*-

include /usr/share/dpkg/default.mk

# Verbose mode
export DH_VERBOSE=1

with :=
ifeq (illumos,$(DEB_HOST_ARCH_OS))
with += smf
endif
ifeq (linux,$(DEB_HOST_ARCH_OS))
with += systemd
endif

%:
	dh $@ $(with:%=--with %)

override_dh_installinit:
	dh_installinit -ppuppetmaster
	dh_installinit --name=puppetqd
	dh_installinit -ppuppet --error-handler=true -- defaults 21

override_dh_auto_install:
	./install.rb --destdir=debian/tmp --sitelibdir=/usr/lib/ruby/vendor_ruby --ruby=/usr/bin/ruby
	rm -vfr debian/tmp/usr/lib/ruby/vendor_ruby/puppet/vendor/safe_yaml/
	rm -vfr debian/tmp/usr/lib/ruby/vendor_ruby/puppet/vendor/rgen/

override_dh_install:
	dh_install --fail-missing -Xusr/share/man
	mv debian/puppetmaster-passenger/usr/share/puppetmaster-passenger/example-passenger-vhost.conf \
	  debian/puppetmaster-passenger/usr/share/puppetmaster-passenger/apache2.site.conf.tmpl
	chmod 755 debian/puppet-common/etc/puppet/etckeeper-commit-post
	chmod 755 debian/puppet-common/etc/puppet/etckeeper-commit-pre
	echo 0 > debian/puppet-el/usr/lib/emacsen-common/packages/compat/puppet-el

override_dh_installlogcheck:
	ln ext/logcheck/puppet debian/puppet-common.logcheck.ignore.server
	dh_installlogcheck

override_dh_installexamples:
	dh_installexamples
	find debian/puppet-common/usr/share/doc/puppet-common/examples -type f -print0 | \
	  xargs -r -0 chmod 644

override_dh_clean:
	dh_clean debian/puppet-common.logcheck.ignore.server metadata.yml