Promote the src/tools crate to the top-level workspace.

The 'src' and 'tests' top-level directories now contain tools sources
and integration tests for any of the library crates.
This commit is contained in:
Jakob Stoklund Olesen
2016-10-17 14:57:42 -07:00
parent 846db00a21
commit f9734458f8
18 changed files with 25 additions and 23 deletions

View File

@@ -1,3 +1,23 @@
# Phantom workspace manifest for all Cretonne crates.
[package]
name = "cretonne-tools"
authors = ["The Cretonne Project Developers"]
version = "0.0.0"
description = "Binaries for testing the Cretonne library"
license = "Apache-2.0"
documentation = "https://cretonne.readthedocs.io/"
repository = "https://github.com/stoklund/cretonne"
publish = false
[[bin]]
name = "cton-util"
path = "src/cton-util.rs"
[dependencies]
cretonne = { path = "lib/cretonne" }
cretonne-reader = { path = "lib/reader" }
filecheck = { path = "lib/filecheck" }
docopt = "0.6.86"
rustc-serialize = "0.3.19"
num_cpus = "1.1.0"
[workspace]
members = ["src/tools"]

View File

@@ -1,18 +0,0 @@
[package]
authors = ["The Cretonne Project Developers"]
name = "cretonne-tools"
version = "0.0.0"
description = "Binaries for testing the Cretonne library"
publish = false
[[bin]]
name = "cton-util"
path = "main.rs"
[dependencies]
cretonne = { path = "../../lib/cretonne" }
cretonne-reader = { path = "../../lib/reader" }
filecheck = { path = "../../lib/filecheck" }
docopt = "0.6.80"
rustc-serialize = "0.3.19"
num_cpus = "1.1.0"

View File

@@ -34,14 +34,14 @@ RUSTFMT_VERSION="0.6.2"
if cargo install --list | grep -q "^rustfmt v$RUSTFMT_VERSION"; then
banner "Rust formatting"
$topdir/src/format-all.sh --write-mode=diff
$topdir/format-all.sh --write-mode=diff
else
echo "Please install rustfmt v$RUSTFMT_VERSION to verify formatting."
echo "If a newer version of rustfmt is available, update this script."
fi
PKGS="cretonne cretonne-reader cretonne-tools filecheck"
cd "$topdir/src/tools"
cd "$topdir"
for PKG in $PKGS
do
banner "Rust $PKG unit tests"
@@ -49,7 +49,7 @@ do
done
# Build cton-util for parser testing.
cd "$topdir/src/tools"
cd "$topdir"
banner "Rust documentation"
echo "open $topdir/target/doc/cretonne/index.html"
cargo doc