File: rules

package info (click to toggle)
amdsmi 7.2.0-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 7,428 kB
  • sloc: cpp: 42,484; python: 22,906; ansic: 12,578; sh: 762; makefile: 20
file content (30 lines) | stat: -rwxr-xr-x 913 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
#!/usr/bin/make -f
export DH_VERBOSE = 1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all optimize=-lto

include /usr/share/dpkg/pkg-info.mk

CMAKE_FLAGS := -DENABLE_ESMI_LIB=ON
# ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
# CMAKE_FLAGS += -DBUILD_TESTS=ON -DINSTALL_GTEST=OFF
# endif

%:
	dh $@ -Scmake --builddir=build

override_dh_auto_configure:
	dh_auto_configure -- $(CMAKE_FLAGS)

override_dh_installman:
	txt2man -P amd-smi -s 1 -v "AMD System Management Interface" \
		-t "AMDSMI(1)" \
		-r amdsmi-$(DEB_VERSION_UPSTREAM) \
		$(CURDIR)/debian/amd-smi-help.txt > $(CURDIR)/debian/amd-smi.1
	dh_installman

override_dh_builddeb:
	chmod -x $(CURDIR)/debian/amd-smi/usr/libexec/amdsmi_cli/BDF.py
	chmod -x $(CURDIR)/debian/amd-smi/usr/libexec/amdsmi_cli/__init__.py
	chmod -x $(CURDIR)/debian/amd-smi/usr/libexec/amdsmi_cli/_version.py
	ls -al $(CURDIR)/debian/amd-smi/usr/libexec/amdsmi_cli
	dh_builddeb