File: rules

package info (click to toggle)
node-expat 2.3.18+ds-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 1,632 kB
  • sloc: xml: 42,159; javascript: 568; cpp: 377; makefile: 20; sh: 4
file content (30 lines) | stat: -rwxr-xr-x 734 bytes parent folder | download
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 DEB_BUILD_MAINT_OPTIONS = hardening=+all

# try resolve from shlibdep of libnodeXX, or use full nodejs version
NODEJS_VERSION = $(shell \
 grep -Po '^shlibs:Depends=.*libnode\d+ \(>= \K\S+(?=\))' \
  debian/node-node-expat.substvars \
 || dpkg-query --showformat='$${source:Version}' --show nodejs)

override_dh_auto_configure:
	node-gyp configure

override_dh_auto_build:
	node-gyp build

override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
	NODE_PATH=lib vows --spec ./test/**/*.js
endif

override_dh_install:
	dh_install
	find debian/node-node-expat/usr/lib -name *.node -exec chmod 644 '{}' \;

override_dh_gencontrol:
	dh_gencontrol -- -V"nodejs:Depends=$(NODEJS_VERSION)"

%:
	dh $@