-
-
Notifications
You must be signed in to change notification settings - Fork 42
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
Target std=gnu++14 rather than std=c++14 on Windows systems #112
Comments
Thanks for reporting the issue! We do run CI against both |
Additionally - I can build this successfully with my |
Anybody have any more info on this? Running into it myself now |
Still have this bug under Cygwin. |
If possible I'd recommend using MSVC for spirv_cross on Windows for now. I've hit some more issues with MSYS2/MinGW/Cygwin recently which sometimes need workarounds like rust-lang/rust#47048 (comment) |
The spirv_cross
build.rs
sets the c++ compiler to use the c++14 standard. On POSIX systems this is fine, because those systems will simply implicitly include the POSIX standard as well. This is not the case on Windows while using GCC, however - it uses the strict c++14 standard. This does not include some key functions used byspirv_cross
, namelystrdup
. Attempting to build a crate with spirv-cross as a dependency on x64 Windows 10 with GCC 9.10 results in the following laundry list of errors:I do not have time at the moment to test, but I believe this can be fixed by telling the compiler to use
std=gnu++11
. This will include the relevant POSIX standard headers to enablestrdup
and friends to compile correctly. I will test this when I have time and respond back in this issue if I test a solution that works.The text was updated successfully, but these errors were encountered: