[spdlog] Fix non-Windows builds with wchar feature enabled (#27740)

- Defining SPDLOG_WCHAR_TO_UTF8_SUPPORT on non-Windows platforms
  triggers an #error, restrict the wchar feature to Windows
- update port-version + vcpkg x-add-version spdlog
This commit is contained in:
Romain Pokrzywka 2022-11-14 17:27:02 -06:00 committed by GitHub
parent 6fe2b934fd
commit c58ae39a72
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 10 additions and 4 deletions

View File

@ -50,7 +50,7 @@ vcpkg_replace_string(${CURRENT_PACKAGES_DIR}/include/spdlog/tweakme.h
"// #define SPDLOG_FMT_EXTERNAL"
"#ifndef SPDLOG_FMT_EXTERNAL\n#define SPDLOG_FMT_EXTERNAL\n#endif"
)
if(SPDLOG_WCHAR_SUPPORT)
if(SPDLOG_WCHAR_SUPPORT AND VCPKG_TARGET_IS_WINDOWS)
vcpkg_replace_string(${CURRENT_PACKAGES_DIR}/include/spdlog/tweakme.h
"// #define SPDLOG_WCHAR_TO_UTF8_SUPPORT"
"#ifndef SPDLOG_WCHAR_TO_UTF8_SUPPORT\n#define SPDLOG_WCHAR_TO_UTF8_SUPPORT\n#endif"

View File

@ -1,7 +1,7 @@
{
"name": "spdlog",
"version-semver": "1.10.0",
"port-version": 1,
"port-version": 2,
"description": "Very fast, header only, C++ logging library",
"homepage": "https://github.com/gabime/spdlog",
"license": "MIT",
@ -24,7 +24,8 @@
]
},
"wchar": {
"description": "Build with wchar_t (Windows only)"
"description": "Build with wchar_t (Windows only)",
"supports": "windows"
}
}
}

View File

@ -7086,7 +7086,7 @@
},
"spdlog": {
"baseline": "1.10.0",
"port-version": 1
"port-version": 2
},
"spectra": {
"baseline": "1.0.1",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "f7ad0e9d934ce7401fb68968f5392fddc7dd4e3a",
"version-semver": "1.10.0",
"port-version": 2
},
{
"git-tree": "3256ea88cc375fda2f977a2eb18435e23d498572",
"version-semver": "1.10.0",