Merge pull request #874 from akva2/rename_common
changed: sync with renaming to opm-common
This commit is contained in:
commit
ce0c928903
@ -17,36 +17,36 @@
|
|||||||
cmake_minimum_required (VERSION 2.8)
|
cmake_minimum_required (VERSION 2.8)
|
||||||
|
|
||||||
# additional search modules
|
# additional search modules
|
||||||
set( OPM_CMAKE_ROOT "" CACHE PATH "Root directory containing OPM related cmake modules")
|
set( OPM_COMMON_ROOT "" CACHE PATH "Root directory containing OPM related cmake modules")
|
||||||
option(SIBLING_SEARCH "Search for other modules in sibling directories?" ON)
|
option(SIBLING_SEARCH "Search for other modules in sibling directories?" ON)
|
||||||
|
|
||||||
if(NOT OPM_CMAKE_ROOT)
|
if(NOT OPM_COMMON_ROOT)
|
||||||
find_package(opm-cmake QUIET)
|
find_package(opm-common QUIET)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (opm-cmake_FOUND)
|
if (opm-common_FOUND)
|
||||||
include(OpmInit)
|
include(OpmInit)
|
||||||
else()
|
else()
|
||||||
if (NOT OPM_CMAKE_ROOT AND SIBLING_SEARCH)
|
if (NOT OPM_COMMON_ROOT AND SIBLING_SEARCH)
|
||||||
set(OPM_CMAKE_ROOT ${PROJECT_SOURCE_DIR}/../opm-cmake)
|
set(OPM_COMMON_ROOT ${PROJECT_SOURCE_DIR}/../opm-common)
|
||||||
endif()
|
endif()
|
||||||
if (OPM_CMAKE_ROOT)
|
if (OPM_COMMON_ROOT)
|
||||||
list( APPEND CMAKE_MODULE_PATH "${OPM_CMAKE_ROOT}/cmake/Modules")
|
list( APPEND CMAKE_MODULE_PATH "${OPM_COMMON_ROOT}/cmake/Modules")
|
||||||
include (OpmInit OPTIONAL RESULT_VARIABLE OPM_INIT)
|
include (OpmInit OPTIONAL RESULT_VARIABLE OPM_INIT)
|
||||||
set( OPM_MACROS_ROOT ${OPM_CMAKE_ROOT} )
|
set( OPM_MACROS_ROOT ${OPM_COMMON_ROOT} )
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT OPM_INIT)
|
if (NOT OPM_INIT)
|
||||||
message( "" )
|
message( "" )
|
||||||
message( " /-------------------------------------------------------------------------------\\")
|
message( " /---------------------------------------------------------------------------------\\")
|
||||||
message( " | Could not locate the opm build macros. The opm build macros |")
|
message( " | Could not locate the opm build macros. The opm build macros |")
|
||||||
message( " | are in a separate repository - instructions to proceed: |")
|
message( " | are in a separate repository - instructions to proceed: |")
|
||||||
message( " | |")
|
message( " | |")
|
||||||
message( " | 1. Clone the repository: git clone git@github.com:OPM/opm-cmake.git |")
|
message( " | 1. Clone the repository: git clone git@github.com:OPM/opm-common.git |")
|
||||||
message( " | |")
|
message( " | |")
|
||||||
message( " | 2. Run cmake in the current project with -DOPM_CMAKE_ROOT=<path>/opm-cmake |")
|
message( " | 2. Run cmake in the current project with -DOPM_COMMON_ROOT=<path>/opm-common |")
|
||||||
message( " | |")
|
message( " | |")
|
||||||
message( " \\-------------------------------------------------------------------------------/")
|
message( " \\---------------------------------------------------------------------------------/")
|
||||||
message( "" )
|
message( "" )
|
||||||
message( FATAL_ERROR "Could not find OPM Macros")
|
message( FATAL_ERROR "Could not find OPM Macros")
|
||||||
endif()
|
endif()
|
||||||
|
4
configure
vendored
4
configure
vendored
@ -6,7 +6,7 @@ src_dir=$(dirname $0)
|
|||||||
mod_dir=
|
mod_dir=
|
||||||
for OPT in "$@"; do
|
for OPT in "$@"; do
|
||||||
case "$OPT" in
|
case "$OPT" in
|
||||||
--with-opm-cmake=*)
|
--with-opm-common=*)
|
||||||
# remove everything before equal sign and assign the rest
|
# remove everything before equal sign and assign the rest
|
||||||
mod_dir=${OPT#*=}
|
mod_dir=${OPT#*=}
|
||||||
# tilde expansion; note that doing eval may have side effects
|
# tilde expansion; note that doing eval may have side effects
|
||||||
@ -27,7 +27,7 @@ fi
|
|||||||
|
|
||||||
# terminate with error message here if the module directory is not found
|
# terminate with error message here if the module directory is not found
|
||||||
if [ ! -r "$mod_dir/$conf_file" ]; then
|
if [ ! -r "$mod_dir/$conf_file" ]; then
|
||||||
echo Build macros not located in \"$mod_dir\", use --with-opm-cmake= to specify! 1>&2
|
echo Build macros not located in \"$mod_dir\", use --with-opm-common= to specify! 1>&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -4,4 +4,4 @@ Description: Open Porous Media Initiative Core Library
|
|||||||
Version: 1.1
|
Version: 1.1
|
||||||
Label: 2013.10
|
Label: 2013.10
|
||||||
Maintainer: atgeirr@sintef.no
|
Maintainer: atgeirr@sintef.no
|
||||||
Depends: dune-common (>= 2.2) dune-istl (>= 2.2) opm-cmake opm-parser opm-material
|
Depends: dune-common (>= 2.2) dune-istl (>= 2.2) opm-common opm-parser opm-material
|
||||||
|
Loading…
Reference in New Issue
Block a user