Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bring 3rdParty libraries into OMSimulator's CMake build system. #1221

Merged
merged 16 commits into from
Aug 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion 3rdParty
Submodule 3rdParty updated 886 files
97 changes: 14 additions & 83 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,16 +1,20 @@
message("cmake version is: ${CMAKE_VERSION}")

IF(WIN32 AND MSVC)
# VS 2017 requires Boost 1.64 or newer
# Boost 1.64 requires CMake 3.8 or newer
cmake_minimum_required(VERSION 3.8)
ELSE()
cmake_minimum_required(VERSION 2.8)
ENDIF()
cmake_minimum_required(VERSION 3.14)

project(OMSimulator)

list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/config.cmake/")

## If OMSimulator is being built standalone (not as part of OpenModelica)
## include the required settings here.
if(${CMAKE_PROJECT_NAME} STREQUAL ${PROJECT_NAME})
set(OMSIMULATOR_STANDALONE ON)
include(OMSimulatorTopLevelSettings)
else()
set(OMSIMULATOR_STANDALONE OFF)
endif()


include(GetGitRevisionDescription)
if (EXISTS "${CMAKE_SOURCE_DIR}/version.txt")
file(STRINGS "version.txt" OMS_VERSION_STRING)
Expand All @@ -36,17 +40,8 @@ ELSE()
set(PLATFORM_STRING "linux")
ENDIF()

# Don't allow in-source build
IF("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_BINARY_DIR}")
message(FATAL_ERROR "No in-source builds supported. Change to 'build' sub-directory and do 'cmake ..'.")
ENDIF()

message(STATUS "Platform string: ${PLATFORM_STRING}")

IF(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX ${PROJECT_SOURCE_DIR}/install/${PLATFORM_STRING} CACHE PATH "Library installation path (don't change)" FORCE)
ENDIF()

if("${STD_REGEX}" STREQUAL "0")
message(WARNING, "Using boost::regex instead of std::regex due to old gcc/clang compiler")
set(LIB_BOOST_REGEX regex)
Expand All @@ -66,9 +61,6 @@ ELSE()
message(STATUS "ABI is: ${ABI}")
ENDIF("${ABI}" MATCHES "^LINUX")

# Enable verbose output from Makefile builds
set(CMAKE_VERBOSE_MAKEFILE ON)

# Use C++ 11 for the whole project
# cmake < 3.1 doesn't know or respect CMAKE_CXX_STANDARD*
set(CPP_FS_LIBS "")
Expand Down Expand Up @@ -127,40 +119,8 @@ ELSE()
ENDIF()

##########################
# Configuring for ZIP
set(ZLIB_ROOT ${PROJECT_SOURCE_DIR}/3rdParty/zlib/install/${PLATFORM_STRING})
find_package(ZLIB REQUIRED)

# Configuring for minizip
set(MINIZIP_ROOT ${PROJECT_SOURCE_DIR}/3rdParty/minizip/install/${PLATFORM_STRING})
# set(MINIZIP_INCLUDEDIR ${PROJECT_SOURCE_DIR}/3rdParty/minizip/install/${PLATFORM_STRING}/include)
# set(MINIZIP_LIBRARYDIR ${PROJECT_SOURCE_DIR}/3rdParty/minizip/install/${PLATFORM_STRING}/lib)
find_package(MINIZIP REQUIRED)

##########################
# Configuring for FMI4c
set(FMI4c_ROOT ${PROJECT_SOURCE_DIR}/3rdParty/fmi4c/install/${PLATFORM_STRING})
find_package(FMI4c REQUIRED)

##########################
# Configuring for Lua
set(LUALibrary_ROOT ${PROJECT_SOURCE_DIR}/3rdParty/Lua/install/${PLATFORM_STRING})
find_package(LUALibrary REQUIRED)

##########################
# Configuring for CVODE
set(CVODELibrary_ROOT ${PROJECT_SOURCE_DIR}/3rdParty/cvode/install/${PLATFORM_STRING})
find_package(CVODELibrary REQUIRED)

##########################
# Configuring for KINSOL
set(KINSOLLibrary_ROOT ${PROJECT_SOURCE_DIR}/3rdParty/kinsol/install/${PLATFORM_STRING})
find_package(KINSOLLibrary REQUIRED)

##########################
# Configuring for PUGIXML
add_definitions(-DPUGIXML_HEADER_ONLY)
set(PUGIXML_INCLUDEDIR ${PROJECT_SOURCE_DIR}/3rdParty/PugiXml)
add_subdirectory(3rdParty)

##########################
# Configuring for CTPL
Expand All @@ -178,39 +138,10 @@ ELSE()
MESSAGE(WARNING, "Python library not found.")
ENDIF()

##########################
# Configuration for OMTLMSimulatorLib
option(OMTLM "Enable the OMTLMSimulator module." ON)
IF(OMTLM)
set(OMTLMSIMULATOR_INCLUDEDIR ${PROJECT_SOURCE_DIR}/OMTLMSimulator/common)
set(OMTLMSIMULATORLIB_INCLUDEDIR ${PROJECT_SOURCE_DIR}/OMTLMSimulator/common/OMTLMSimulatorLib)
IF(WIN32)
set(OMTLMSIMULATORLIB_LIBRARYDIR ${PROJECT_SOURCE_DIR}/OMTLMSimulator/bin)
ELSE() # use it from the install folder where is properly installed for MacOS
set(OMTLMSIMULATORLIB_LIBRARYDIR ${CMAKE_INSTALL_PREFIX}/lib/${HOST_SHORT})
ENDIF()
set(OMTLMSIMULATOR_3RDPARTY_INCLUDEDIR ${PROJECT_SOURCE_DIR}/OMTLMSimulator/3rdParty/misc/include)
IF(WIN32)
IF (MINGW)
# adrpo: link with the full path to the dll on MINGW
set(OMTLM_LINKFLAGS ${OMTLMSIMULATORLIB_LIBRARYDIR}/libomtlmsimulator.dll wsock32 ws2_32)
message(STATUS "OMTLMSimulator enabled: ${OMTLM_LINKFLAGS}")
ELSE(MINGW)
set(OMTLM_LINKFLAGS omtlmsimulator wsock32 ws2_32)
ENDIF(MINGW)
ELSE(WIN32)
set(OMTLM_LINKFLAGS omtlmsimulator)
ENDIF(WIN32)
message(STATUS "OMTLMSimulator enabled.")
ELSE(OMTLM)
set(OMTLM_LINKFLAGS)
message(STATUS "OMTLMSimulator disabled.")
ENDIF(OMTLM)

##########################
# Add project modules
add_subdirectory(src/OMSimulator)
add_subdirectory(src/OMSimulatorLib)
add_subdirectory(src/OMSimulator)
add_subdirectory(src/OMSimulatorLua)
add_subdirectory(src/OMSimulatorPython)
add_subdirectory(src/OMSimulatorServer)
Expand Down
105 changes: 5 additions & 100 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ROOT_DIR=$(shell pwd)
# Option to build LIBXML2 as part of the 3rdParty projects
LIBXML2 ?= $(OMTLM)
# Option to enable OMTLM
OMTLM ?= ON
OMTLM ?= OFF
# Option to enable AddressSanitizer
ASAN ?= OFF
# Statically link dependencies as much as possible
Expand Down Expand Up @@ -78,7 +78,7 @@ endif
# Should we install everything into the OMBUILDDIR?
ifeq ($(OMBUILDDIR),)
TOP_INSTALL_DIR=$(INSTALL_DIR)
CMAKE_INSTALL_PREFIX=
CMAKE_INSTALL_PREFIX=-DCMAKE_INSTALL_PREFIX=$(TOP_INSTALL_DIR)
HOST_SHORT=
else
TOP_INSTALL_DIR=$(OMBUILDDIR)
Expand Down Expand Up @@ -116,7 +116,7 @@ else
CMAKE_BOOST_ROOT="-DBOOST_ROOT=$(BOOST_ROOT)"
endif

.PHONY: OMSimulator OMSimulatorCore config-OMSimulator config-fmi4c config-lua config-minizip config-zlib config-cvode config-kinsol config-xerces config-3rdParty distclean testsuite doc doc-html doc-doxygen OMTLMSimulator OMTLMSimulatorClean RegEx pip
.PHONY: OMSimulator OMSimulatorCore config-OMSimulator config-xerces config-3rdParty distclean testsuite doc doc-html doc-doxygen OMTLMSimulator OMTLMSimulatorClean RegEx pip

OMSimulator:
@echo OS: $(detected_OS)
Expand Down Expand Up @@ -188,7 +188,7 @@ RegEx: 3rdParty/RegEx/OMSRegEx$(EEXT)
@echo "Please checkout the 3rdParty submodule, e.g. using \"git submodule update --init 3rdParty\", and try again."
@false

config-3rdParty: 3rdParty/README.md config-zlib config-minizip config-fmi4c config-lua config-cvode config-kinsol config-libxml2
config-3rdParty: 3rdParty/README.md

config-OMSimulator: $(BUILD_DIR)/Makefile
$(BUILD_DIR)/Makefile: RegEx CMakeLists.txt
Expand All @@ -197,77 +197,7 @@ $(BUILD_DIR)/Makefile: RegEx CMakeLists.txt
@echo
$(eval STD_REGEX := $(shell 3rdParty/RegEx/OMSRegEx$(EEXT)))
$(MKDIR) $(BUILD_DIR)
cd $(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. -DABI=$(ABI) -DSTD_REGEX=$(STD_REGEX) -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON -DOMTLM:BOOL=$(OMTLM) -DASAN:BOOL=$(ASAN) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) $(CMAKE_BOOST_ROOT) $(CMAKE_INSTALL_PREFIX) $(HOST_SHORT) $(EXTRA_CMAKE) $(CMAKE_STATIC)

# use zlib and minizip from OMSimulator 3rdParty by setting OMS_ZLIB_INCLUDE_DIR, OMS_ZLIB_LIBRARY OMS_MINIZIP_INCLUDE_DIR and DOMS_MINIZIP_LIBRARY, see 3rdparty/fmi4c/cmake
config-fmi4c: config-minizip config-zlib 3rdParty/fmi4c/$(INSTALL_DIR)/lib/libfmi4c.a
3rdParty/fmi4c/$(INSTALL_DIR)/lib/libfmi4c.a: 3rdParty/fmi4c/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/fmi4c/$(BUILD_DIR)/ install VERBOSE=1
3rdParty/fmi4c/$(BUILD_DIR)/Makefile: 3rdParty/fmi4c/CMakeLists.txt
@echo
@echo "# config fmi4c"
@echo
$(MKDIR) 3rdParty/fmi4c/$(BUILD_DIR)
$(MKDIR) 3rdParty/fmi4c/$(INSTALL_DIR)
cd 3rdParty/fmi4c/$(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. \
-DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) \
-DFMI4C_BUILD_SHARED=OFF \
-DFMI4C_USE_INCLUDED_ZLIB=OFF \
-DOMS_ZLIB_INCLUDE_DIR=../zlib/$(INSTALL_DIR)/include \
-DOMS_ZLIB_LIBRARY=../zlib/$(INSTALL_DIR)/lib/libzlibstatic.a \
-DOMS_MINIZIP_INCLUDE_DIR=../minizip/$(INSTALL_DIR)/include \
-DOMS_MINIZIP_LIBRARY=../minizip/$(INSTALL_DIR)/lib/libminizip.a

config-zlib: 3rdParty/zlib/$(INSTALL_DIR)/lib/libzlibstatic.a
3rdParty/zlib/$(INSTALL_DIR)/lib/libzlibstatic.a: 3rdParty/zlib/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/zlib/$(BUILD_DIR)/ install VERBOSE=1
3rdParty/zlib/$(BUILD_DIR)/Makefile: 3rdParty/zlib/CMakeLists.txt
@echo
@echo "# config zlib"
@echo
$(MKDIR) 3rdParty/zlib/$(BUILD_DIR)
$(MKDIR) 3rdParty/zlib/$(INSTALL_DIR)
cd 3rdParty/zlib/$(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) -DBUILD_SHARED_LIBS=OFF

config-lua: 3rdParty/Lua/$(INSTALL_DIR)/liblua.a
3rdParty/Lua/$(INSTALL_DIR)/liblua.a: 3rdParty/Lua/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/Lua/$(BUILD_DIR)/ install VERBOSE=1
3rdParty/Lua/$(BUILD_DIR)/Makefile:
@echo
@echo "# config Lua"
@echo
$(MKDIR) 3rdParty/Lua/$(BUILD_DIR)/
cd 3rdParty/Lua/$(BUILD_DIR)/ && $(CMAKE) $(CMAKE_TARGET) ../.. -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) -DLUA_ENABLE_SHARED=OFF -DLUA_ENABLE_TESTING=OFF

config-minizip: config-zlib 3rdParty/minizip/$(INSTALL_DIR)/libminizip.a
3rdParty/minizip/$(INSTALL_DIR)/libminizip.a: 3rdParty/minizip/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/minizip/$(BUILD_DIR)/ install VERBOSE=1
3rdParty/minizip/$(BUILD_DIR)/Makefile:
@echo
@echo "# config minizip"
@echo
$(MKDIR) 3rdParty/minizip/$(BUILD_DIR)/
cd 3rdParty/minizip/$(BUILD_DIR)/ && $(CMAKE) $(CMAKE_TARGET) ../../src -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR)

config-cvode: 3rdParty/cvode/$(INSTALL_DIR)/lib/libsundials_cvode.a
3rdParty/cvode/$(INSTALL_DIR)/lib/libsundials_cvode.a: 3rdParty/cvode/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/cvode/$(BUILD_DIR)/ install
3rdParty/cvode/$(BUILD_DIR)/Makefile: 3rdParty/cvode/CMakeLists.txt
@echo
@echo "# config cvode"
@echo
$(MKDIR) 3rdParty/cvode/$(BUILD_DIR)
cd 3rdParty/cvode/$(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) -DEXAMPLES_ENABLE:BOOL=0 -DBUILD_SHARED_LIBS:BOOL=0 $(CMAKE_FPIC)

config-kinsol: 3rdParty/kinsol/$(INSTALL_DIR)/lib/libsundials_kinsol.a
3rdParty/kinsol/$(INSTALL_DIR)/lib/libsundials_kinsol.a: 3rdParty/kinsol/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/kinsol/$(BUILD_DIR)/ install
3rdParty/kinsol/$(BUILD_DIR)/Makefile: 3rdParty/kinsol/CMakeLists.txt
@echo
@echo "# config kinsol"
@echo
$(MKDIR) 3rdParty/kinsol/$(BUILD_DIR)
cd 3rdParty/kinsol/$(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) -DEXAMPLES_ENABLE:BOOL=0 -DBUILD_SHARED_LIBS:BOOL=0 $(CMAKE_FPIC)
$(CMAKE) -S . -B $(BUILD_DIR) $(CMAKE_TARGET) -DABI=$(ABI) -DSTD_REGEX=$(STD_REGEX) -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON -DASAN:BOOL=$(ASAN) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) $(CMAKE_BOOST_ROOT) $(CMAKE_INSTALL_PREFIX) $(HOST_SHORT) $(EXTRA_CMAKE) $(CMAKE_STATIC)

config-xerces: 3rdParty/xerces/$(INSTALL_DIR)/lib/libxerces-c.a
3rdParty/xerces/$(INSTALL_DIR)/lib/libxerces-c.a: 3rdParty/xerces/$(BUILD_DIR)/Makefile
Expand All @@ -279,41 +209,16 @@ config-xerces: 3rdParty/xerces/$(INSTALL_DIR)/lib/libxerces-c.a
$(MKDIR) 3rdParty/xerces/$(BUILD_DIR)
cd 3rdParty/xerces/$(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) -DBUILD_SHARED_LIBS:BOOL=OFF

ifeq ($(LIBXML2),OFF)
config-libxml2:
@echo
@echo "# LIBXML2=OFF => Skipping build of 3rdParty library libxml2 (must be installed on system instead)."
@echo
else
config-libxml2: 3rdParty/libxml2/$(INSTALL_DIR)/lib/libxml2.a
3rdParty/libxml2/$(INSTALL_DIR)/lib/libxml2.a: 3rdParty/libxml2/$(BUILD_DIR)/Makefile
$(MAKE) -C 3rdParty/libxml2/$(BUILD_DIR)/ install
3rdParty/libxml2/$(BUILD_DIR)/Makefile: 3rdParty/libxml2/CMakeLists.txt
@echo
@echo "# config libxml2"
@echo
$(MKDIR) 3rdParty/libxml2/$(BUILD_DIR)
cd 3rdParty/libxml2/$(BUILD_DIR) && $(CMAKE) $(CMAKE_TARGET) ../.. -DCMAKE_INSTALL_PREFIX=../../$(INSTALL_DIR) -DBUILD_SHARED_LIBS=OFF -DLIBXML2_WITH_PYTHON=OFF -DLIBXML2_WITH_ZLIB=OFF -DLIBXML2_WITH_LZMA=OFF -DLIBXML2_WITH_TESTS=OFF
endif

distclean:
@echo
@echo "# make distclean"
@echo
@$(MAKE) OMTLMSimulatorClean
$(RM) $(BUILD_DIR)
$(RM) $(INSTALL_DIR)
$(RM) 3rdParty/Lua/$(BUILD_DIR)
$(RM) 3rdParty/Lua/$(INSTALL_DIR)
$(RM) 3rdParty/RegEx/OMSRegEx$(EEXT)
$(RM) 3rdParty/cvode/$(BUILD_DIR)
$(RM) 3rdParty/cvode/$(INSTALL_DIR)
$(RM) 3rdParty/kinsol/$(BUILD_DIR)
$(RM) 3rdParty/kinsol/$(INSTALL_DIR)
$(RM) 3rdParty/xerces/$(BUILD_DIR)
$(RM) 3rdParty/xerces/$(INSTALL_DIR)
$(RM) 3rdParty/libxml2/$(BUILD_DIR)
$(RM) 3rdParty/libxml2/$(INSTALL_DIR)

testsuite:
@echo
Expand Down
11 changes: 0 additions & 11 deletions buildWinVS.bat
Original file line number Diff line number Diff line change
Expand Up @@ -45,17 +45,6 @@ IF NOT DEFINED CMAKE_BUILD_TYPE SET CMAKE_BUILD_TYPE="Release"

MKDIR install\win\bin

:: -- build OMTLMSimulator ----------------------------------------------------
ECHO # Building OMTLMSimulator
CD OMTLMSimulator
START /B /WAIT CMD /C "buildWinVS.bat %OMS_VS_TARGET%"
IF NOT ["%ERRORLEVEL%"]==["0"] GOTO fail
CD..
COPY /Y OMTLMSimulator\bin\omtlmsimulator.lib install\win\bin
COPY /Y OMTLMSimulator\bin\omtlmsimulator.dll install\win\bin
ECHO %CD%
:: -- build OMTLMSimulator ----------------------------------------------------

:: -- build OMSimulator -------------------------------------------------------
ECHO # build OMSimulator
msbuild.exe "build\win\INSTALL.vcxproj" /t:Build /p:configuration=%CMAKE_BUILD_TYPE% /maxcpucount
Expand Down
57 changes: 57 additions & 0 deletions config.cmake/OMSimulatorTopLevelSettings.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# Build all libraries within OMSimulator with position independent
set(CMAKE_POSITION_INDEPENDENT_CODE ON)

# Find and use ccache if available.
find_program(CCACHE_PROGRAM ccache)
if(CCACHE_PROGRAM)
message(STATUS "Found ccache. It will be used for compilation C/C++ sources")
set(CMAKE_CXX_COMPILER_LAUNCHER ${CCACHE_PROGRAM})
set(CMAKE_C_COMPILER_LAUNCHER ${CCACHE_PROGRAM})
endif()

### Installation configurations ###############################################################################
# Install following GNU conventions (i.e., bin, lib, include, share ...)
include(GNUInstallDirs)

# Precaution so that users do not install in system folders (e.g. /user/, /usr/local/)
# unintentionally. If the user has not specified anything default to an install_cmake dir in the root
# build directory.
if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
set(CMAKE_INSTALL_PREFIX "${PROJECT_BINARY_DIR}/install_cmake" CACHE PATH "Default installation directory" FORCE)
# Prevent sub-projects from changing it by checking CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT after this
set(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT FALSE)
message(WARNING "No installation directory specified. Defaulting to: ${CMAKE_INSTALL_PREFIX}")
endif()
# omc_add_to_report(CMAKE_INSTALL_PREFIX)

# Install libraries to lib/<arch> folder within the installation prefix directory.
set(CMAKE_INSTALL_LIBDIR "${CMAKE_INSTALL_LIBDIR}/${CMAKE_LIBRARY_ARCHITECTURE}")

# Install headers to "include/" folder within the installation prefix directory.
# set(CMAKE_INSTALL_INCLUDEDIR "${CMAKE_INSTALL_INCLUDEDIR}/")

# On macOS we want BUNDLEs (.app) to go to an 'Applications/' directory instead of a 'bin/' directory
if(APPLE)
set(OM_MACOS_INSTALL_BUNDLEDIR "Applications/")
endif()

## Set the adjusted installation lib directory as an rpath for all installed binaries.
## Assumes binaries end up in either 'bin' or 'lib' AND also assumes that 'bin' and 'lib' are sibling directories.
if(APPLE)
## MacOS Bundles end up in bin/<BundleName>.app/Contents/MacOS/
## So make sure that the lib dir is referenced from that location as well
set(CMAKE_INSTALL_RPATH "@loader_path/../${CMAKE_INSTALL_LIBDIR};@loader_path/../../../../${CMAKE_INSTALL_LIBDIR}")
else()
set(CMAKE_INSTALL_RPATH "$ORIGIN;$ORIGIN/../${CMAKE_INSTALL_LIBDIR}")
endif()

## Do not print unnecessary install messages when nothing has actually changed.
set(CMAKE_INSTALL_MESSAGE LAZY)




# Don't allow in-source build
if("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_BINARY_DIR}")
message(FATAL_ERROR "No in-source builds supported. Change to 'build' sub-directory and do 'cmake ..'.")
endif()
Loading