Make docs target depend directly on the some docs-only required
binaries and add a new intermediate ".do-cargo-build" target that is
explicitly not a PHONY target.
That avoids one extra set of full builds.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
-all: cargo-build $(SUBDIRS)
.PHONY: $(SUBDIRS)
$(SUBDIRS):
.PHONY: $(SUBDIRS)
$(SUBDIRS):
$(foreach i,$(SUBDIRS), \
$(MAKE) -C $(i) clean ;)
$(CARGO) clean
$(foreach i,$(SUBDIRS), \
$(MAKE) -C $(i) clean ;)
$(CARGO) clean
find . -name '*~' -exec rm {} ';'
# allows one to avoid running cargo clean when one just wants to tidy up after a packgae build
find . -name '*~' -exec rm {} ';'
# allows one to avoid running cargo clean when one just wants to tidy up after a packgae build
dpkg -i $^
# make sure we build binaries before docs
dpkg -i $^
# make sure we build binaries before docs
+docs: $(COMPILEDIR)/dump-catalog-shell-cli $(COMPILEDIR)/docgen
.PHONY: cargo-build
cargo-build:
.PHONY: cargo-build
cargo-build:
+ rm -f .do-cargo-build
+ $(MAKE) $(COMPILED_BINS)
+
+$(COMPILED_BINS) $(COMPILEDIR)/dump-catalog-shell-cli $(COMPILEDIR)/docgen: .do-cargo-build
+.do-cargo-build:
RUSTFLAGS="--cfg openid" $(CARGO) build $(CARGO_BUILD_ARGS) \
--bin proxmox-backup-api --bin proxmox-backup-proxy \
--bin proxmox-backup-manager --bin docgen
RUSTFLAGS="--cfg openid" $(CARGO) build $(CARGO_BUILD_ARGS) \
--bin proxmox-backup-api --bin proxmox-backup-proxy \
--bin proxmox-backup-manager --bin docgen
--bin proxmox-tape \
--bin pxar \
--bin sg-tape-cmd
--bin proxmox-tape \
--bin pxar \
--bin sg-tape-cmd
-$(COMPILED_BINS): cargo-build