Skip to content

Commit

Permalink
RPATHの設定をした
Browse files Browse the repository at this point in the history
  • Loading branch information
qwerty2501 committed Jul 24, 2022
1 parent 8df0774 commit f285ebf
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions crates/voicevox_core/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@ __declspec(dllimport)
cbindgen::generate_with_config(&crate_dir, config)
.unwrap()
.write_to_file(&output_file);

#[cfg(target_os = "linux")]
println!("cargo:rustc-link-arg=-Wl,-rpath,$ORIGIN");

#[cfg(target_os = "macos")]
println!("cargo:rustc-link-arg=-Wl,-install_name,@rpath/libcore.dylib");
}
fn target_dir() -> PathBuf {
PathBuf::from(env::var("CARGO_WORKSPACE_DIR").unwrap()).join("target")
Expand Down

0 comments on commit f285ebf

Please sign in to comment.