File: rules

package info (click to toggle)
freeipmi 1.6.3-1.1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 24,160 kB
  • sloc: ansic: 318,886; sh: 12,191; makefile: 2,109; perl: 1,078
file content (59 lines) | stat: -rwxr-xr-x 1,994 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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#!/usr/bin/make -f
# -*- makefile -*-

# --fail-missing for dh_install
# --link-doc for dh_installdocs
%:
	dh $@ --with autotools_dev --fail-missing --link-doc=freeipmi-common

override_dh_auto_configure:
	: # suppress multiarch support for now
	dh_auto_configure -- --libdir=/usr/lib

override_dh_auto_install:
	dh_auto_install

	: # Clean up duplicate/unneeded copyright/installation files
	rm -f $(CURDIR)/debian/tmp/usr/share/doc/freeipmi/COPYING*
	rm -f $(CURDIR)/debian/tmp/usr/share/doc/freeipmi/DISCLAIMER*
	rm -f $(CURDIR)/debian/tmp/usr/share/doc/freeipmi/INSTALL
	rm -f $(CURDIR)/debian/tmp/usr/share/doc/freeipmi/ChangeLog

	: # We don't need the libtool metadata nor the init scripts
	rm $(CURDIR)/debian/tmp/usr/lib/libfreeipmi.la
	rm $(CURDIR)/debian/tmp/usr/lib/libipmiconsole.la
	rm $(CURDIR)/debian/tmp/usr/lib/libipmimonitoring.la
	rm $(CURDIR)/debian/tmp/usr/lib/libipmidetect.la
	rm $(CURDIR)/debian/tmp/etc/init.d/bmc-watchdog
	rm $(CURDIR)/debian/tmp/etc/init.d/ipmidetectd
	rm $(CURDIR)/debian/tmp/etc/init.d/ipmiseld

	: # chrpath -- operate only on files (not on still dangling symlinks)
	/usr/bin/find  $(CURDIR)/debian/*/usr/sbin -type f \
	| xargs grep -L '#!/bin/sh' \
	| xargs chrpath -d
	chrpath -d $(CURDIR)/debian/*/usr/lib/*.so.*

	: # assure no dir.gz
	rm -f $(CURDIR)/debian/tmp/usr/share/info/dir

	: # Use Debian specific init files with "matching" names
	dh_installinit -pfreeipmi-bmc-watchdog \
	 --name=bmc-watchdog --no-enable --no-start
	dh_installinit -pfreeipmi-ipmidetect \
	 --name=ipmidetectd --no-enable --no-start
	dh_installinit -pfreeipmi-ipmiseld \
	 --name=ipmiseld

override_dh_installlogrotate:
	dh_installlogrotate --name=bmc-watchdog

override_dh_fixperms-indep:
	dh_fixperms

	: # since it contains sensitive information
	chmod 640      $(CURDIR)/debian/freeipmi-common/etc/freeipmi/freeipmi.conf
	chown root:adm $(CURDIR)/debian/freeipmi-common/etc/freeipmi/freeipmi.conf

override_dh_installchangelogs:
	dh_installchangelogs --keep