]> git.lizzy.rs Git - rust.git/commitdiff
Compiletest libc dependency can be unix-only
authorDavid Tolnay <dtolnay@gmail.com>
Sun, 26 Nov 2017 13:08:23 +0000 (05:08 -0800)
committerDavid Tolnay <dtolnay@gmail.com>
Sun, 26 Nov 2017 13:08:31 +0000 (05:08 -0800)
In main.rs libc is imported as:

    #[cfg(unix)]
    extern crate libc;

src/tools/compiletest/Cargo.toml

index d4d567e63c017748b2c606d02d50b0e2829e830a..6fc9423a4139a47ab6a54ae7cc51ab25d333a3e7 100644 (file)
@@ -10,6 +10,8 @@ filetime = "0.1"
 getopts = "0.2"
 log = "0.3"
 rustc-serialize = "0.3"
+
+[target.'cfg(unix)'.dependencies]
 libc = "0.2"
 
 [target.'cfg(windows)'.dependencies]