diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-03 13:40:32 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-03 13:40:32 +0000 |
commit | 86cc98ac45d2fe735c5103cb89040db0e159e1f5 (patch) | |
tree | b32ea97ff2eef869149f1750a0e6f55c9fcff65c /build.rs | |
parent | Releasing progress-linux version 1.0.81-1~progress7.99u1. (diff) | |
download | rust-proc-macro2-86cc98ac45d2fe735c5103cb89040db0e159e1f5.tar.xz rust-proc-macro2-86cc98ac45d2fe735c5103cb89040db0e159e1f5.zip |
Merging upstream version 1.0.85.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'build.rs')
-rw-r--r-- | build.rs | 19 |
1 files changed, 19 insertions, 0 deletions
@@ -34,6 +34,9 @@ // macro API and catching a panic if it isn't available. Enabled on Rust // 1.57+. +#![allow(unknown_lints)] +#![allow(unexpected_cfgs)] + use std::env; use std::ffi::OsString; use std::iter; @@ -44,6 +47,22 @@ use std::str; fn main() { let rustc = rustc_minor_version().unwrap_or(u32::MAX); + if rustc >= 80 { + println!("cargo:rustc-check-cfg=cfg(fuzzing)"); + println!("cargo:rustc-check-cfg=cfg(no_is_available)"); + println!("cargo:rustc-check-cfg=cfg(no_literal_byte_character)"); + println!("cargo:rustc-check-cfg=cfg(no_literal_c_string)"); + println!("cargo:rustc-check-cfg=cfg(no_source_text)"); + println!("cargo:rustc-check-cfg=cfg(proc_macro_span)"); + println!("cargo:rustc-check-cfg=cfg(procmacro2_backtrace)"); + println!("cargo:rustc-check-cfg=cfg(procmacro2_nightly_testing)"); + println!("cargo:rustc-check-cfg=cfg(procmacro2_semver_exempt)"); + println!("cargo:rustc-check-cfg=cfg(randomize_layout)"); + println!("cargo:rustc-check-cfg=cfg(span_locations)"); + println!("cargo:rustc-check-cfg=cfg(super_unstable)"); + println!("cargo:rustc-check-cfg=cfg(wrap_proc_macro)"); + } + let docs_rs = env::var_os("DOCS_RS").is_some(); let semver_exempt = cfg!(procmacro2_semver_exempt) || docs_rs; if semver_exempt { |