From 1e741641a619eee5c6aa5e834bf8b2279410b024 Mon Sep 17 00:00:00 2001 From: Jason Ish Date: Fri, 24 Jan 2020 12:27:27 -0600 Subject: [PATCH] rust: make clean fixups For make clean, only remove gen/ if cbindgen is available. This prevents make clean from remove gen when the headers were bundled, but cbindgen is not available to remove them. Unconditionally remove gen and vendor in maintainerclean. --- rust/Makefile.am | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/rust/Makefile.am b/rust/Makefile.am index f9fff8ffab..158d348b72 100644 --- a/rust/Makefile.am +++ b/rust/Makefile.am @@ -43,10 +43,16 @@ else endif clean-local: - -rm -rf target gen + rm -rf target +if HAVE_CBINDGEN + rm -rf gen +endif + +distclean-local: + rm -f Cargo.lock -distclean-local: clean-local - rm -rf vendor gen Cargo.lock +maintainerclean-local: + rm -rf vendor gen check: CARGO_HOME="$(CARGO_HOME)" @rustup_home@ \ -- 2.47.2