Skip to content

Commit

Permalink
Add pkg-config as fallback for MagickCore-config
Browse files Browse the repository at this point in the history
Fixes #131
  • Loading branch information
Des-Nerger committed Aug 26, 2024
1 parent b0f5154 commit b92bed0
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,14 @@ fn main() {
.arg("--cppflags")
.output()
} else {
Command::new("MagickCore-config").arg("--cppflags").output()
Command::new("MagickCore-config")
.arg("--cppflags")
.output()
.or_else(|_| {
Command::new("pkg-config")
.args(["--cflags", "MagickCore"])
.output()
})
};
if let Ok(ok_cppflags) = check_cppflags {
let cppflags = ok_cppflags.stdout;
Expand Down

0 comments on commit b92bed0

Please sign in to comment.