Browse Source

Use -lctrud for debug builds

pull/10/head
Fenrir 8 years ago
parent
commit
22a855e41a
  1. 10
      ctru-rs/build.rs

10
ctru-rs/build.rs

@ -1,7 +1,11 @@
use std::env; use std::env;
use std::path::PathBuf;
fn main() { fn main() {
let dkp_path = PathBuf::from(env::var("DEVKITPRO").unwrap()); let dkp_path = env::var("DEVKITPRO").unwrap();
println!("cargo:rustc-link-search=native={}", dkp_path.join("libctru/lib").display());
println!("cargo:rustc-link-search=native={}/libctru/lib", dkp_path);
println!("cargo:rustc-link-lib=static={}", match env::var("PROFILE").unwrap().as_str() {
"debug" => "ctrud",
_ => "ctru",
});
} }

Loading…
Cancel
Save