2012-10-19 07:14:15 -05:00
|
|
|
# - Open Porous Media Initiative Core Library config mode
|
|
|
|
#
|
|
|
|
# Defines the following variables:
|
|
|
|
# @PACKAGE@_FOUND - true
|
|
|
|
# @PACKAGE@_VERSION - version of the opm-core library found, e.g. 0.2
|
|
|
|
# @PACKAGE@_DEFINITIONS - defines to be made on the command line
|
2012-10-29 03:05:53 -05:00
|
|
|
# @PACKAGE@_INCLUDE_DIRS - header directories with which to compile
|
|
|
|
# @PACKAGE@_LIBRARY_DIRS - directories to search for libraries
|
|
|
|
# @PACKAGE@_LIBRARIES - names of the libraries with which to link
|
2012-10-19 07:14:15 -05:00
|
|
|
#
|
|
|
|
# You should put lines like this in your CMakeLists.txt
|
|
|
|
# set (@PACKAGE@_DIR "../@PACKAGE@" CACHE LOCATION "Build tree of @PACKAGE_NAME@")
|
|
|
|
# find_package (@PACKAGE@)
|
|
|
|
|
|
|
|
# <http://www.vtk.org/Wiki/CMake/Tutorials/How_to_create_a_ProjectConfig.cmake_file>
|
|
|
|
|
|
|
|
# propagate this property from one build system to the other
|
|
|
|
set (@PACKAGE@_VERSION @PACKAGE_VERSION@)
|
|
|
|
|
|
|
|
# these definitions may be necessary to make the header files behave the
|
|
|
|
# same way as they did when the library was compiled
|
|
|
|
set (@PACKAGE@_DEFINITIONS "@OPM_BOOST_CPPFLAGS@ @SUPERLU_CPPFLAGS@ @ERT_CPPFLAGS@")
|
|
|
|
|
|
|
|
# include files come from the source tree where the template is stored
|
|
|
|
set (@PACKAGE@_INCLUDE_DIRS "@abs_top_srcdir@")
|
|
|
|
|
|
|
|
# user programs should link with this library (see comment in the header)
|
|
|
|
set (@PACKAGE@_LIBRARIES "@PACKAGE@")
|
|
|
|
|
2012-10-29 03:05:53 -05:00
|
|
|
# convention is to have a variable named like this to add to link directories
|
|
|
|
set (@PACKAGE@_LIBRARY_DIRS "@abs_top_builddir@/lib/.libs")
|
|
|
|
|
2012-10-19 07:14:15 -05:00
|
|
|
# libraries come from the build tree where this file was generated
|
2012-10-29 03:05:53 -05:00
|
|
|
find_library (@PACKAGE@_LOCATION NAMES "@PACKAGE@" PATHS "${@PACKAGE@_LIBRARY_DIRS}")
|
2012-10-19 07:14:15 -05:00
|
|
|
mark_as_advanced (@PACKAGE@_LOCATION)
|
|
|
|
|
|
|
|
# add the library as a target, so that other things in the project including
|
|
|
|
# this file may depend on it and get rebuild if this library changes.
|
|
|
|
add_library (@PACKAGE@ UNKNOWN IMPORTED)
|
|
|
|
set_property (TARGET @PACKAGE@ PROPERTY IMPORTED_LOCATION "${@PACKAGE@_LOCATION}")
|