From e72490638a8801a1830a909d6a09f34b35a543a1 Mon Sep 17 00:00:00 2001 From: Mike Dev Date: Tue, 2 Oct 2018 22:04:12 +0200 Subject: [PATCH] [CMake] Add minimal cmake file Generate cmake target that builds the library and which can be used by other libraries to express their dependency on this library and retrieve any configuration information such as the include directory, binary to link to, transitive dependencies, necessary compiler options or the required c++ standards level. --- CMakeLists.txt | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 CMakeLists.txt diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 00000000..598cbd9d --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,31 @@ +# Copyright 2018 Mike Dev +# Distributed under the Boost Software License, Version 1.0. +# See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt + +cmake_minimum_required(VERSION 3.5) +project(BoostRegex LANGUAGES CXX) + + +file(GLOB BOOST_REGEX_SRC ./src/*.cpp) + +add_library(boost_regex ${BOOST_REGEX_SRC}) +add_library(Boost::regex ALIAS boost_regex) + +target_include_directories(boost_regex PUBLIC include) + +target_link_libraries(boost_regex + PUBLIC + Boost::assert + Boost::concept_check + Boost::config + Boost::container_hash + Boost::core + Boost::integer + Boost::iterator + Boost::mpl + Boost::predef + Boost::smart_ptr + Boost::static_assert + Boost::throw_exception + Boost::type_traits +)