rom-properties/cmake
David Korth fa932de93f [libfmt] Add an internal copy of libfmt-11.1.2.
Currently used as a header-only build. Will eventually be changed to
build a DLL for Windows and Mac OS X.

Other changes needed to get the Windows version to build with libfmt:

Add #include <fmt/xchar.h> to some files for full wchar_t support
in libfmt. Otherwise, errors like this appear:

src\amiibo-data\amiiboc.cpp(175,8): error C2665: 'fmt::v11::print': no overloaded function could convert all the argument types
extlib\libfmt\include\fmt\base.h(2925,17): message : could be 'void fmt::v11::print<TCHAR*&>(FILE *,fmt::v11::fstring<TCHAR *&>,TCHAR *&)'
src\amiibo-data\amiiboc.cpp(175,8): message : 'void fmt::v11::print<TCHAR*&>(FILE *,fmt::v11::fstring<TCHAR *&>,TCHAR *&)': cannot convert argument 2 from 'wmain::<lambda_1>::()::FMT_COMPILE_STRING' to 'fmt::v11::fstring<TCHAR *&>'
src\amiibo-data\amiiboc.cpp(175,22): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
extlib\libfmt\include\fmt\base.h(2908,17): message : or       'void fmt::v11::print<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR*&>(fmt::v11::fstring<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR *&>,wmain::<lambda_1>::()::FMT_COMPILE_STRING &&,TCHAR *&)'
src\amiibo-data\amiiboc.cpp(175,8): message : 'void fmt::v11::print<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR*&>(fmt::v11::fstring<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR *&>,wmain::<lambda_1>::()::FMT_COMPILE_STRING &&,TCHAR *&)': cannot convert argument 1 from 'FILE *' to 'fmt::v11::fstring<wmain::<lambda_1>::()::FMT_COMPILE_STRING,TCHAR *&>'
src\amiibo-data\amiiboc.cpp(175,14): message : No constructor could take the source type, or constructor overload resolution was ambiguous
src\amiibo-data\amiiboc.cpp(175,8): message : while trying to match the argument list '(FILE *, wmain::<lambda_1>::()::FMT_COMPILE_STRING, TCHAR *)' [build.vc17_64\src\amiibo-data\amiiboc.vcxproj]

Files modified for xchar.h:
- amiibo-data/amiiboc.cpp
- libromdata/stdafx.h (needed by WiiUPackage)
- libromdata/tests/RomHeaderTest.cpp

NOTE: Only included on Windows. xchar.h was added in libfmt-8.0.0,
which was first added (in Ubuntu LTS releases) in Ubuntu 20.04.
It's not needed on Linux, anyway.

New option USE_INTERNAL_FMT to force the use of the internal copy of
libfmt on Linux, for testing purposes. (...and also for Ubuntu 16.04)
- TODO: Maybe use it on 18.04, etc. for improved performance?
2025-01-21 23:59:20 -05:00
..
libs [libfmt] Add an internal copy of libfmt-11.1.2. 2025-01-21 23:59:20 -05:00
macros Remove CheckHiddenVisibility.cmake. 2025-01-18 22:34:24 -05:00
platform [cmake] msvc.cmake: Add more conformance options. 2025-01-20 18:45:52 -05:00
toolchain [scripts] package.cmd: Add ARM, ARM64, and ARM64EC. 2023-07-16 18:28:21 -04:00
cmake_uninstall.cmake.in [cmake] cmake_uninstall.cmake.in: Use EXECUTE_PROCESS() instead of EXEC_PROGRAM(). 2024-03-03 12:51:03 -05:00
options.cmake [libfmt] Add an internal copy of libfmt-11.1.2. 2025-01-21 23:59:20 -05:00
platform.cmake [cmake] Add flags for RelWithDebInfo. 2024-03-24 16:58:18 -04:00