It is a source file, so explicitly look for it in the source directory.
---
rust/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/rust/Makefile.am b/rust/Makefile.am
index 979e98bd4..edcccffa1 100644
--- a/rust/Makefile.am
+++ b/rust/Makefile.am
@@ -32,7 +32,7 @@ EXTRA_DIST = \
if HAVE_RUST
-all: src/lib.rs
+all: $(srcdir)/src/lib.rs
$(top_builddir)/run $(CARGO) build --release
TESTS = run-bindtests run-tests
--
2.23.0