-
Notifications
You must be signed in to change notification settings - Fork 1.3k
/
Copy pathrules
executable file
·26 lines (20 loc) · 937 Bytes
/
rules
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
#!/usr/bin/make -f
# See debhelper(7) (uncomment to enable)
# output every command that modifies files on the build system.
#DH_VERBOSE = 1
# see EXAMPLES in dpkg-buildflags(1) and read /usr/share/dpkg/*
DPKG_EXPORT_BUILDFLAGS = 1
include /usr/share/dpkg/default.mk
# see FEATURE AREAS in dpkg-buildflags(1)
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
export deb_udevdir = $(shell pkg-config --variable=udevdir udev | sed s,^/,,)
%:
dh $@ --buildsystem cmake
override_dh_auto_configure:
dh_auto_configure -- \
-DSTLINK_UDEV_RULES_DIR='/lib/udev/rules.d'
-DSTLINK_UDEV_RULES_DIR=/$(deb_udevdir)/rules.d
override_dh_auto_install:
dh_auto_install
mkdir -p $(CURDIR)/debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig
sed -e "s/@VERSION@/$(DEB_VERSION_UPSTREAM)/" -e "s/@DEB_HOST_MULTIARCH@/$(DEB_HOST_MULTIARCH)/" $(CURDIR)/debian/stlink.pc.in > $(CURDIR)/debian/tmp/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/stlink.pc