-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
64 lines (44 loc) · 1.23 KB
/
CMakeLists.txt
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
cmake_minimum_required(VERSION 2.8)
PROJECT(ImageLib)
LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
OPTION(BUILD_SHARED_LIBS "Build with shared (.DLL .SO) libraries." ON)
include(compat_flags)
# FIXME: config.h needs to be generated
#include(configh)
find_package(SDL)
if (SDL_FOUND)
add_definitions(-DILUT_USE_SDL)
endif()
find_package(LCMS)
find_package(MNG)
find_package(JPEG)
find_package(PNG)
find_package(TIFF)
find_package(ZLIB)
find_package(OPENEXR)
SET(DEVIL_INCS
${DEVIL_SOURCE_DIR}/include/IL/config.h
${DEVIL_SOURCE_DIR}/include/IL/devil_internal_exports.h
${DEVIL_SOURCE_DIR}/include/IL/il.h
${DEVIL_SOURCE_DIR}/include/IL/il_wrap.h
${DEVIL_SOURCE_DIR}/include/IL/ilu.h
${DEVIL_SOURCE_DIR}/include/IL/ilu_region.h
${DEVIL_SOURCE_DIR}/include/IL/ilut.h
)
SUBDIRS(
# src-XTRA
src-IL
src-ILU
src-ILUT
)
option(DEVIL_BUILD_EXAMPLES "build examples" OFF)
if (DEVIL_BUILD_EXAMPLES)
add_subdirectory( examples)
endif()
# need to check for vc6 or vc2003 output dir
IF(BUILD_SHARED_LIBS)
SET(DEVIL_LIB_DEST_DIR ${CMAKE_CURRENT_SOURCE_DIR}/lib/ )
ELSE(BUILD_SHARED_LIBS)
SET(DEVIL_LIB_DEST_DIR ${CMAKE_CURRENT_SOURCE_DIR}/lib/ )
ENDIF(BUILD_SHARED_LIBS)
EXPORT_LIBRARY_DEPENDENCIES(CMakeDepends.txt)