Skip to content

Commit 8c8ff6a

Browse files
committed
test/linkage-visibility: Ignore on musl targets
DynamicLibrary uses libc's dlsym() function internally to find symbols. Some implementations of dlsym(), like musl's, only look at dynamically- exported symbols, as found in shared libraries. To also export symbols from the main executable, we would need to pass --export-dynamic to the linker. Since this flag isn't available everywhere, ignore the test for now.
1 parent 99e3fca commit 8c8ff6a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/test/run-pass-fulldeps/auxiliary/linkage-visibility.rs

+2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
// ignore-musl - dlsym doesn't see symbols without "-C link-arg=-Wl,--export-dynamic"
12+
1113
#![feature(rustc_private)]
1214

1315
// We're testing linkage visibility; the compiler warns us, but we want to

0 commit comments

Comments
 (0)