Skip to content

Commit

Permalink
Merge pull request #1343 from AMS21/fix/bundled_build_with_multi_conf…
Browse files Browse the repository at this point in the history
…ig_ninja

Fix cmake build failure when using multi-config generators
  • Loading branch information
Cobrand authored Oct 24, 2023
2 parents 76748c5 + 919f1a6 commit 77c1eb4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sdl2-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,10 @@ fn compile_sdl2(sdl2_build_path: &Path, target_os: &str) -> PathBuf {
let mut cfg = cmake::Config::new(sdl2_build_path);
if let Ok(profile) = env::var("SDL2_BUILD_PROFILE") {
cfg.profile(&profile);
cfg.define("CMAKE_CONFIGURATION_TYPES", &profile);
} else {
cfg.profile("Release");
cfg.define("CMAKE_CONFIGURATION_TYPES", "Release");
}

// Allow specifying custom toolchain specifically for SDL2.
Expand Down

0 comments on commit 77c1eb4

Please sign in to comment.