d-fix-rustix-outline
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Thu, 30 May 2024 09:25:53 +0000 (11:25 +0200)
committerFabian Grünbichler <debian@fabian.gruenbichler.email>
Thu, 30 May 2024 09:25:53 +0000 (11:25 +0200)
Always enable cc even if the feature is not enabled.

Some Debian architectures need outline asm, and Debian does not ship pre-built
outline asm.

Gbp-Pq: Name d-fix-rustix-outline.patch

vendor/rustix-0.37.6/Cargo.toml
vendor/rustix-0.37.6/build.rs

index b560499a8cfe61e78e85991a907f72a7704bac3a..6029686a0f44261e2ed619545716871b7228ede1 100644 (file)
@@ -127,7 +127,6 @@ version = "3.4.0"
 
 [build-dependencies.cc]
 version = "1.0.68"
-optional = true
 
 [features]
 all-apis = [
index d8d1c8bd6e542c2a82631fba7e9b1471cb9139e9..39e857b79eab50f5caf7215580faa679ad2e7617 100644 (file)
@@ -1,4 +1,3 @@
-#[cfg(feature = "cc")]
 use cc::Build;
 use std::env::var;
 use std::io::Write;
@@ -158,16 +157,16 @@ fn link_in_librustix_outline(arch: &str, asm_name: &str) {
     println!("cargo:rerun-if-changed={}", to);
 
     // If "cc" is not enabled, use a pre-built library.
-    #[cfg(not(feature = "cc"))]
+    /*#[cfg(not(feature = "cc"))]
     {
         let _ = asm_name;
         println!("cargo:rustc-link-search={}/{}", OUTLINE_PATH, profile);
         println!("cargo:rustc-link-lib=static={}", name);
-    }
+    }*/
 
     // If "cc" is enabled, build the library from source, update the pre-built
     // version, and assert that the pre-built version is checked in.
-    #[cfg(feature = "cc")]
+    //#[cfg(feature = "cc")]
     {
         let out_dir = var("OUT_DIR").unwrap();
         // Add `-gdwarf-3` so that we always get the same output, regardless of