CMake: add WITH_LINKER_LLD option for unix platforms
[blender-staging.git] / source / blender / modifiers / 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 # ***** END GPL LICENSE BLOCK *****
20
21 set(INC
22   .
23   intern
24   ../blenfont
25   ../blenkernel
26   ../blenlib
27   ../bmesh
28   ../depsgraph
29   ../makesdna
30   ../makesrna
31   ../render/extern/include
32   ../../../intern/eigen
33   ../../../intern/guardedalloc
34 )
35
36 set(INC_SYS
37   ${ZLIB_INCLUDE_DIRS}
38 )
39
40 set(SRC
41   intern/MOD_armature.c
42   intern/MOD_array.c
43   intern/MOD_bevel.c
44   intern/MOD_boolean.c
45   intern/MOD_build.c
46   intern/MOD_cast.c
47   intern/MOD_cloth.c
48   intern/MOD_collision.c
49   intern/MOD_correctivesmooth.c
50   intern/MOD_curve.c
51   intern/MOD_datatransfer.c
52   intern/MOD_decimate.c
53   intern/MOD_displace.c
54   intern/MOD_dynamicpaint.c
55   intern/MOD_edgesplit.c
56   intern/MOD_explode.c
57   intern/MOD_fluid.c
58   intern/MOD_hook.c
59   intern/MOD_laplaciandeform.c
60   intern/MOD_laplaciansmooth.c
61   intern/MOD_lattice.c
62   intern/MOD_mask.cc
63   intern/MOD_meshcache.c
64   intern/MOD_meshcache_mdd.c
65   intern/MOD_meshcache_pc2.c
66   intern/MOD_meshcache_util.c
67   intern/MOD_meshdeform.c
68   intern/MOD_meshsequencecache.c
69   intern/MOD_mirror.c
70   intern/MOD_multires.c
71   intern/MOD_none.c
72   intern/MOD_normal_edit.c
73   intern/MOD_ocean.c
74   intern/MOD_particleinstance.c
75   intern/MOD_particlesystem.c
76   intern/MOD_remesh.c
77   intern/MOD_screw.c
78   intern/MOD_shapekey.c
79   intern/MOD_shrinkwrap.c
80   intern/MOD_simpledeform.c
81   intern/MOD_skin.c
82   intern/MOD_smooth.c
83   intern/MOD_softbody.c
84   intern/MOD_solidify.c
85   intern/MOD_solidify_extrude.c
86   intern/MOD_solidify_nonmanifold.c
87   intern/MOD_subsurf.c
88   intern/MOD_surface.c
89   intern/MOD_surfacedeform.c
90   intern/MOD_triangulate.c
91   intern/MOD_util.c
92   intern/MOD_uvproject.c
93   intern/MOD_uvwarp.c
94   intern/MOD_warp.c
95   intern/MOD_wave.c
96   intern/MOD_weighted_normal.c
97   intern/MOD_weightvg_util.c
98   intern/MOD_weightvgedit.c
99   intern/MOD_weightvgmix.c
100   intern/MOD_weightvgproximity.c
101   intern/MOD_weld.c
102   intern/MOD_wireframe.c
103
104   MOD_modifiertypes.h
105   intern/MOD_meshcache_util.h
106   intern/MOD_solidify_util.h
107   intern/MOD_util.h
108   intern/MOD_weightvg_util.h
109 )
110
111 set(LIB
112   bf_blenkernel
113   bf_blenlib
114 )
115
116 if(WITH_ALEMBIC)
117   add_definitions(-DWITH_ALEMBIC)
118   list(APPEND INC
119     ../io/alembic
120   )
121   list(APPEND LIB
122     bf_alembic
123   )
124 endif()
125
126 if(WITH_MOD_REMESH)
127   list(APPEND INC
128     ../../../intern/dualcon
129   )
130   list(APPEND LIB
131     bf_intern_dualcon
132   )
133   add_definitions(-DWITH_MOD_REMESH)
134 endif()
135
136 if(WITH_MOD_FLUID)
137   add_definitions(-DWITH_FLUID)
138 endif()
139
140 if(WITH_MOD_OCEANSIM)
141   add_definitions(-DWITH_OCEANSIM)
142 endif()
143
144 if(WITH_OPENSUBDIV)
145   add_definitions(-DWITH_OPENSUBDIV)
146 endif()
147
148 if(WITH_BULLET)
149   list(APPEND LIB
150     extern_bullet
151   )
152   add_definitions(-DWITH_BULLET)
153 endif()
154
155 if(WITH_INTERNATIONAL)
156   add_definitions(-DWITH_INTERNATIONAL)
157 endif()
158
159 # So we can have special tricks in modifier system.
160 add_definitions(${GL_DEFINITIONS})
161
162 blender_add_lib(bf_modifiers "${SRC}" "${INC}" "${INC_SYS}" "${LIB}")