patch [#19796] GLEW update by Mitchell Stokes (Moguri)
[blender.git] / source / blender / blenkernel / SConscript
1 #!/usr/bin/python
2 Import ('env')
3
4 sources = env.Glob('intern/*.c')
5
6 incs = '. #/intern/guardedalloc #/intern/memutil ../editors/include ../blenlib ../blenfont ../makesdna'
7 incs += ' ../render/extern/include #/intern/decimation/extern ../makesrna'
8 incs += ' ../imbuf ../ikplugin ../avi #/intern/elbeem/extern ../nodes'
9 incs += ' #/intern/iksolver/extern ../blenloader'
10 incs += ' #/extern/bullet2/src'
11 incs += ' #/intern/opennl/extern #/intern/bsp/extern'
12 incs += ' ../gpu #/extern/glew/include'
13 incs += ' #/intern/smoke/extern'
14 incs += ' #/intern/audaspace/intern'
15
16 incs += ' ' + env['BF_OPENGL_INC']
17 incs += ' ' + env['BF_ZLIB_INC']
18
19 defs = [ 'GLEW_STATIC' ]
20
21 if not env['WITH_BF_PYTHON']:
22         defs.append('DISABLE_PYTHON')
23 else:
24         incs += ' ../python'
25         incs += ' ' + env['BF_PYTHON_INC']
26         if env['BF_DEBUG']:
27                 defs.append('_DEBUG')
28
29 if env['WITH_BF_QUICKTIME']:
30         incs += ' ../quicktime'
31
32 if env['WITH_BF_SDL']:
33         incs += ' ' + env['BF_SDL_INC']
34 else:
35         defs.append('DISABLE_SDL')
36
37 if env['WITH_BF_OPENEXR']:
38         defs.append('WITH_OPENEXR')
39
40 if env['WITH_BF_OPENJPEG']:
41         defs.append('WITH_OPENJPEG')
42
43 if env['WITH_BF_DDS']:
44         defs.append('WITH_DDS')
45
46 if env['WITH_BF_FFMPEG']:
47         defs.append('WITH_FFMPEG')
48         incs += ' ' + env['BF_FFMPEG_INC']
49
50 if env['WITH_BF_QUICKTIME']:
51         defs.append('WITH_QUICKTIME')
52         incs += ' ' + env['BF_QUICKTIME_INC']
53
54 if env['WITH_BF_BULLET']:
55         defs.append('USE_BULLET')
56
57 if env['BF_NO_ELBEEM']:
58         defs.append('DISABLE_ELBEEM')
59
60 if env['WITH_BF_LCMS']:
61         defs.append('WITH_LCMS')
62
63 if env['WITH_BF_LZO']:
64         incs += ' #/extern/lzo/minilzo'
65         defs.append('WITH_LZO')
66
67 if env['WITH_BF_LZMA']:
68         incs += ' #/extern/lzma'
69         defs.append('WITH_LZMA')
70
71 if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'linuxcross', 'win64-vc'):
72     incs += ' ' + env['BF_PTHREADS_INC']
73
74 env.BlenderLib ( libname = 'bf_blenkernel', sources = sources, includes = Split(incs), defines = defs, libtype=['core','player'], priority = [166,25] )