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.
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@ \