-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adds setting of SystemC_LIBRARIES also for CWR & NCSC
- Loading branch information
Showing
1 changed file
with
36 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,40 @@ | ||
# a small wrapper to map SLS, OSCI SystemC (from environment) and conan package to the same variables | ||
if(NOT SystemC_FOUND) | ||
if(USE_CWR_SYSTEMC) | ||
find_package(SLSSystemC REQUIRED) | ||
elseif(USE_NCSC_SYSTEMC) | ||
find_package(XMSystemC REQUIRED) | ||
else() | ||
find_package(SystemCLanguage QUIET) | ||
if(TARGET SystemC::systemc) # conan find_package_generator or the cmake of an SystemC installation | ||
set(SystemC_FOUND true) | ||
set(SystemC_LIBRARIES SystemC::systemc) | ||
find_package(systemc-scv QUIET) | ||
if(systemc-scv_FOUND) | ||
set(SCV_FOUND TRUE) | ||
set(SCV_LIBRARIES systemc-scv::systemc-scv) | ||
endif() | ||
find_package(systemc-cci QUIET) | ||
if(systemc-cci_FOUND) | ||
set(CCI_FOUND TRUE) | ||
set(CCI_LIBRARIES systemc-cci::systemc-cci) | ||
endif() | ||
elseif(TARGET CONAN_PKG::systemc) # conan cmake targets | ||
set(SystemC_FOUND true) | ||
set(SystemC_LIBRARIES CONAN_PKG::systemc) | ||
if(TARGET CONAN_PKG::systemc-scv) | ||
set(SCV_FOUND TRUE) | ||
set(SCV_LIBRARIES CONAN_PKG::systemc-scv) | ||
endif() | ||
if(TARGET CONAN_PKG::systemc-cci) | ||
set(CCI_FOUND TRUE) | ||
set(CCI_LIBRARIES CONAN_PKG::systemc-cci) | ||
endif() | ||
else() | ||
find_package(OSCISystemC) | ||
if(USE_CWR_SYSTEMC) | ||
find_package(SLSSystemC REQUIRED) | ||
set(SystemC_LIBRARIES SystemC::systemc) | ||
elseif(USE_NCSC_SYSTEMC) | ||
find_package(XMSystemC REQUIRED) | ||
set(SystemC_LIBRARIES SystemC::systemc) | ||
else() | ||
find_package(SystemCLanguage QUIET) | ||
if(TARGET SystemC::systemc) # conan find_package_generator or the cmake of an SystemC installation | ||
set(SystemC_FOUND true) | ||
set(SystemC_LIBRARIES SystemC::systemc) | ||
endif() | ||
endif() | ||
find_package(systemc-scv QUIET) | ||
if(systemc-scv_FOUND) | ||
set(SCV_FOUND TRUE) | ||
set(SCV_LIBRARIES systemc-scv::systemc-scv) | ||
endif() | ||
find_package(systemc-cci QUIET) | ||
if(systemc-cci_FOUND) | ||
set(CCI_FOUND TRUE) | ||
set(CCI_LIBRARIES systemc-cci::systemc-cci) | ||
endif() | ||
elseif(TARGET CONAN_PKG::systemc) # conan cmake targets | ||
set(SystemC_FOUND true) | ||
set(SystemC_LIBRARIES CONAN_PKG::systemc) | ||
if(TARGET CONAN_PKG::systemc-scv) | ||
set(SCV_FOUND TRUE) | ||
set(SCV_LIBRARIES CONAN_PKG::systemc-scv) | ||
endif() | ||
if(TARGET CONAN_PKG::systemc-cci) | ||
set(CCI_FOUND TRUE) | ||
set(CCI_LIBRARIES CONAN_PKG::systemc-cci) | ||
endif() | ||
else() | ||
find_package(OSCISystemC) | ||
set(SystemC_LIBRARIES SystemC::systemc) | ||
endif() | ||
endif() | ||
endif() |