1# Copyright Mike Dev 2018 2# Copyright Rene Rivera 2018 3# Distributed under the Boost Software License, Version 1.0. 4# See accompanying file LICENSE_1_0.txt or copy at 5# http://www.boost.org/LICENSE_1_0.txt 6 7# NOTE: 8# This does NOT run the unit tests for Boost.Predef. 9# It only tests, if the CMakeLists.txt file in predef's 10# root directory works as expected (i.e. it provides the 11# target Boost::predef which in turn provides the 12# correct include directory ) 13 14# We have very simple cmake requirements we we still require the new style 15# declarative targets. 16cmake_minimum_required( VERSION 3.0 ) 17 18project( PredefCMakeSelfTest ) 19 20# Process cmake file at root of library and use 21# ${CMAKE_CURRENT_BINARY_DIR}/libs/predef as workspace 22add_subdirectory( ../.. ${CMAKE_CURRENT_BINARY_DIR}/libs/predef ) 23 24# The executable just includes a predef header to verify that it's used. 25add_executable( predef_cmake_test_prj main.cpp ) 26 27# The executable needs to "use" the Predef "library" to get the usage 28# requirements added to the executable build. 29target_link_libraries( predef_cmake_test_prj Boost::predef ) 30