mirror of
https://github.com/imsnif/bandwhich.git
synced 2026-02-09 10:09:20 +08:00
* build: Add Makefile for building on Linux with make * packaging: Add debian packaging to build on Debian platforms * Define `env CLEAN=0` to prevent from rebuilding sources * Define `env VENDOR=0` to prevent vendoring of sources To build in a schroot for bionic: ``` sbuild -d bionic --extra-repository='deb [trusted=yes] http://ppa.launchpad.net/mmstick76/rust/ubuntu bionic main' ``` Replace bionic with whichever Ubuntu release you are building for
23 lines
310 B
Makefile
Executable File
23 lines
310 B
Makefile
Executable File
#!/usr/bin/make -f
|
|
|
|
export VENDOR ?= 1
|
|
export prefix = /usr
|
|
CLEAN ?= 1
|
|
|
|
%:
|
|
dh $@
|
|
|
|
override_dh_auto_clean:
|
|
ifeq ($(CLEAN),1)
|
|
make clean;
|
|
endif
|
|
ifeq ($(VENDOR),1)
|
|
if ! ischroot; then \
|
|
make vendor; \
|
|
rm -rf vendor; \
|
|
fi
|
|
endif
|
|
|
|
override_dh_auto_build:
|
|
env CARGO_HOME="$$(pwd)/target/cargo" dh_auto_build
|