From 30bd80bd85df4e848ef4cbb701b631acf2c10e05 Mon Sep 17 00:00:00 2001 From: gabime Date: Wed, 29 May 2019 00:04:36 +0300 Subject: CMake improvements --- example/CMakeLists.txt | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'example') diff --git a/example/CMakeLists.txt b/example/CMakeLists.txt index 2fbbf1d2..994051f9 100644 --- a/example/CMakeLists.txt +++ b/example/CMakeLists.txt @@ -2,15 +2,9 @@ # Distributed under the MIT License (http://opensource.org/licenses/MIT) cmake_minimum_required(VERSION 3.1) -project(SpdlogExamples CXX) +project(spdlog_examples CXX) -if(TARGET spdlog) - # If we're running this example as part of the primary spdlog applciation - # then add an alias. This allows us to use the same "spdlog::spdlog" - # below that a user would use (with the namespace) - add_library(spdlog::spdlog ALIAS spdlog) - add_library(spdlog::spdlog_header_only ALIAS spdlog_header_only) -else() +if(NOT TARGET spdlog) # Stand-alone build find_package(spdlog REQUIRED) endif() -- cgit v1.2.3