forked from openslide/openslide
-
Notifications
You must be signed in to change notification settings - Fork 6
/
OpenslideConfig.cmake.in
45 lines (37 loc) · 2.37 KB
/
OpenslideConfig.cmake.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Config file for the Openslide package
get_filename_component(Openslide_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
list(APPEND CMAKE_MODULE_PATH "${Openslide_CMAKE_DIR}")
include(FindPackageHandleStandardArgs)
include(CMakeFindDependencyMacro)
find_dependency(TIFF)
find_dependency(GLIB)
find_dependency(Cairo)
find_dependency(GDK-PixBuf)
find_dependency(JPEG)
find_dependency(OpenJPEG)
find_dependency(SQLite3)
find_dependency(LibXml2)
find_dependency(ZLIB)
find_dependency(PNG)
find_dependency(GLIB)
if(MSVC)
set(CMAKE_CXX_FLAGS "/wd4018 /wd4244 /wd4267 /wd4305 ${CMAKE_CXX_FLAGS}")
endif()
# Our library dependencies (contains definitions for IMPORTED targets)
include("${Openslide_CMAKE_DIR}/OpenslideTargets.cmake")
include("${Openslide_CMAKE_DIR}/OpenslideConfigVersion.cmake")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${TIFF_INCLUDE_DIRS}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${GLIB_INCLUDE_DIRS}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${Cairo_INCLUDE_DIRS}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${GDK-PixBuf_INCLUDE_DIRS}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${JPEG_INCLUDE_DIRS}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${OpenJPEG_INCLUDE_DIR}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${SQLite3_INCLUDE_DIRS}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${LIBXML2_INCLUDE_DIR}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${ZLIB_INCLUDE_DIR}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${PNG_INCLUDE_DIR}")
set_property(TARGET Openslide::openslide APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES "${GLIB_INCLUDE_DIR}")
get_target_property(FULL_Openslide_INCLUDE_DIRS Openslide::openslide INTERFACE_INCLUDE_DIRECTORIES)
list(GET FULL_Openslide_INCLUDE_DIRS 0 Openslide_INCLUDE_DIR)
get_filename_component(Openslide_INCLUDE_DIR "${Openslide_INCLUDE_DIR}" REALPATH)
find_package_handle_standard_args(Openslide REQUIRED_VARS Openslide_INCLUDE_DIR VERSION_VAR PACKAGE_VERSION)