File: rules

package info (click to toggle)
opencl-clang-21 21.1.2-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 356 kB
  • sloc: cpp: 1,242; ansic: 47; makefile: 19; sh: 10
file content (28 lines) | stat: -rwxr-xr-x 727 bytes parent folder | download | duplicates (5)
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
#!/usr/bin/make -f

export DEB_BUILD_MAINT_OPTIONS	 = hardening=+all

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

LLVM_VERSION		 = $(shell sed -n -r '/^Build/,/^$$/s/.*llvm-([0-9]+)-dev.*/\1/p' debian/control)
LLVM_UPSTREAM_VERSION	 = $(shell dpkg-query -f '$${source:Upstream-Version}\n' -W llvm-$(LLVM_VERSION)-dev)

%:
	dh $@

override_dh_auto_configure:
	dh_auto_configure -- \
		-DLLVMSPIRV_INCLUDED_IN_LLVM=OFF \
		-DSPIRV_TRANSLATOR_DIR=/usr/lib \
		-DCMAKE_SKIP_RPATH=true \
		-Wno-dev

execute_after_dh_clean:
	$(RM) -r opencl-clang-??.?.?


ifneq (,$(wildcard .git))
upstream:
	git remote show $@ >/dev/null 2>&1 || git remote add $@ $(shell sed -rn 's/Repository: //p' debian/upstream/metadata)
	git fetch $@ --prune
endif