File: rules

package info (click to toggle)
tree-sitter-vimdoc 4.0.0-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 852 kB
  • sloc: ansic: 16,522; javascript: 179; makefile: 119; lisp: 52; python: 50; cpp: 14; sh: 9
file content (27 lines) | stat: -rwxr-xr-x 663 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
#!/usr/bin/make -f

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

export DEB_VERSION_UPSTREAM
export TREE_SITTER_SRC_DIR = /usr/src/tree-sitter/vimdoc/${DEB_VERSION_UPSTREAM}/

%:
	dh $@

debian/%: debian/%.in
	sed "s/@PARSER_VER@/$(DEB_VERSION_UPSTREAM)/g" $< > $@

override_dh_auto_build:
	tree-sitter generate --abi $(shell sed -n 's/#define LANGUAGE_VERSION //p' src/parser.c)
	dh_auto_build --buildsystem=rust

# Do not run Makefile install
override_dh_auto_install:
	dh_auto_install --buildsystem=rust

override_dh_install: debian/Makefile
	dh_install

override_dh_auto_test:
	XDG_CACHE_HOME=$(CURDIR)/debian/.cache tree-sitter test
	dh_auto_test --buildsystem=rust