@@ -351,11 +351,11 @@ fn link_sdl2(target_os: &str) {
351
351
// -lSDL2_mixer can find it.
352
352
#[ cfg( all( not( feature = "use-pkgconfig" ) , not( feature = "static-link" ) ) ) ] {
353
353
if cfg ! ( feature = "mixer" ) {
354
- if cfg ! ( any ( target_os= "linux" , target_os= "freebsd" , target_os= "openbsd" ) ) {
354
+ if target_os. contains ( "linux" ) || target_os. contains ( "freebsd" ) || target_os. contains ( "openbsd" ) {
355
355
println ! ( "cargo:rustc-flags=-l SDL2_mixer" ) ;
356
- } else if cfg ! ( target_os= "windows" ) {
356
+ } else if target_os. contains ( "windows" ) {
357
357
println ! ( "cargo:rustc-flags=-l SDL2_mixer" ) ;
358
- } else if cfg ! ( target_os= "macos ") {
358
+ } else if target_os. contains ( "darwin ") {
359
359
if cfg ! ( any( mac_framework, feature="use_mac_framework" ) ) {
360
360
println ! ( "cargo:rustc-flags=-l framework=SDL2_mixer" ) ;
361
361
} else {
@@ -364,11 +364,11 @@ fn link_sdl2(target_os: &str) {
364
364
}
365
365
}
366
366
if cfg ! ( feature = "image" ) {
367
- if cfg ! ( any ( target_os= "linux" , target_os= "freebsd" , target_os= "openbsd" ) ) {
367
+ if target_os. contains ( "linux" ) || target_os. contains ( "freebsd" ) || target_os. contains ( "openbsd" ) {
368
368
println ! ( "cargo:rustc-flags=-l SDL2_image" ) ;
369
- } else if cfg ! ( target_os= "windows" ) {
369
+ } else if target_os. contains ( "windows" ) {
370
370
println ! ( "cargo:rustc-flags=-l SDL2_image" ) ;
371
- } else if cfg ! ( target_os= "macos ") {
371
+ } else if target_os. contains ( "darwin ") {
372
372
if cfg ! ( any( mac_framework, feature="use_mac_framework" ) ) {
373
373
println ! ( "cargo:rustc-flags=-l framework=SDL2_image" ) ;
374
374
} else {
@@ -377,11 +377,11 @@ fn link_sdl2(target_os: &str) {
377
377
}
378
378
}
379
379
if cfg ! ( feature = "ttf" ) {
380
- if cfg ! ( any ( target_os= "linux" , target_os= "freebsd" , target_os= "openbsd" ) ) {
380
+ if target_os. contains ( "linux" ) || target_os. contains ( "freebsd" ) || target_os. contains ( "openbsd" ) {
381
381
println ! ( "cargo:rustc-flags=-l SDL2_ttf" ) ;
382
- } else if cfg ! ( target_os= "windows" ) {
382
+ } else if target_os. contains ( "windows" ) {
383
383
println ! ( "cargo:rustc-flags=-l SDL2_ttf" ) ;
384
- } else if cfg ! ( target_os= "macos ") {
384
+ } else if target_os. contains ( "darwin ") {
385
385
if cfg ! ( any( mac_framework, feature="use_mac_framework" ) ) {
386
386
println ! ( "cargo:rustc-flags=-l framework=SDL2_ttf" ) ;
387
387
} else {
@@ -390,11 +390,11 @@ fn link_sdl2(target_os: &str) {
390
390
}
391
391
}
392
392
if cfg ! ( feature = "gfx" ) {
393
- if cfg ! ( any ( target_os= "linux" , target_os= "freebsd" , target_os= "openbsd" ) ) {
393
+ if target_os. contains ( "linux" ) || target_os. contains ( "freebsd" ) || target_os. contains ( "openbsd" ) {
394
394
println ! ( "cargo:rustc-flags=-l SDL2_gfx" ) ;
395
- } else if cfg ! ( target_os= "windows" ) {
395
+ } else if target_os. contains ( "windows" ) {
396
396
println ! ( "cargo:rustc-flags=-l SDL2_gfx" ) ;
397
- } else if cfg ! ( target_os= "macos ") {
397
+ } else if target_os. contains ( "darwin ") {
398
398
if cfg ! ( any( mac_framework, feature="use_mac_framework" ) ) {
399
399
println ! ( "cargo:rustc-flags=-l framework=SDL2_gfx" ) ;
400
400
} else {
0 commit comments