1
0
Fork 0

build library code as PIC

This commit is contained in:
edef 2014-12-23 06:38:45 +01:00
parent e9d6146b5b
commit 6125d4d6aa
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ fn main() {
if let Some(basename) = eat_extension(filename, ".c") { if let Some(basename) = eat_extension(filename, ".c") {
outpath = format!("{}/{}.o", out_dir, basename); outpath = format!("{}/{}.o", out_dir, basename);
Command::new("cc").args(&[filepath.as_slice(), "-c", "-o"]) Command::new("cc").args(&[filepath.as_slice(), "-c", "-fPIC", "-o"])
.arg(outpath.clone()) .arg(outpath.clone())
.status().unwrap(); .status().unwrap();
} }