File: rules

package info (click to toggle)
lm-sensors 1%3A3.6.0-7.1
  • links: PTS
  • area: main
  • in suites: bookworm
  • size: 3,236 kB
  • sloc: perl: 6,461; ansic: 5,303; sh: 2,301; lex: 372; yacc: 296; makefile: 220
file content (71 lines) | stat: -rwxr-xr-x 1,977 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#!/usr/bin/make -f

%:
	dh $@

MAKEARGS_INDP = DESTDIR=$(CURDIR)/debian/tmp \
		PREFIX=/usr \
		LIBDIR=/usr/lib/$(DEB_HOST_MULTIARCH) \
		MANDIR=/usr/share/man
MAKEARGS_ARCH = $(MAKEARGS_INDP) \
		ARCH=$(DEB_HOST_GNU_CPU) \
		CFLAGS="$(CFLAGS)" \
		CPPFLAGS="$(CPPFLAGS)" \
		LDFLAGS="$(LDFLAGS)" \
		EXLDFLAGS="$(LDFLAGS)"

override_dh_auto_clean:
	dh_auto_clean -- $(MAKEARGS_ARCH)

# Ignore missing files on non-Linux. This package is Linux specific, and
# is just minimally built on other OS to simplify porters work.
ifneq ($(DEB_HOST_ARCH_OS),linux)
override_dh_missing:
	dh_missing --list-missing
endif

#
# Architecture independent targets
#
override_dh_auto_build-indep:

override_dh_auto_install-indep:
	$(MAKE) install-etc install-prog-pwm $(MAKEARGS_INDP)
	mkdir -p $(CURDIR)/debian/fancontrol/lib/systemd/system-sleep/
	install -m 755 $(CURDIR)/debian/fancontrol-systemd-sleep $(CURDIR)/debian/fancontrol/lib/systemd/system-sleep/fancontrol

	# Make sure /etc/sensors.d/ is not removed
	touch $(CURDIR)/debian/tmp/etc/sensors.d/.placeholder

override_dh_installinit-indep:
	dh_installinit -pfancontrol --restart-after-upgrade

override_dh_installsystemd-indep:
	dh_installsystemd -pfancontrol --restart-after-upgrade


#
# Architecture targets
#
override_dh_auto_build-arch:
	dh_auto_build -- $(MAKEARGS_ARCH)

override_dh_auto_install-arch:
	dh_auto_install -- $(MAKEARGS_ARCH)

	# Install isadump only if it has been built (on x86/x86_64 archs only)
	if [ -x prog/dump/isadump ] ; then \
		dh_install -plm-sensors usr/sbin/isadump ; \
		dh_install -plm-sensors usr/share/man/man8/isadump.8 ; \
	fi
	# Install isaset only if it has been built (on x86/x86_64 archs only)
	if [ -x prog/dump/isaset ] ; then \
		dh_install -plm-sensors usr/sbin/isaset ; \
		dh_install -plm-sensors usr/share/man/man8/isaset.8 ; \
	fi

override_dh_installinit-arch:
	dh_installinit -plm-sensors --no-start

override_dh_installsystemd-arch:
	dh_installsystemd -plm-sensors --no-start