Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors using -flto with clang #173

Open
MagicalDrizzle opened this issue Oct 21, 2023 · 2 comments
Open

Errors using -flto with clang #173

MagicalDrizzle opened this issue Oct 21, 2023 · 2 comments

Comments

@MagicalDrizzle
Copy link

It seems this toolchain has the same problem with -flto as this one in the llvm-mingw repo: mstorsjo/llvm-mingw#12
clang: error: 'x86_64-w64-windows-gnu': unable to pass LLVM bit-code files to linker
The problem is the exact same and the solutions offered works for me, so I believe your problem is the same as in that link.

@brechtsanders
Copy link
Owner

The ticket you refer to is 5 years old. Which winlibs release were you using?

@MagicalDrizzle
Copy link
Author

MagicalDrizzle commented Oct 21, 2023

F:\build\mingw64\bin>clang "F:\build\home\clolcat.c" -flto
clang: error: 'x86_64-w64-windows-gnu': unable to pass LLVM bit-code files to linker

F:\build\mingw64\bin>clang "F:\build\home\clolcat.c" -flto -fuse-ld=lld

F:\build\mingw64\bin>cat ..\version_info.txt
winlibs personal build version gcc-13.2.0-llvm-16.0.6-mingw-w64msvcrt-11.0.1-r1

This is the winlibs Intel/AMD 64-bit standalone build of:
- GCC 13.2.0
- GDB 13.2
- LLVM/Clang/LLD/LLDB 16.0.6
- MinGW-w64 11.0.1 (linked with msvcrt)
- GNU Binutils 2.41
- GNU Make 4.4.1
- PExports 0.47
- dos2unix 7.5.0
- Yasm 1.3.0
- NASM 2.16.01
- JWasm 2.12pre
- ccache version 4.8.2
- CMake 3.27.1
- ninja 1.11.1.git.kitware.jobserver-1
- Doxygen 1.9.7

Thread model: posix
Runtime library: MSVCRT

This build was compiled with GCC 13.2.0 and packaged on 2023-08-09.

Please check out http://winlibs.com/ for the latest personal build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants