Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2
3 include /usr/share/dpkg/pkg-info.mk
4 include /usr/share/rustc/architecture.mk
5 export DEB_HOST_RUST_TYPE DEB_HOST_GNU_TYPE
6 export PATH := /usr/share/cargo/bin:$(PATH)
7 export CARGO=/usr/share/cargo/bin/cargo
8 export CARGO_HOME=$(shell pwd)/debian/cargo_home
9 export DEB_CARGO_CRATE=$(DEB_SOURCE)_$(DEB_VERSION_UPSTREAM)
10 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
11
12 %:
13 dh $@ --buildsystem=cargo --without single-binary
14
15 execute_after_dh_auto_clean:
16 rm -rf debian/cargo_registry
17 rm -rf debian/cargo-checksum.json
18
19 # touch a dummy checksum to allow building
20 execute_before_dh_auto_configure:
21 $(CARGO) prepare-debian debian/cargo_registry --link-from-system
22 rm -f Cargo.lock
23 touch debian/cargo-checksum.json
24
25 execute_before_dh_installdocs:
26 mdbook build book --dest-dir html
27
28 execute_after_dh_auto_install:
29 /usr/share/cargo/bin/dh-cargo-built-using gir