File: rules

package info (click to toggle)
obs-color-monitor 0.9.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, trixie
  • size: 728 kB
  • sloc: ansic: 3,515; cpp: 2,390; sh: 72; makefile: 31
file content (44 lines) | stat: -rwxr-xr-x 1,400 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
#!/usr/bin/make -f
#export DH_VERBOSE = 1

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

export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# Exclude "obs-" from NAME and set a DEST
export PLUGIN_NAME=$(shell echo ${DEB_SOURCE} | cut -d"-" -f2-)
export PLUGIN_DEST=debian/${DEB_SOURCE}/usr/lib/${DEB_TARGET_MULTIARCH}/obs-plugins

%:
	dh $@

execute_before_dh_auto_configure:
	if [ "$(shell hostname)" = "canopus" ]; then \
	    LINESUS=$(shell cat data/locale/en-US.ini | wc -l); \
	    LINESPT=$(shell cat data/locale/pt-BR.ini | wc -l); \
	    if [ "$$LINESUS" != "$$LINESPT" ]; then \
	        echo "ERROR: Translation to pt_BR is out of date."; \
	        exit 1; \
	    fi; \
	fi

override_dh_auto_configure:
	dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr \
                             -DLINUX_PORTABLE=Off \
                             -DLINUX_RPATH=Off \
                             -DQT_VERSION=6

execute_before_dh_auto_build:
	@echo "blhc: ignore-line-regexp: .*/CMakeCXXCompilerABI.cpp.*"

execute_after_dh_install-arch:
	# Check if the plugin is in right place
	ls ${PLUGIN_DEST}/${PLUGIN_NAME}.so

execute_after_dh_installdocs:
	cd debian/${DEB_SOURCE}/usr/share/doc/${DEB_SOURCE}; \
	for i in dock.md falsecolor.md global_config.md histogram.md vectorscope.md waveform.md zebra.md; \
	do \
	    name=`echo $$i | cut -d"." -f1`; \
	    pandoc $$i -f markdown -t plain -o $$name.txt; \
	done