d-fix-rustix-outline
authorDebian Rust Maintainers <pkg-rust-maintainers@alioth-lists.debian.net>
Mon, 27 May 2024 11:28:20 +0000 (13:28 +0200)
committerFabian Grünbichler <debian@fabian.gruenbichler.email>
Mon, 27 May 2024 11:28:20 +0000 (13:28 +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.11/Cargo.toml
vendor/rustix-0.37.11/build.rs
vendor/rustix-0.37.20/Cargo.toml
vendor/rustix-0.37.20/build.rs
vendor/rustix/Cargo.toml
vendor/rustix/build.rs

index a0ea91d13c4cb644992ed48d9dc3a44529083020..a844f00cab09989ae2194c34d6a0b746cb76d8cf 100644 (file)
@@ -127,7 +127,6 @@ version = "3.4.0"
 
 [build-dependencies.cc]
 version = "1.0.68"
-optional = true
 
 [features]
 all-apis = [
index 47c76c77d685a699d794f2c7cfae8180c9e3665b..803e2d7c9529a0636d72d5eebd872c2bd6984f20 100644 (file)
@@ -1,4 +1,3 @@
-#[cfg(feature = "cc")]
 use cc::Build;
 use std::env::var;
 use std::io::Write;
@@ -161,16 +160,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
index 1a23dff466ba42388353fa53a47073b4104187db..ee01aac1182aac0a32c9f5c417349c17ecd87a76 100644 (file)
@@ -127,7 +127,6 @@ version = "3.4.0"
 
 [build-dependencies.cc]
 version = "1.0.68"
-optional = true
 
 [features]
 all-apis = [
index 320b3052beac1b3479dcd4cd28811196cb3fa2d1..c5464096f7e52101ca41bc6243c952af5e20c21a 100644 (file)
@@ -1,4 +1,3 @@
-#[cfg(feature = "cc")]
 use cc::Build;
 use std::env::var;
 use std::io::Write;
@@ -169,16 +168,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
index dd40b2507c11d7c6a0b9a234412540ea320aedc8..3b221a4fba9edd31143fcbc8c8c17b94b32e3bf2 100644 (file)
@@ -117,7 +117,6 @@ version = "3.5.0"
 
 [build-dependencies.cc]
 version = "1.0.68"
-optional = true
 
 [features]
 all-apis = [
index 26f306e58d5c2d7af5c7a33167950d7338ed630e..b85f0119834bd99ed2e71622e4a6f687a8120e45 100644 (file)
@@ -1,4 +1,3 @@
-#[cfg(feature = "cc")]
 use cc::Build;
 use std::env::var;
 use std::io::Write;
@@ -165,16 +164,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