ionobase
This commit is contained in:
parent
c79d5268d3
commit
aebd1d3088
@ -1,13 +1,13 @@
|
||||
if(NOT LIBIONOBASE_PREFIX STREQUAL CMAKE_BINARY_DIR)
|
||||
if(NOT LIBIONOBASE_IS_EXTERNAL_PROJECT)
|
||||
set(LIBIONOBASE_PREFIX "" CACHE PATH "The path to the prefix of an libionobase installation")
|
||||
|
||||
find_path(
|
||||
LIBIONOBASE_INCLUDE_DIRS
|
||||
NAMES preprocmath/params.hpp
|
||||
NAMES ionobase/interchfor.hpp
|
||||
PATHS ${LIBIONOBASE_PREFIX}/include)
|
||||
find_library(
|
||||
LIBIONOBASE_LIBRARY
|
||||
NAMES preprocmath
|
||||
NAMES ionobase
|
||||
PATHS ${LIBIONOBASE_PREFIX}/lib)
|
||||
|
||||
if(LIBIONOBASE_INCLUDE_DIRS AND LIBIONOBASE_LIBRARY)
|
||||
|
@ -1,29 +1,27 @@
|
||||
# Подключение внешних проектов
|
||||
include(ExternalProject)
|
||||
|
||||
if(${IonobaseThirdparty_FIND_COMPONENTS} STREQUAL "headers")
|
||||
ExternalProject_Add(
|
||||
libionobase
|
||||
SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/libionobase
|
||||
INSTALL_DIR ${CMAKE_BINARY_DIR}
|
||||
DOWNLOAD_COMMAND ""
|
||||
CONFIGURE_COMMAND
|
||||
${CMAKE_COMMAND} -G "${CMAKE_GENERATOR}"
|
||||
-DCMLIB_MAIN_DIR=${CMLIB_MAIN_DIR} ${CMLIB_EXT_PROJ_DEFAULT_ARGS}
|
||||
<SOURCE_DIR>
|
||||
BUILD_COMMAND true
|
||||
INSTALL_COMMAND make ionobase-install-headers)
|
||||
else()
|
||||
ExternalProject_Add(
|
||||
libionobase
|
||||
SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/libionobase
|
||||
INSTALL_DIR ${CMAKE_BINARY_DIR}
|
||||
DOWNLOAD_COMMAND ""
|
||||
CONFIGURE_COMMAND
|
||||
${CMAKE_COMMAND} -G "${CMAKE_GENERATOR}"
|
||||
-DCMLIB_MAIN_DIR=${CMLIB_MAIN_DIR} ${CMLIB_EXT_PROJ_DEFAULT_ARGS}
|
||||
<SOURCE_DIR>)
|
||||
# cmake-format: off
|
||||
list(APPEND _ext_project_args
|
||||
libionobase
|
||||
SOURCE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/libionobase
|
||||
INSTALL_DIR ${CMAKE_BINARY_DIR}
|
||||
DOWNLOAD_COMMAND ""
|
||||
CONFIGURE_COMMAND ${CMAKE_COMMAND} -G "${CMAKE_GENERATOR}"
|
||||
-DCMLIB_MAIN_DIR=${CMLIB_MAIN_DIR}
|
||||
${CMLIB_EXT_PROJ_DEFAULT_ARGS}
|
||||
<SOURCE_DIR>)
|
||||
|
||||
if(IonobaseThirdparty_FIND_COMPONENTS STREQUAL "headers")
|
||||
list(APPEND _ext_project_args
|
||||
BUILD_COMMAND true
|
||||
INSTALL_COMMAND ${CMAKE_MAKE_PROGRAM} ionobase-install-headers)
|
||||
endif()
|
||||
ExternalProject_Add(${_ext_project_args})
|
||||
unset(_ext_project_args)
|
||||
|
||||
set(LIBIONOBASE_IS_EXTERNAL_PROJECT ON CACHE BOOL "" FORCE)
|
||||
# cmake-format: on
|
||||
|
||||
set(LIBIONOBASE_PREFIX
|
||||
${CMAKE_BINARY_DIR}
|
||||
|
Loading…
Reference in New Issue
Block a user