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

[fmt, spdlog] "/utf8 error"build failure #42132

Open
ysyecust opened this issue Nov 13, 2024 · 8 comments · May be fixed by #42211
Open

[fmt, spdlog] "/utf8 error"build failure #42132

ysyecust opened this issue Nov 13, 2024 · 8 comments · May be fixed by #42211
Labels
category:community-triplet A PR or issue related to community triplets not officially validated by the vcpkg team. category:port-bug The issue is with a library, which is something the port should already support

Comments

@ysyecust
Copy link

Operating system

Windows

Compiler

Clang

Steps to reproduce the behavior

like https://github.com/microsoft/vcpkg/issues/40214 
when I use spdlog v1.14.1 it works, but when I upgrade spdlog to v1.15.0, it still have the "\utf8" error

Failure logs

[build] C:\PROGRA~1\LLVM\bin\CLANG_~1.EXE -DFMT_SHARED -DSPDLOG_COMPILED_LIB -DSPDLOG_FMT_EXTERNAL -DSPDLOG_SHARED_LIB -IC:/Users/YSY_e/Documents/simona2/build -IC:/Users/YSY_e/Documents/simona2/simona2/loger/include -isystem C:/vcpkg/installed/x64-windows/include -O3 -DNDEBUG -std=c++20 -D_DLL -D_MT -Xclang --dependent-lib=msvcrt -Wall -Wextra -Weffc++ -Werror=uninitialized -Werror=return-type -Wconversion -Wsign-compare -Werror=unused-result -Werror=suggest-override -Wzero-as-null-pointer-constant -Wmissing-declarations -Wold-style-cast -Wnon-virtual-dtor -Werror -finput-charset=UTF-8 /utf-8 -MD -MT simona2/loger/CMakeFiles/Logger.dir/src/logger.cpp.obj -MF simona2\loger\CMakeFiles\Logger.dir\src\logger.cpp.obj.d -o simona2/loger/CMakeFiles/Logger.dir/src/logger.cpp.obj -c C:/Users/YSY_e/Documents/simona2/simona2/loger/src/logger.cpp
[build] clang++: error: no such file or directory: '/utf-8'

Additional context

No response

@ysyecust ysyecust added the category:port-bug The issue is with a library, which is something the port should already support label Nov 13, 2024
@WangWeiLin-MV WangWeiLin-MV self-assigned this Nov 13, 2024
@WangWeiLin-MV WangWeiLin-MV added the category:community-triplet A PR or issue related to community triplets not officially validated by the vcpkg team. label Nov 13, 2024
@WangWeiLin-MV WangWeiLin-MV removed their assignment Nov 13, 2024
@WangWeiLin-MV
Copy link
Contributor

Build passed with vcpkg install spdlog:x64-mingw-dynamic

@ysyecust
Copy link
Author

Build passed with vcpkg install spdlog:x64-mingw-dynamic

It didn't solve the problem, still got the /utf8 error

[proc] Executing command: "C:\Program Files\CMake\bin\cmake.EXE" --build c:/Users/YSY_e/Documents/code/simona2/build --config Debug --target Logger --
[build] [1/2   0% :: 0.004] Re-checking globbed directories...
[build] [1/2  50% :: 0.048] Building CXX object simona2/loger/CMakeFiles/Logger.dir/src/logger.cpp.obj
[build] FAILED: simona2/loger/CMakeFiles/Logger.dir/src/logger.cpp.obj 
[build] C:\PROGRA~1\LLVM\bin\CLANG_~1.EXE -DFMT_SHARED -DSPDLOG_COMPILED_LIB -DSPDLOG_FMT_EXTERNAL -DSPDLOG_SHARED_LIB -IC:/Users/YSY_e/Documents/code/simona2/build -IC:/Users/YSY_e/Documents/code/simona2/simona2/loger/include -isystem C:/vcpkg/installed/x64-windows/include -O0 -g -Xclang -gcodeview -std=c++20 -D_DEBUG -D_DLL -D_MT -Xclang --dependent-lib=msvcrtd -Wall -Wextra -Weffc++ -Werror=uninitialized -Werror=return-type -Wconversion -Wsign-compare -Werror=unused-result -Werror=suggest-override -Wzero-as-null-pointer-constant -Wmissing-declarations -Wold-style-cast -Wnon-virtual-dtor -Werror -finput-charset=UTF-8 /utf-8 -MD -MT simona2/loger/CMakeFiles/Logger.dir/src/logger.cpp.obj -MF simona2\loger\CMakeFiles\Logger.dir\src\logger.cpp.obj.d -o simona2/loger/CMakeFiles/Logger.dir/src/logger.cpp.obj -c C:/Users/YSY_e/Documents/code/simona2/simona2/loger/src/logger.cpp
[build] clang++: error: no such file or directory: '/utf-8'
[build] ninja: build stopped: subcommand failed.
[proc] The command: "C:\Program Files\CMake\bin\cmake.EXE" --build c:/Users/YSY_e/Documents/code/simona2/build --config Debug --target Logger -- exited with code: 1
[driver] Build completed: 00:00:00.090
[build] Build finished with exit code 1

@dg0yt
Copy link
Contributor

dg0yt commented Nov 13, 2024

Build passed with vcpkg install spdlog:x64-mingw-dynamic

gcc or clang?

@dg0yt
Copy link
Contributor

dg0yt commented Nov 13, 2024

-isystem C:/vcpkg/installed/x64-windows/include

This error is for triplet x64-windows which is a triplet for MSVC.

@WangWeiLin-MV
Copy link
Contributor

Build passed with vcpkg install spdlog:x64-mingw-dynamic

gcc or clang?

With gcc

@hghgthifg
Copy link

I have encountered the same problem. When I tried to use clang-cl instead, another problem arised.
cl.exe works well, but that's not what I expected. I want to use clang.

@dg0yt
Copy link
Contributor

dg0yt commented Nov 13, 2024

AFAICT there is no triplet here for non-mingw Windows clang, regardless of frontend.

@ysyecust
Copy link
Author

Is there a plan to fix this issue, my current solution is to switch to 77dfbee: [spdlog] update to 1.15.0 (#42076) before this commit

@miyanyan miyanyan linked a pull request Nov 18, 2024 that will close this issue
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:community-triplet A PR or issue related to community triplets not officially validated by the vcpkg team. category:port-bug The issue is with a library, which is something the port should already support
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants