use --dynamic-list for exporting executable symbols#143446
Merged
bors merged 1 commit intorust-lang:masterfrom Jul 10, 2025
Merged
use --dynamic-list for exporting executable symbols#143446bors merged 1 commit intorust-lang:masterfrom
--dynamic-list for exporting executable symbols#143446bors merged 1 commit intorust-lang:masterfrom
Conversation
Collaborator
Collaborator
|
Some changes occurred in compiler/rustc_codegen_ssa |
bjorn3
reviewed
Jul 4, 2025
a18772a to
63d952e
Compare
oli-obk
reviewed
Jul 8, 2025
oli-obk
reviewed
Jul 8, 2025
oli-obk
reviewed
Jul 8, 2025
63d952e to
abf1ccc
Compare
Contributor
|
@bors r+ rollup |
Collaborator
bjorn3
reviewed
Jul 8, 2025
Contributor
|
@bors r- |
abf1ccc to
ea6a131
Compare
Contributor
Author
|
@rustbot ready |
bjorn3
reviewed
Jul 9, 2025
ea6a131 to
6fe2ad8
Compare
Member
|
@bors r=bjorn3,oli-obk |
Collaborator
Kobzol
added a commit
to Kobzol/rust
that referenced
this pull request
Jul 9, 2025
…r=bjorn3,oli-obk use `--dynamic-list` for exporting executable symbols closes rust-lang#101610 cc rust-lang#84161 https://sourceware.org/binutils/docs-2.39/ld/VERSION.html: > --dynamic-list=dynamic-list-file Specify the name of a dynamic list file to the linker. This is typically used when creating shared libraries to specify a list of global symbols whose references shouldn’t be bound to the definition within the shared library, or creating dynamically linked executables to specify a list of symbols which should be added to the symbol table in the executable. This option is only meaningful on ELF platforms which support shared libraries. `ld.lld --help`: > --dynamic-list=<file>: Similar to --export-dynamic-symbol-list. When creating a shared object, this additionally implies -Bsymbolic but does not set DF_SYMBOLIC > --export-dynamic-symbol-list=file: Read a list of dynamic symbol patterns. Apply --export-dynamic-symbol on each pattern > --export-dynamic-symbol=glob: (executable) Put matched symbols in the dynamic symbol table. (shared object) References to matched non-local STV_DEFAULT symbols shouldn't be bound to definitions within the shared object. Does not imply -Bsymbolic. > --export-dynamic: Put symbols in the dynamic symbol table Use `--dynamic-list` because it's older than `--export-dynamic-symbol-list` (binutils 2.35)
bors
added a commit
that referenced
this pull request
Jul 9, 2025
Rollup of 6 pull requests Successful merges: - #143398 (tidy: add support for `--extra-checks=auto:` feature) - #143446 (use `--dynamic-list` for exporting executable symbols) - #143644 (Add triagebot stdarch mention ping) - #143660 (Disable docs for `compiler-builtins` and `sysroot`) - #143666 (Re-expose nested bodies in rustc_borrowck::consumers) - #143668 (Fix VxWorks build errors) r? `@ghost` `@rustbot` modify labels: rollup
Member
|
Probably failed in #143676 (comment). @bors r- |
bjorn3
reviewed
Jul 9, 2025
| fn main() { | ||
| unsafe { | ||
| let handle = libc::dlopen(std::ptr::null(), libc::RTLD_NOW); | ||
| let ptr = libc::dlsym(handle, c"hack".as_ptr()); |
Member
There was a problem hiding this comment.
dlsym doesn't work for statically linked musl. This either needs -Ctarget-feature=-crt-static on musl or to exclude musl entirely.
6fe2ad8 to
bf6d29d
Compare
Contributor
Author
|
@rustbot ready |
Member
|
@bors r=bjorn3,oli-obk |
Collaborator
bors
added a commit
that referenced
this pull request
Jul 10, 2025
Rollup of 9 pull requests Successful merges: - #143446 (use `--dynamic-list` for exporting executable symbols) - #143590 (Fix weird rustdoc output when single and glob reexport conflict on a name) - #143599 (emit `.att_syntax` when global/naked asm use that option) - #143615 (Fix handling of no_std targets in `doc::Std` step) - #143632 (fix: correct parameter names in LLVMRustBuildMinNum and LLVMRustBuildMaxNum FFI declarations) - #143640 (Constify `Fn*` traits) - #143651 (Win: Use exceptions with empty data for SEH panic exception copies instead of a new panic) - #143660 (Disable docs for `compiler-builtins` and `sysroot`) - #143665 ([rustdoc-json] Add tests for `#[doc(hidden)]` handling of items.) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
that referenced
this pull request
Jul 10, 2025
Rollup merge of #143446 - usamoi:export-executable-symbols, r=bjorn3,oli-obk use `--dynamic-list` for exporting executable symbols closes #101610 cc #84161 https://sourceware.org/binutils/docs-2.39/ld/VERSION.html: > --dynamic-list=dynamic-list-file Specify the name of a dynamic list file to the linker. This is typically used when creating shared libraries to specify a list of global symbols whose references shouldn’t be bound to the definition within the shared library, or creating dynamically linked executables to specify a list of symbols which should be added to the symbol table in the executable. This option is only meaningful on ELF platforms which support shared libraries. `ld.lld --help`: > --dynamic-list=<file>: Similar to --export-dynamic-symbol-list. When creating a shared object, this additionally implies -Bsymbolic but does not set DF_SYMBOLIC > --export-dynamic-symbol-list=file: Read a list of dynamic symbol patterns. Apply --export-dynamic-symbol on each pattern > --export-dynamic-symbol=glob: (executable) Put matched symbols in the dynamic symbol table. (shared object) References to matched non-local STV_DEFAULT symbols shouldn't be bound to definitions within the shared object. Does not imply -Bsymbolic. > --export-dynamic: Put symbols in the dynamic symbol table Use `--dynamic-list` because it's older than `--export-dynamic-symbol-list` (binutils 2.35) try-job: dist-i586-gnu-i586-i686-musl
github-actions bot
pushed a commit
to rust-lang/rustc-dev-guide
that referenced
this pull request
Jul 11, 2025
Rollup of 9 pull requests Successful merges: - rust-lang/rust#143446 (use `--dynamic-list` for exporting executable symbols) - rust-lang/rust#143590 (Fix weird rustdoc output when single and glob reexport conflict on a name) - rust-lang/rust#143599 (emit `.att_syntax` when global/naked asm use that option) - rust-lang/rust#143615 (Fix handling of no_std targets in `doc::Std` step) - rust-lang/rust#143632 (fix: correct parameter names in LLVMRustBuildMinNum and LLVMRustBuildMaxNum FFI declarations) - rust-lang/rust#143640 (Constify `Fn*` traits) - rust-lang/rust#143651 (Win: Use exceptions with empty data for SEH panic exception copies instead of a new panic) - rust-lang/rust#143660 (Disable docs for `compiler-builtins` and `sysroot`) - rust-lang/rust#143665 ([rustdoc-json] Add tests for `#[doc(hidden)]` handling of items.) r? `@ghost` `@rustbot` modify labels: rollup
github-actions bot
pushed a commit
to rust-lang/compiler-builtins
that referenced
this pull request
Jul 12, 2025
Rollup of 9 pull requests Successful merges: - rust-lang/rust#143446 (use `--dynamic-list` for exporting executable symbols) - rust-lang/rust#143590 (Fix weird rustdoc output when single and glob reexport conflict on a name) - rust-lang/rust#143599 (emit `.att_syntax` when global/naked asm use that option) - rust-lang/rust#143615 (Fix handling of no_std targets in `doc::Std` step) - rust-lang/rust#143632 (fix: correct parameter names in LLVMRustBuildMinNum and LLVMRustBuildMaxNum FFI declarations) - rust-lang/rust#143640 (Constify `Fn*` traits) - rust-lang/rust#143651 (Win: Use exceptions with empty data for SEH panic exception copies instead of a new panic) - rust-lang/rust#143660 (Disable docs for `compiler-builtins` and `sysroot`) - rust-lang/rust#143665 ([rustdoc-json] Add tests for `#[doc(hidden)]` handling of items.) r? `@ghost` `@rustbot` modify labels: rollup
tgross35
pushed a commit
to rust-lang/compiler-builtins
that referenced
this pull request
Jan 31, 2026
Rollup of 9 pull requests Successful merges: - rust-lang/rust#143446 (use `--dynamic-list` for exporting executable symbols) - rust-lang/rust#143590 (Fix weird rustdoc output when single and glob reexport conflict on a name) - rust-lang/rust#143599 (emit `.att_syntax` when global/naked asm use that option) - rust-lang/rust#143615 (Fix handling of no_std targets in `doc::Std` step) - rust-lang/rust#143632 (fix: correct parameter names in LLVMRustBuildMinNum and LLVMRustBuildMaxNum FFI declarations) - rust-lang/rust#143640 (Constify `Fn*` traits) - rust-lang/rust#143651 (Win: Use exceptions with empty data for SEH panic exception copies instead of a new panic) - rust-lang/rust#143660 (Disable docs for `compiler-builtins` and `sysroot`) - rust-lang/rust#143665 ([rustdoc-json] Add tests for `#[doc(hidden)]` handling of items.) r? `@ghost` `@rustbot` modify labels: rollup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
closes #101610
cc #84161
https://sourceware.org/binutils/docs-2.39/ld/VERSION.html:
ld.lld --help:Use
--dynamic-listbecause it's older than--export-dynamic-symbol-list(binutils 2.35)try-job: dist-i586-gnu-i586-i686-musl