Skip to content

Commit

Permalink
Avoid redefinition when vars are duplicated
Browse files Browse the repository at this point in the history
  • Loading branch information
kornelski authored and tilpner committed May 24, 2023
1 parent 4ae8679 commit a712864
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -348,12 +348,14 @@ fn check_features(
}
includes_code.push_str(&format!(
r#"
#ifndef {var}_is_defined
#ifndef {var}
#define {var} 0
#define {var}_is_defined 0
#else
#define {var}_is_defined 1
#endif
#endif
"#,
var = var
));
Expand Down

0 comments on commit a712864

Please sign in to comment.