aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorMario Werner <mario.werner@iaik.tugraz.at>2017-05-23 17:01:45 +0200
committerVictor Zverovich <victor.zverovich@gmail.com>2018-03-13 13:51:48 -0400
commit6d21fc43b9478f66206610d7cc1cf81b3b4e797a (patch)
tree822eef4bf4e71711d5228c8a44ef666f1107080a /CMakeLists.txt
parente02aacc6343a3db64a5963dea51bb8b64a555bae (diff)
downloadfmtlib-6d21fc43b9478f66206610d7cc1cf81b3b4e797a.tar.gz
add alias targets with fmt namespace
For the consumer it should not matter if fmt has been added to the project as subdirectory or via find_package. With the alias targets the library can be always imported via fmt::fmt.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt1
1 files changed, 1 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 95556539..f7260c32 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -133,6 +133,7 @@ endif ()
# Additionally define a header-only library when CMake is new enough.
if (CMAKE_VERSION VERSION_GREATER 3.1.0 OR CMAKE_VERSION VERSION_EQUAL 3.1.0)
add_library(fmt-header-only INTERFACE)
+ add_library(fmt::fmt-header-only ALIAS fmt-header-only)
target_compile_definitions(fmt-header-only INTERFACE FMT_HEADER_ONLY=1)