Merge branch 'master' into blender2.8
[blender.git] / source / blender / windowmanager / CMakeLists.txt
1 # ***** BEGIN GPL LICENSE BLOCK *****
2 #
3 # This program is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU General Public License
5 # as published by the Free Software Foundation; either version 2
6 # of the License, or (at your option) any later version.
7 #
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 # GNU General Public License for more details.
12 #
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software Foundation,
15 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
16 #
17 # The Original Code is Copyright (C) 2006, Blender Foundation
18 # All rights reserved.
19 #
20 # The Original Code is: all of this file.
21 #
22 # Contributor(s): Jacques Beaurain.
23 #
24 # ***** END GPL LICENSE BLOCK *****
25
26 set(INC
27         .
28         manipulators
29         manipulators/intern
30         ../blenfont
31         ../blenkernel
32         ../blenlib
33         ../blenloader
34         ../blentranslation
35         ../compositor
36         ../depsgraph
37         ../editors/include
38         ../draw
39         ../gpu
40         ../imbuf
41         ../makesdna
42         ../makesrna
43         ../nodes
44         ../render/extern/include
45         ../../../intern/clog
46         ../../../intern/ghost
47         ../../../intern/guardedalloc
48         ../../../intern/glew-mx
49         ../../../intern/memutil
50 )
51
52 set(INC_SYS
53         ${ZLIB_INCLUDE_DIRS}
54         ${GLEW_INCLUDE_PATH}
55 )
56
57 set(SRC
58         intern/wm.c
59         intern/wm_cursors.c
60         intern/wm_dragdrop.c
61         intern/wm_draw.c
62         intern/wm_event_system.c
63         intern/wm_files.c
64         intern/wm_files_link.c
65         intern/wm_gesture.c
66         intern/wm_gesture_ops.c
67         intern/wm_init_exit.c
68         intern/wm_jobs.c
69         intern/wm_keymap.c
70         intern/wm_menu_type.c
71         intern/wm_operator_props.c
72         intern/wm_operator_type.c
73         intern/wm_operators.c
74         intern/wm_playanim.c
75         intern/wm_stereo.c
76         intern/wm_subwindow.c
77         intern/wm_toolsystem.c
78         intern/wm_tooltip.c
79         intern/wm_uilist_type.c
80         intern/wm_window.c
81         manipulators/intern/wm_manipulator.c
82         manipulators/intern/wm_manipulator_group.c
83         manipulators/intern/wm_manipulator_group_type.c
84         manipulators/intern/wm_manipulator_map.c
85         manipulators/intern/wm_manipulator_target_props.c
86         manipulators/intern/wm_manipulator_type.c
87         message_bus/intern/wm_message_bus.c
88         message_bus/intern/wm_message_bus_rna.c
89         message_bus/intern/wm_message_bus_static.c
90
91         WM_api.h
92         WM_keymap.h
93         WM_toolsystem.h
94         WM_types.h
95         wm.h
96         wm_cursors.h
97         wm_draw.h
98         wm_event_system.h
99         wm_event_types.h
100         wm_files.h
101         wm_window.h
102         manipulators/WM_manipulator_api.h
103         manipulators/WM_manipulator_types.h
104         manipulators/wm_manipulator_fn.h
105         manipulators/wm_manipulator_wmapi.h
106         manipulators/intern/wm_manipulator_intern.h
107         message_bus/intern/wm_message_bus_intern.h
108         message_bus/wm_message_bus.h
109 )
110
111 if(WITH_AUDASPACE)
112         add_definitions(-DWITH_AUDASPACE)
113
114         list(APPEND INC_SYS
115                 ${AUDASPACE_C_INCLUDE_DIRS}
116         )
117 endif()
118
119 add_definitions(${GL_DEFINITIONS})
120
121 if(WITH_INTERNATIONAL)
122         add_definitions(-DWITH_INTERNATIONAL)
123 endif()
124
125 if(WITH_OPENCOLLADA)
126         add_definitions(-DWITH_COLLADA)
127 endif()
128
129 if(WITH_CODEC_FFMPEG)
130         list(APPEND INC_SYS
131                 ${FFMPEG_INCLUDE_DIRS}
132         )
133         add_definitions(-DWITH_FFMPEG)
134 endif()
135
136 if(WITH_HEADLESS)
137         add_definitions(-DWITH_HEADLESS)
138 elseif(WITH_X11)
139         add_definitions(-DWITH_X11)
140 endif()
141
142 if(WITH_PYTHON)
143         list(APPEND INC
144                 ../python
145         )
146         add_definitions(-DWITH_PYTHON)
147 endif()
148
149 if(WITH_BUILDINFO)
150         add_definitions(-DWITH_BUILDINFO)
151 endif()
152
153 if(WITH_OPENSUBDIV)
154         add_definitions(-DWITH_OPENSUBDIV)
155 endif()
156
157 if(WITH_INPUT_NDOF)
158         add_definitions(-DWITH_INPUT_NDOF)
159 endif()
160
161 if(WIN32)
162         if(WITH_INPUT_IME)
163                 add_definitions(-DWITH_INPUT_IME)
164         endif()
165 endif()
166
167 if(WITH_COMPOSITOR)
168         add_definitions(-DWITH_COMPOSITOR)
169 endif()
170
171 blender_add_lib_nolist(bf_windowmanager "${SRC}" "${INC}" "${INC_SYS}")