chore: Switch from Makefile to justfile
This commit is contained in:
parent
d17acbd9ce
commit
2c7af23323
3 changed files with 119 additions and 111 deletions
27
debian/rules
vendored
27
debian/rules
vendored
|
|
@ -1,6 +1,6 @@
|
|||
#!/usr/bin/make -f
|
||||
|
||||
export VENDOR ?= 1
|
||||
VENDOR ?= 1
|
||||
CLEAN ?= 1
|
||||
DESTDIR=debian/tmp
|
||||
|
||||
|
|
@ -8,15 +8,26 @@ DESTDIR=debian/tmp
|
|||
dh $@ --with=systemd
|
||||
|
||||
override_dh_auto_clean:
|
||||
ifeq ($(CLEAN),1)
|
||||
ischroot && make clean || make distclean
|
||||
endif
|
||||
ifeq ($(VENDOR),1)
|
||||
ischroot || make vendor
|
||||
endif
|
||||
if test "${CLEAN}" = "1"; then \
|
||||
cargo clean; \
|
||||
fi
|
||||
|
||||
if ! ischroot && test "${VENDOR}" = "1"; then \
|
||||
mkdir -p .cargo; \
|
||||
cargo vendor --sync plugins/Cargo.toml \
|
||||
--sync bin/Cargo.toml \
|
||||
--sync service/Cargo.toml \
|
||||
| head -n -1 > .cargo/config; \
|
||||
echo 'directory = "vendor"' >> .cargo/config; \
|
||||
tar pcf vendor.tar vendor; \
|
||||
rm -rf vendor; \
|
||||
fi
|
||||
|
||||
override_dh_auto_build:
|
||||
CARGO_HOME="$$(pwd)/target/cargo" make DESTDIR=$(DESTDIR)
|
||||
env CARGO_HOME="$$(pwd)/target/cargo" just rootdir=$(DESTDIR) debug=$(DEBUG) vendor=$(VENDOR)
|
||||
|
||||
override_dh_auto_install:
|
||||
just rootdir=$(DESTDIR) install
|
||||
|
||||
override_dh_fixperms:
|
||||
dh_fixperms
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue