]> git.lizzy.rs Git - rust.git/commit
Add a new run-make test directory
authorAlex Crichton <alex@alexcrichton.com>
Sun, 17 Nov 2013 01:07:32 +0000 (17:07 -0800)
committerAlex Crichton <alex@alexcrichton.com>
Sat, 30 Nov 2013 02:36:14 +0000 (18:36 -0800)
commit6d6ccb75ff2240ed294fcf6aa57e96c72316954c
treeae07356d883d3d076460b5a0a821e2b93f554e2f
parent9fbba7b2eeabd073f9518f2dbd50f4eabb621c67
Add a new run-make test directory

This infrastructure is meant to support runnings tests that involve various
interesting interdependencies about the types of crates being linked or possibly
interacting with C libraries. The goal of these make tests is to not restrict
them to a particular test runner, but allow each test to run its own tests.

To this end, there is a new src/test/run-make directory which has sub-folders of
tests. Each test requires a `Makefile`, and running the tests constitues simply
running `make` inside the directory. The new target is `check-stageN-rmake`.

These tests will have the destination directory (as TMPDIR) and the local rust
compiler (as RUSTC) passed along to them. There is also some helpful
cross-platform utilities included in src/test/run-make/tools.mk to aid with
compiling C programs and running them.

The impetus for adding this new test suite is to allow various interesting forms
of testing rust linkage. All of the tests initially added are various flavors of
compiling Rust and C with one another as well as just making sure that rust
linkage works in general.

Closes #10434
58 files changed:
mk/tests.mk
src/etc/maketest.py [new file with mode: 0644]
src/test/run-make/c-dynamic-dylib/Makefile [new file with mode: 0644]
src/test/run-make/c-dynamic-dylib/bar.rs [new file with mode: 0644]
src/test/run-make/c-dynamic-dylib/cfoo.c [new file with mode: 0644]
src/test/run-make/c-dynamic-dylib/foo.rs [new file with mode: 0644]
src/test/run-make/c-dynamic-rlib/Makefile [new file with mode: 0644]
src/test/run-make/c-dynamic-rlib/bar.rs [new file with mode: 0644]
src/test/run-make/c-dynamic-rlib/cfoo.c [new file with mode: 0644]
src/test/run-make/c-dynamic-rlib/foo.rs [new file with mode: 0644]
src/test/run-make/c-link-to-rust-dylib/Makefile [new file with mode: 0644]
src/test/run-make/c-link-to-rust-dylib/bar.c [new file with mode: 0644]
src/test/run-make/c-link-to-rust-dylib/foo.rs [new file with mode: 0644]
src/test/run-make/c-link-to-rust-staticlib/Makefile [new file with mode: 0644]
src/test/run-make/c-link-to-rust-staticlib/bar.c [new file with mode: 0644]
src/test/run-make/c-link-to-rust-staticlib/foo.rs [new file with mode: 0644]
src/test/run-make/c-static-dylib/Makefile [new file with mode: 0644]
src/test/run-make/c-static-dylib/bar.rs [new file with mode: 0644]
src/test/run-make/c-static-dylib/cfoo.c [new file with mode: 0644]
src/test/run-make/c-static-dylib/foo.rs [new file with mode: 0644]
src/test/run-make/c-static-rlib/Makefile [new file with mode: 0644]
src/test/run-make/c-static-rlib/bar.rs [new file with mode: 0644]
src/test/run-make/c-static-rlib/cfoo.c [new file with mode: 0644]
src/test/run-make/c-static-rlib/foo.rs [new file with mode: 0644]
src/test/run-make/dylib-chain/Makefile [new file with mode: 0644]
src/test/run-make/dylib-chain/m1.rs [new file with mode: 0644]
src/test/run-make/dylib-chain/m2.rs [new file with mode: 0644]
src/test/run-make/dylib-chain/m3.rs [new file with mode: 0644]
src/test/run-make/dylib-chain/m4.rs [new file with mode: 0644]
src/test/run-make/mixing-deps/Makefile [new file with mode: 0644]
src/test/run-make/mixing-deps/both.rs [new file with mode: 0644]
src/test/run-make/mixing-deps/dylib.rs [new file with mode: 0644]
src/test/run-make/mixing-deps/prog.rs [new file with mode: 0644]
src/test/run-make/mixing-libs/Makefile [new file with mode: 0644]
src/test/run-make/mixing-libs/dylib.rs [new file with mode: 0644]
src/test/run-make/mixing-libs/prog.rs [new file with mode: 0644]
src/test/run-make/mixing-libs/rlib.rs [new file with mode: 0644]
src/test/run-make/prefer-dylib/Makefile [new file with mode: 0644]
src/test/run-make/prefer-dylib/bar.rs [new file with mode: 0644]
src/test/run-make/prefer-dylib/foo.rs [new file with mode: 0644]
src/test/run-make/prefer-rlib/Makefile [new file with mode: 0644]
src/test/run-make/prefer-rlib/bar.rs [new file with mode: 0644]
src/test/run-make/prefer-rlib/foo.rs [new file with mode: 0644]
src/test/run-make/rlib-chain/Makefile [new file with mode: 0644]
src/test/run-make/rlib-chain/m1.rs [new file with mode: 0644]
src/test/run-make/rlib-chain/m2.rs [new file with mode: 0644]
src/test/run-make/rlib-chain/m3.rs [new file with mode: 0644]
src/test/run-make/rlib-chain/m4.rs [new file with mode: 0644]
src/test/run-make/simple-dylib/Makefile [new file with mode: 0644]
src/test/run-make/simple-dylib/bar.rs [new file with mode: 0644]
src/test/run-make/simple-dylib/foo.rs [new file with mode: 0644]
src/test/run-make/simple-rlib/Makefile [new file with mode: 0644]
src/test/run-make/simple-rlib/bar.rs [new file with mode: 0644]
src/test/run-make/simple-rlib/foo.rs [new file with mode: 0644]
src/test/run-make/static-unwinding/Makefile [new file with mode: 0644]
src/test/run-make/static-unwinding/lib.rs [new file with mode: 0644]
src/test/run-make/static-unwinding/main.rs [new file with mode: 0644]
src/test/run-make/tools.mk [new file with mode: 0644]