test --no-default-features and fix musl builds

This commit is contained in:
gnzlbg 2018-02-27 15:47:18 +01:00
parent bb2a95c9f2
commit 988843834f
3 changed files with 4 additions and 2 deletions

View file

@ -24,4 +24,5 @@ build: false
test_script:
- cargo test --target %TARGET%
- cargo test --no-default-features --target %TARGET%
- cargo test --manifest-path libc-test/Cargo.toml --target %TARGET%

View file

@ -79,4 +79,5 @@ if [ "$TARGET" = "x86_64-unknown-linux-gnux32" ]; then
opt="--release"
fi
exec cargo test $opt --no-default-features --target $TARGET
exec cargo test $opt --manifest-path libc-test/Cargo.toml --target $TARGET

View file

@ -277,8 +277,8 @@ cfg_if! {
// cargo build, don't pull in anything extra as the libstd dep
// already pulls in all libs.
} else if #[cfg(target_env = "musl")] {
#[link(name = "c", kind = "static", cfg(target_feature = "crt-static"))]
#[link(name = "c", cfg(not(target_feature = "crt-static")))]
#[cfg_attr(feature = "stdbuild", link(name = "c", kind = "static", cfg(target_feature = "crt-static")))]
#[cfg_attr(feature = "stdbuild", link(name = "c", cfg(not(target_feature = "crt-static"))))]
extern {}
} else if #[cfg(target_os = "emscripten")] {
#[link(name = "c")]