move build system to use conan cmake_find_package generator

This commit is contained in:
2021-07-26 16:21:01 +02:00
parent dccb727dc9
commit f2b998a09d
9 changed files with 33 additions and 113 deletions

View File

@@ -20,7 +20,7 @@ set(GIT_SUBMODULE_DIR_sc-components .)
set(GIT_SUBMODULE_BRANCH_sc-components ${GIT_BRANCH})
include(GNUInstallDirs)
include(Conan)
include(ConanInline)
include(BuildType)
#enable_testing()
@@ -71,13 +71,19 @@ endif()
endif()
setup_conan(TARGETS)
conan_configure(REQUIRES fmt/6.1.2 boost/1.75.0 gsl-lite/0.37.0 systemc/2.3.3 systemc-cci/1.0.0
GENERATORS cmake_find_package
OPTIONS fmt:header_only=True
)
conan_install()
find_package(ZLIB)
# This line finds the boost lib and headers.
set(Boost_NO_BOOST_CMAKE ON) # Don't do a find_package in config mode before searching for a regular boost install.
find_package(Boost COMPONENTS program_options filesystem system thread REQUIRED)
# set-up SystemC and SCV
find_package(OSCISystemC)
include(FindSystemCPackage)
if(NOT SystemC_FOUND)
message( FATAL_ERROR "SystemC library not found." )
endif()