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

Unable to link mingw64 + rust nightly undefined reference to `__imp___acrt_iob_func' #59604

Closed
norru opened this issue Apr 1, 2019 · 2 comments

Comments

@norru
Copy link

norru commented Apr 1, 2019

I am trying to compile https://github.com/vulkano-rs/vulkano on nightly.

OS: Windows 10 + mingw64, pacman -Syu to latest mingw64 from MSYS2
Toolchain: nightly-x86_64-pc-windows-gnu
rustc 1.35.0-nightly (bc44841ad 2019-03-14)

MINGW64 /f/Projects/3rdParty/vulkano
$ cargo build
   Compiling vulkano-shaders v0.11.1 (F:\Projects\3rdParty\vulkano\vulkano-shaders)
error: linking with `gcc` failed: exit code: 1
  |
  = note: "gcc" "-Wl,--enable-long-section-names" "-fno-use-linker-plugin" "-Wl,--nxcompat" "-nostdlib" "-m64" 

[...snip...]

  = note: F:\Projects\3rdParty\vulkano\target\debug\deps\libshaderc-f274fa1b371f550d.rlib(ShaderLang.cpp.obj):ShaderLang.cpp:(.text$_ZL6printfPKcz+0x29): undefined reference to `__imp___acrt_iob_func'
          F:\Projects\3rdParty\vulkano\target\debug\deps\libshaderc-f274fa1b371f550d.rlib(ossource.cpp.obj):ossource.cpp:(.text$_Z6printfPKcz[_Z6printfPKcz]+0x29): undefined reference to `__imp___acrt_iob_func'
          F:\Projects\3rdParty\vulkano\target\debug\deps\libshaderc-f274fa1b371f550d.rlib(glslang_tab.cpp.obj):glslang_tab.cpp:(.text$_ZL14yy_stack_printPsS_+0xd): undefined reference to `__imp___acrt_iob_func'
          F:\Projects\3rdParty\vulkano\target\debug\deps\libshaderc-f274fa1b371f550d.rlib(glslang_tab.cpp.obj):glslang_tab.cpp:(.text$_ZL10yydestructPKciP7YYSTYPEPN7glslang13TParseContextE.isra.13+0x23): undefinedference to `__imp___acrt_iob_func'
          F:\Projects\3rdParty\vulkano\target\debug\deps\libshaderc-f274fa1b371f550d.rlib(glslang_tab.cpp.obj):glslang_tab.cpp:(.text$_Z7yyparsePN7glslang13TParseContextE+0x8cc): undefined reference to `__imp___aciob_func'
          F:\Projects\3rdParty\vulkano\target\debug\deps\libshaderc-f274fa1b371f550d.rlib(glslang_tab.cpp.obj):glslang_tab.cpp:(.text$_Z7yyparsePN7glslang13TParseContextE+0x90a): more undefined references to `__im_acrt_iob_func' follow


error: aborting due to previous error

error: Could not compile `vulkano-shaders`.

To learn more, run the command again with --verbose.

Building on stable succeeds but I need nightly for development. Building on stable-*-msvc works.

@jonas-schievink
Copy link
Contributor

The Vulkano readme states:

windows-gnu toolchain is not supported but you can instead cross-compile to windows-gnu from windows-msvc

so this looks like a user error to me, even if it did happen to work in the past?

@norru
Copy link
Author

norru commented Apr 1, 2019

Ah right, I missed that bit. Thanks.

@norru norru closed this as completed Apr 1, 2019
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
Chris00 added a commit to Chris00/rust-crlibm that referenced this issue Dec 20, 2021
These targets are not supported by the Rust language.
See rust-lang/rust#59604
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