File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -167,11 +167,19 @@ fn main() {
167
167
// https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#check-cfg
168
168
if libc_check_cfg {
169
169
for cfg in ALLOWED_CFGS {
170
- println ! ( "cargo:rustc-check-cfg=values({})" , cfg) ;
170
+ if rustc_minor_ver >= 75 {
171
+ println ! ( "cargo:rustc-check-cfg=cfg({})" , cfg) ;
172
+ } else {
173
+ println ! ( "cargo:rustc-check-cfg=values({})" , cfg) ;
174
+ }
171
175
}
172
176
for & ( name, values) in CHECK_CFG_EXTRA {
173
177
let values = values. join ( "\" ,\" " ) ;
174
- println ! ( "cargo:rustc-check-cfg=values({},\" {}\" )" , name, values) ;
178
+ if rustc_minor_ver >= 75 {
179
+ println ! ( "cargo:rustc-check-cfg=cfg({},values(\" {}\" ))" , name, values) ;
180
+ } else {
181
+ println ! ( "cargo:rustc-check-cfg=values({},\" {}\" )" , name, values) ;
182
+ }
175
183
}
176
184
}
177
185
}
You can’t perform that action at this time.
0 commit comments