mirror of
https://github.com/lifegpc/pixiv_downloader.git
synced 2026-06-06 05:49:01 +08:00
When build on windows with msvc, force use ninja
This commit is contained in:
8
build.rs
8
build.rs
@@ -35,7 +35,7 @@ fn main() {
|
||||
.define("ENABLE_CXX17", "ON")
|
||||
.define("INSTALL_DEP_FILES", "ON");
|
||||
#[cfg(all(windows, target_env = "msvc"))]
|
||||
config.define("CMAKE_BUILD_TYPE", "Release");
|
||||
config.define("CMAKE_BUILD_TYPE", "Release").generator("Ninja");
|
||||
config.build();
|
||||
let dep_path = out_path.join("utils_dep.txt");
|
||||
let mut f = File::open(dep_path).unwrap();
|
||||
@@ -68,7 +68,7 @@ fn main() {
|
||||
config.define("CMAKE_INSTALL_PREFIX", out_path.to_str().unwrap())
|
||||
.out_dir(avdict_build_path);
|
||||
#[cfg(all(windows, target_env = "msvc"))]
|
||||
config.define("CMAKE_BUILD_TYPE", "Release");
|
||||
config.define("CMAKE_BUILD_TYPE", "Release").generator("Ninja");
|
||||
config.build();
|
||||
println!("cargo:rustc-link-search=native={}/lib", out_path.display());
|
||||
let dep_path = out_path.join("avdict_dep.txt");
|
||||
@@ -117,7 +117,7 @@ fn main() {
|
||||
.out_dir(exif_build_path)
|
||||
.define("UTILS_LIBRARY", utils_build_path.to_str().unwrap());
|
||||
#[cfg(all(windows, target_env = "msvc"))]
|
||||
config.define("CMAKE_BUILD_TYPE", "Release");
|
||||
config.define("CMAKE_BUILD_TYPE", "Release").generator("Ninja");
|
||||
config.build();
|
||||
println!("cargo:rustc-link-search=native={}/lib", out_path.display());
|
||||
let dep_path = out_path.join("exif_dep.txt");
|
||||
@@ -167,7 +167,7 @@ fn main() {
|
||||
.out_dir(ugoira_build_path)
|
||||
.define("UTILS_LIBRARY", utils_build_path.to_str().unwrap());
|
||||
#[cfg(all(windows, target_env = "msvc"))]
|
||||
config.define("CMAKE_BUILD_TYPE", "Release");
|
||||
config.define("CMAKE_BUILD_TYPE", "Release").generator("Ninja");
|
||||
config.build();
|
||||
println!("cargo:rustc-link-search=native={}/lib", out_path.display());
|
||||
let dep_path = out_path.join("ugoira_dep.txt");
|
||||
|
||||
Reference in New Issue
Block a user