aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--embassy-stm32/build.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/embassy-stm32/build.rs b/embassy-stm32/build.rs
index d92d92174..2011fd17d 100644
--- a/embassy-stm32/build.rs
+++ b/embassy-stm32/build.rs
@@ -1376,6 +1376,15 @@ fn main() {
1376 println!("cargo:rustc-cfg=flashsize_{}", &chip_name[10..11]); 1376 println!("cargo:rustc-cfg=flashsize_{}", &chip_name[10..11]);
1377 } 1377 }
1378 1378
1379 // Mark the L4+ chips as they have many differences to regular L4.
1380 if &chip_name[..7] == "stm32l4" {
1381 if "pqrs".contains(&chip_name[7..8]) {
1382 println!("cargo:rustc-cfg=stm32l4_plus");
1383 } else {
1384 println!("cargo:rustc-cfg=stm32l4_nonplus");
1385 }
1386 }
1387
1379 println!("cargo:rerun-if-changed=build.rs"); 1388 println!("cargo:rerun-if-changed=build.rs");
1380} 1389}
1381 1390