egl/dri2: Fix build of dri2 egl driver with SCons
authorAlexander von Gluck IV <kallisti5@unixzen.com>
Mon, 22 Dec 2014 16:27:35 +0000 (11:27 -0500)
committerAlexander von Gluck IV <kallisti5@unixzen.com>
Tue, 23 Dec 2014 14:07:58 +0000 (09:07 -0500)
* egl/dri2 was missing a SConscript
* Problem caught by Adrián Arroyo Calle

src/egl/drivers/dri2/SConscript [new file with mode: 0644]

diff --git a/src/egl/drivers/dri2/SConscript b/src/egl/drivers/dri2/SConscript
new file mode 100644 (file)
index 0000000..5b03107
--- /dev/null
@@ -0,0 +1,40 @@
+Import('*')
+
+env = env.Clone()
+
+env.Append(CPPDEFINES = [
+       'DEFAULT_DRIVER_DIR=\\"\\"'
+])
+
+env.Append(CPPPATH = [
+       '#/include',
+       '#/src/egl/main',
+       '#/src/loader',
+])
+
+sources = [
+       'egl_dri2.c',
+]
+
+if env['x11']:
+       sources.append('platform_x11.c')
+       env.Append(CPPDEFINES = [
+               'HAVE_X11_PLATFORM',
+       ])
+       #env.Append(CPPPATH = [
+       #       'XCB_DRI2_CFLAGS',
+       #])
+
+if env['drm']:
+       env.PkgUseModules('DRM')
+
+env.Prepend(LIBS = [
+       libloader,
+])
+
+egl_dri2 = env.ConvenienceLibrary(
+       target = 'egl_dri2',
+       source = sources,
+)
+
+Export('egl_dri2')