try enabling linker-messages by default again#149937
try enabling linker-messages by default again#149937jyn514 wants to merge 5 commits intorust-lang:mainfrom
linker-messages by default again#149937Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
@bors try |
This comment has been minimized.
This comment has been minimized.
try enabling `linker-messages` by default again
This comment has been minimized.
This comment has been minimized.
|
@craterbot build-only |
|
🚨 Error: failed to parse the command 🆘 If you have any trouble with Crater please ask in t-infra on Zulip |
|
@craterbot run mode=build-only |
|
👌 Experiment ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
don't use no_main and no_core to test IBT The previous test was quite fragile and depended on a bunch of internal features. Simplify it. Split out of rust-lang#149937. cc `@jieyouxu` `@Oneirical`
don't use no_main and no_core to test IBT The previous test was quite fragile and depended on a bunch of internal features. Simplify it. Split out of rust-lang#149937. cc ``@jieyouxu`` ``@Oneirical``
don't use no_main and no_core to test IBT The previous test was quite fragile and depended on a bunch of internal features. Simplify it. Split out of rust-lang#149937. cc ```@jieyouxu``` ```@Oneirical```
|
☔ The latest upstream changes (presumably #149999) made this pull request unmergeable. Please resolve the merge conflicts. |
don't use no_main and no_core to test IBT The previous test was quite fragile and depended on a bunch of internal features. Simplify it. Split out of rust-lang/rust#149937. cc ```@jieyouxu``` ```@Oneirical```
|
🚧 Experiment ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more |
|
🎉 Experiment
Footnotes
|
|
@bors try jobs=dist-x86_64-llvm-mingw I have noticed recently that Clang doesn't handle The error: |
This comment has been minimized.
This comment has been minimized.
try enabling `linker-messages` by default again try-job: dist-x86_64-llvm-mingw
|
💔 Test for 75ce9fd failed: CI. Failed job:
|
This comment has been minimized.
This comment has been minimized.
… r=petrochenkov Do no add -no-pie on Windows Windows binaries are always position independent and Clang warns when trying to enable or disable that: ``` ❯ clang hello.c -pie clang: warning: argument unused during compilation: '-pie' [-Wunused-command-line-argument] ❯ clang hello.c -no-pie clang: warning: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument] ``` rust-lang#149937 will turn these warnings into build errors: ``` ❯ cargo rustc -- -D linker-messages Compiling hello v0.1.0 (E:\tmp\hello) error: linker stderr: x86_64-w64-mingw32-clang: argument unused during compilation: '-nolibc' [-Wunused-command-line-argument]␍ x86_64-w64-mingw32-clang: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument]␍ | = note: requested on the command line with `-D linker-messages` error: could not compile `hello` (bin "hello") due to 1 previous error ```
… r=petrochenkov Do no add -no-pie on Windows Windows binaries are always position independent and Clang warns when trying to enable or disable that: ``` ❯ clang hello.c -pie clang: warning: argument unused during compilation: '-pie' [-Wunused-command-line-argument] ❯ clang hello.c -no-pie clang: warning: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument] ``` rust-lang#149937 will turn these warnings into build errors: ``` ❯ cargo rustc -- -D linker-messages Compiling hello v0.1.0 (E:\tmp\hello) error: linker stderr: x86_64-w64-mingw32-clang: argument unused during compilation: '-nolibc' [-Wunused-command-line-argument]␍ x86_64-w64-mingw32-clang: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument]␍ | = note: requested on the command line with `-D linker-messages` error: could not compile `hello` (bin "hello") due to 1 previous error ```
… r=petrochenkov Do no add -no-pie on Windows Windows binaries are always position independent and Clang warns when trying to enable or disable that: ``` ❯ clang hello.c -pie clang: warning: argument unused during compilation: '-pie' [-Wunused-command-line-argument] ❯ clang hello.c -no-pie clang: warning: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument] ``` rust-lang#149937 will turn these warnings into build errors: ``` ❯ cargo rustc -- -D linker-messages Compiling hello v0.1.0 (E:\tmp\hello) error: linker stderr: x86_64-w64-mingw32-clang: argument unused during compilation: '-nolibc' [-Wunused-command-line-argument]␍ x86_64-w64-mingw32-clang: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument]␍ | = note: requested on the command line with `-D linker-messages` error: could not compile `hello` (bin "hello") due to 1 previous error ```
… r=petrochenkov Do no add -no-pie on Windows Windows binaries are always position independent and Clang warns when trying to enable or disable that: ``` ❯ clang hello.c -pie clang: warning: argument unused during compilation: '-pie' [-Wunused-command-line-argument] ❯ clang hello.c -no-pie clang: warning: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument] ``` rust-lang#149937 will turn these warnings into build errors: ``` ❯ cargo rustc -- -D linker-messages Compiling hello v0.1.0 (E:\tmp\hello) error: linker stderr: x86_64-w64-mingw32-clang: argument unused during compilation: '-nolibc' [-Wunused-command-line-argument]␍ x86_64-w64-mingw32-clang: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument]␍ | = note: requested on the command line with `-D linker-messages` error: could not compile `hello` (bin "hello") due to 1 previous error ```
Rollup merge of #152793 - mati865:disable-no-pie-on-windows, r=petrochenkov Do no add -no-pie on Windows Windows binaries are always position independent and Clang warns when trying to enable or disable that: ``` ❯ clang hello.c -pie clang: warning: argument unused during compilation: '-pie' [-Wunused-command-line-argument] ❯ clang hello.c -no-pie clang: warning: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument] ``` #149937 will turn these warnings into build errors: ``` ❯ cargo rustc -- -D linker-messages Compiling hello v0.1.0 (E:\tmp\hello) error: linker stderr: x86_64-w64-mingw32-clang: argument unused during compilation: '-nolibc' [-Wunused-command-line-argument]␍ x86_64-w64-mingw32-clang: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument]␍ | = note: requested on the command line with `-D linker-messages` error: could not compile `hello` (bin "hello") due to 1 previous error ```
- Hide common linker output behind `linker-info` - Add tests - Account for different capitalization on windows-gnu when removing "warning" prefix - Add some more comments - Add macOS deployment-target test - Ignore linker warnings from trying to statically link glibc I don't know what's going on in `nofile-limit.rs` but I want no part of it. - Use a fake linker so tests are platform-independent
It's an incomplete feature anyway, it's ok for it to be broken.
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
|
rebased this over #152793, the windows job should hopefully pass now. |
|
Perhaps I wasn't clear enough. There were two warnings with windows-gnullvm targets:
Point 1. will still need to be handled until Clang's fix is generally available (may take years) or we change how rustc links mingw-w64 libs for windows-gnullvm. |
…henkov Do no add -no-pie on Windows Windows binaries are always position independent and Clang warns when trying to enable or disable that: ``` ❯ clang hello.c -pie clang: warning: argument unused during compilation: '-pie' [-Wunused-command-line-argument] ❯ clang hello.c -no-pie clang: warning: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument] ``` rust-lang/rust#149937 will turn these warnings into build errors: ``` ❯ cargo rustc -- -D linker-messages Compiling hello v0.1.0 (E:\tmp\hello) error: linker stderr: x86_64-w64-mingw32-clang: argument unused during compilation: '-nolibc' [-Wunused-command-line-argument]␍ x86_64-w64-mingw32-clang: argument unused during compilation: '-no-pie' [-Wunused-command-line-argument]␍ | = note: requested on the command line with `-D linker-messages` error: could not compile `hello` (bin "hello") due to 1 previous error ```
|
☔ The latest upstream changes (presumably #152965) made this pull request unmergeable. Please resolve the merge conflicts. |
|
I think it might make sense to merge all the changes except for the Allow -> Warn bump, so we can avoid merge conflicts. |
|
Yeah, sounds fine. Can't tell how many bugs are there yet to be uncovered, |
View all comments
linker-infofromlinker-messageslinker-messageswarn-by-default; keeplinker-infodeny-by-defaultHelps with #136096.