The cmake/spdlogConfig.cmake.in file properly takes into account the fmt
package dependency when building with SPDLOG_FMT_EXTERNAL:BOOL=ON but
not when built with SPDLOG_FMT_EXTERNAL_HO:BOOL=ON.
Prior to these changes SPDLOG_FMT_EXTERNAL_HO:BOOL=ON results in
exported targets with INTERFACE_LINK_LIBRARIES that contain
fmt::fmt-header-only.
As such, the installed spdlogConfig.cmake file should attempt to find
that dependency for the consumer.
As per CMake's Importing and Exporting Guide[1],
configure_package_config_file() should be used for configuring the
package configuration file, not the regular configure_file() function.
This ensures that a spdlog package built on one system (with a given
directory tree) can be imported from a different system -
e.g. creating a pre-compiled spdlog package for use on different
systems.
[1]: https://cmake.org/cmake/help/git-stage/guide/importing-exporting/index.html#id8
clang on windows support both gcc and mscv style options. Clang.exe on windows
defaults to gcc style, which will result in /WX unknown compiler command.
This will set /WX if and only if the compiler is MSVC and greater than version 1900
Compilation is shorten by 2 on windows with msvc. Some improvement for gcc and appleclang. Add SPDLOG_ENABLE_PCH option to CMake that is defaulted to ON. This will enable precompiled header by default if supported. It can be disable if user have a conflict of any kind. Or to check that project is still compiling with CMake version that do not support precompiled header.
Enable command line overrides of default settings
* CPACK_GENERATOR
* CPACK_PACKAGE_RELOCATABLE
Enables command line setting of generated RPM version attributes
* CPACK_RPM_PACKAGE_RELEASE
* CPACK_RPM_PACKAGE_ARCHITECTURE
Adds dependency on pkgconfig RPM when not generating relocatable RPM
Sets the following when querying the generated RPM's info:
Group : System Environment/Libraries
License : MIT
URL : https://github.com/gabime/spdlog
Summary : Fast C++ logging library
Description :
Very fast, header-only/compiled, C++ logging library.