mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-12 18:59:50 +03:00
Note: Change from `cargo:rustc-link-lib=<name>` to `cargo:rustc-link-lib=dylib=<name>` was not required, just to be consistent with the rest of the build.rs. Resolves #15127 (ffi tests are no longer broken on aarch64) Resolves #17030
29 lines
1.2 KiB
Diff
29 lines
1.2 KiB
Diff
From: Jakub Jirutka <jakub@jirutka.cz>
|
|
Date: Fri, 21 Jul 2023 13:24:48 +0200
|
|
Subject: [PATCH] Disable guess_os_stack_limit on musl
|
|
|
|
This is a workaround for some memory bug in deno. Without this patch,
|
|
the following tests fails on stack overflow:
|
|
|
|
- integration::node_unit_tests::_fs_chmod_test
|
|
- integration::node_unit_tests::_fs_read_test
|
|
- integration::node_unit_tests::_fs_readlink_test
|
|
- integration::node_unit_tests::_fs_stat_test
|
|
- integration::npm::esm_module
|
|
- integration::run::_045_proxy
|
|
|
|
See https://github.com/rust-lang/stacker/pull/51
|
|
|
|
diff --git a/src/lib.rs b/src/lib.rs
|
|
index 3c1d889..a75a361 100644
|
|
--- a/vendor/stacker/src/lib.rs
|
|
+++ b/vendor/stacker/src/lib.rs
|
|
@@ -414,7 +414,7 @@
|
|
);
|
|
Some(mi.assume_init().AllocationBase as usize + get_thread_stack_guarantee() + 0x1000)
|
|
}
|
|
- } else if #[cfg(any(target_os = "linux", target_os="solaris", target_os = "netbsd"))] {
|
|
+ } else if #[cfg(any(all(target_os = "linux", target_env = "gnu"), target_os="solaris", target_os = "netbsd"))] {
|
|
unsafe fn guess_os_stack_limit() -> Option<usize> {
|
|
let mut attr = std::mem::MaybeUninit::<libc::pthread_attr_t>::uninit();
|
|
assert_eq!(libc::pthread_attr_init(attr.as_mut_ptr()), 0);
|