scons: r300/r600 now depends on libdrm.
[mesa.git] / src / gallium / SConscript
1 Import('env')
2
3 #
4 # Auxiliary modules
5 #
6
7 SConscript('auxiliary/SConscript')
8
9 #
10 # Drivers
11 #
12
13 # These are common and work across all platforms
14 SConscript([
15 'drivers/galahad/SConscript',
16 'drivers/identity/SConscript',
17 'drivers/llvmpipe/SConscript',
18 'drivers/rbug/SConscript',
19 'drivers/softpipe/SConscript',
20 'drivers/svga/SConscript',
21 'drivers/trace/SConscript',
22 ])
23
24 if not env['msvc']:
25 # These drivers do not build on MSVC compilers
26 SConscript([
27 'drivers/i915/SConscript',
28 ])
29
30 if env['drm']:
31 # These drivers depend on drm headers
32 if env['drm_radeon']:
33 SConscript([
34 'drivers/r300/SConscript',
35 'drivers/r600/SConscript',
36 ])
37 # XXX: nouveau drivers have a tight dependency on libdrm, so to enable
38 # we need some version logic before we enable them. Also, ATM there is
39 # no nouveau target in scons
40 # if env['drm_nouveau']:
41 # SConscript([
42 # 'drivers/nouveau/SConscript',
43 # 'drivers/nv50/SConscript',
44 # 'drivers/nvc0/SConscript',
45 # 'drivers/nvfx/SConscript',
46 # ])
47
48 #
49 # State trackers
50 #
51
52 # Needed by some state trackers
53 SConscript('winsys/sw/null/SConscript')
54
55 if not env['embedded']:
56 SConscript('state_trackers/vega/SConscript')
57 if env['platform'] not in ['darwin', 'haiku']:
58 SConscript('state_trackers/egl/SConscript')
59
60 if env['x11']:
61 SConscript('state_trackers/glx/xlib/SConscript')
62
63 if env['dri']:
64 SConscript('state_trackers/dri/SConscript')
65
66 if env['dri'] and env['xorg']:
67 SConscript('state_trackers/xorg/SConscript')
68
69 if env['platform'] == 'windows':
70 SConscript('state_trackers/wgl/SConscript')
71
72 #
73 # Winsys
74 #
75
76 SConscript([
77 'winsys/sw/wrapper/SConscript',
78 ])
79
80 if env['x11']:
81 SConscript([
82 'winsys/sw/xlib/SConscript',
83 ])
84
85 if env['platform'] == 'windows':
86 SConscript([
87 'winsys/sw/gdi/SConscript',
88 ])
89
90 if not env['msvc']:
91 SConscript([
92 'winsys/i915/sw/SConscript',
93 ])
94
95 if env['dri']:
96 SConscript([
97 'winsys/sw/dri/SConscript',
98 ])
99
100 SConscript([
101 'winsys/svga/drm/SConscript',
102 ])
103
104 if env['drm_intel']:
105 SConscript([
106 'winsys/i915/drm/SConscript',
107 ])
108
109 if env['drm_radeon']:
110 SConscript([
111 'winsys/radeon/drm/SConscript',
112 ])
113
114 #
115 # Targets
116 #
117
118 SConscript([
119 'targets/graw-null/SConscript',
120 ])
121
122 if not env['embedded']:
123 if env['platform'] not in ['darwin', 'haiku']:
124 SConscript([
125 'targets/egl-static/SConscript'
126 ])
127
128 if env['x11']:
129 SConscript([
130 'targets/graw-xlib/SConscript',
131 'targets/libgl-xlib/SConscript',
132 ])
133
134 if env['platform'] == 'windows':
135 SConscript([
136 'targets/graw-gdi/SConscript',
137 'targets/libgl-gdi/SConscript',
138 ])
139
140 if env['dri']:
141 SConscript([
142 'targets/SConscript.dri',
143 'targets/dri-swrast/SConscript',
144 'targets/dri-vmwgfx/SConscript',
145 #'targets/dri-nouveau/SConscript',
146 ])
147 if env['drm_intel']:
148 SConscript([
149 'targets/dri-i915/SConscript',
150 ])
151 if env['drm_radeon']:
152 SConscript([
153 'targets/dri-r300/SConscript',
154 'targets/dri-r600/SConscript',
155 ])
156
157 if env['xorg'] and env['drm']:
158 SConscript([
159 #'targets/xorg-i915/SConscript',
160 #'targets/xorg-nouveau/SConscript',
161 #'targets/xorg-radeon/SConscript',
162 ])
163
164
165 #
166 # Unit tests & tools
167 #
168
169 if not env['embedded']:
170 SConscript('tests/unit/SConscript')
171 SConscript('tests/graw/SConscript')