diff options
author | Colin Walters <walters@verbum.org> | 2021-04-15 11:13:31 -0400 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2021-04-15 12:33:34 -0400 |
commit | 46a0911c6d3999e36a10861c94f0c48c033a46f2 (patch) | |
tree | 12887858fbe065e71540bb94968005dfd97fab5b | |
parent | 36693f064c63dad550ebcfed33bf9b95806ddef9 (diff) | |
download | ostree-46a0911c6d3999e36a10861c94f0c48c033a46f2.tar.gz |
build-sys: Add toplevel workspace Cargo.toml
rust-analyzer is happier with this because it understands
the project structure out of the box.
We aren't actually again adding a dependency on Rust/cargo in the core,
this is only used to make `cargo build` work out of the box to build
the Rust test code.
-rw-r--r-- | Cargo.toml | 6 | ||||
-rw-r--r-- | Makefile.am | 3 | ||||
-rw-r--r-- | tests/inst/.gitignore | 2 | ||||
-rw-r--r-- | tests/kolainst/Makefile | 2 |
4 files changed, 10 insertions, 3 deletions
diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 00000000..b2aa3f4e --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,6 @@ +# Today, this repository only uses Rust for tests. This +# toplevel Cargo.toml helps tools like rust-analyzer understand +# that this project contains Rust code. We don't otherwise currently +# use `cargo` for any part of the core build. +[workspace] +members = ["tests/inst"] diff --git a/Makefile.am b/Makefile.am index b2588ad7..2f3cb53f 100644 --- a/Makefile.am +++ b/Makefile.am @@ -46,6 +46,9 @@ GITIGNOREFILES = aclocal.m4 build-aux/ buildutil/*.m4 config.h.in gtk-doc.make # Generated by coreos-assembler build-fast and kola GITIGNOREFILES += fastbuild-*.qcow2 _kola_temp/ +# Rust stuff +GITIGNOREFILES += target/ Cargo.lock + SUBDIRS += . if ENABLE_GTK_DOC diff --git a/tests/inst/.gitignore b/tests/inst/.gitignore deleted file mode 100644 index 2c96eb1b..00000000 --- a/tests/inst/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -target/ -Cargo.lock diff --git a/tests/kolainst/Makefile b/tests/kolainst/Makefile index acfdc3b7..5dc18281 100644 --- a/tests/kolainst/Makefile +++ b/tests/kolainst/Makefile @@ -12,6 +12,6 @@ all: install: install -D -m 0644 -t $(KOLA_TESTDIR) $(LIBSCRIPTS) for x in $(TESTDIRS); do rsync -rlv ./$${x} $(KOLA_TESTDIR)/; done - install -D -m 0755 -t $(KOLA_TESTDIR)/nondestructive-rs ../inst/target/release/ostree-test + install -D -m 0755 -t $(KOLA_TESTDIR)/nondestructive-rs ../../target/release/ostree-test install -D -m 0644 destructive-stamp.ign $(KOLA_TESTDIR)/destructive-rs/config.ign ./install-wrappers.sh destructive-list.txt $(KOLA_TESTDIR)/destructive-rs |