From aa64d080e8f8d7582bbdb18b373cc94187012b3c Mon Sep 17 00:00:00 2001 From: liebman Date: Fri, 13 Sep 2024 11:14:48 -0700 Subject: [PATCH] don't set clang target as its already handled in bindgen by default --- CHANGELOG.md | 4 ++++ build.rs | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 97e0200..37be451 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Fixed + +- Fix build script for platforms where the Rust target is not equal to the clang target ([#16](https://github.com/trussed-dev/littlefs2-sys/pull/16)) + ## [0.2.0] - 2024-05-28 ### Added diff --git a/build.rs b/build.rs index abd80f4..d8ddea2 100644 --- a/build.rs +++ b/build.rs @@ -3,7 +3,6 @@ use std::path::PathBuf; fn main() -> Result<(), Box> { let mut builder = cc::Build::new(); - let target = env::var("TARGET")?; let builder = builder .flag("-std=c11") .flag("-DLFS_NO_DEBUG") @@ -29,7 +28,6 @@ fn main() -> Result<(), Box> { let bindings = bindgen::Builder::default() .header("littlefs/lfs.h") - .clang_arg(format!("--target={}", target)) .use_core() .allowlist_item("lfs_.*") .allowlist_item("LFS_.*")