st/nine: Refactor how user constbufs sizes are calculated
[mesa.git] / src / gallium / state_trackers / egl / SConscript
1 #######################################################################
2 # SConscript for egl state_tracker
3
4 Import('*')
5
6 env = env.Clone()
7
8 env.Append(CPPPATH = [
9 '#/src/egl/main',
10 '#/src/gallium/winsys',
11 '#/src/gallium/winsys/sw',
12 '.',
13 ])
14
15 sources = env.ParseSourceList('Makefile.sources', 'common_FILES')
16
17 # OpenGL ES and OpenGL
18 if env['gles']:
19 env.Append(CPPDEFINES = [
20 'FEATURE_GL=1',
21 'FEATURE_ES1=1',
22 'FEATURE_ES2=1'
23 ])
24
25 # OpenVG
26 if True:
27 env.Append(CPPDEFINES = ['FEATURE_VG=1'])
28
29 if env['platform'] == 'windows':
30 env.Append(CPPDEFINES = ['HAVE_GDI_BACKEND'])
31 sources.append(env.ParseSourceList('Makefile.sources', 'gdi_FILES'))
32 else:
33 if env['drm']:
34 env.PkgUseModules('DRM')
35 if env['x11']:
36 env.Append(CPPDEFINES = ['HAVE_X11_BACKEND'])
37 env.Prepend(CPPPATH = [
38 '#/src/glx',
39 '#/src/mapi',
40 ])
41 sources.append(env.ParseSourceList('Makefile.sources', 'x11_FILES'))
42 if env['drm']:
43 env.Append(CPPDEFINES = ['GLX_DIRECT_RENDERING'])
44 sources.append(env.ParseSourceList('Makefile.sources', 'x11_drm_FILES'))
45 if env['drm'] and False:
46 # XXX: Disabled as it depends on gbm, which is not yet built with scons
47 env.Append(CPPDEFINES = ['HAVE_DRM_BACKEND'])
48 env.Append(CPPPATH = [
49 '#/src/loader',
50 '#/src/gbm/main',
51 '#/src/gallium/state_trackers/gbm',
52 ])
53 env.Prepend(LIBS = [
54 libloader
55 ])
56 sources.append(env.ParseSourceList('Makefile.sources', 'drm_FILES'))
57
58 st_egl = env.ConvenienceLibrary(
59 target = 'st_egl',
60 source = sources,
61 )
62 Export('st_egl')