gallium/svga: add automake target 'template'
authorEmil Velikov <emil.l.velikov@gmail.com>
Sun, 21 Sep 2014 14:41:51 +0000 (15:41 +0100)
committerEmil Velikov <emil.l.velikov@gmail.com>
Wed, 24 Sep 2014 09:44:00 +0000 (10:44 +0100)
Rather than duplicating the libdeps, extra define... all over the
targets, define them only once and use when applicable.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Acked-by: Matt Turner <mattst88@gmail.com>
src/gallium/drivers/svga/Automake.inc [new file with mode: 0644]
src/gallium/targets/dri/Makefile.am
src/gallium/targets/egl-static/Makefile.am
src/gallium/targets/gbm/Makefile.am
src/gallium/targets/xa/Makefile.am

diff --git a/src/gallium/drivers/svga/Automake.inc b/src/gallium/drivers/svga/Automake.inc
new file mode 100644 (file)
index 0000000..d2d1d8f
--- /dev/null
@@ -0,0 +1,10 @@
+if HAVE_GALLIUM_SVGA
+
+TARGET_DRIVERS += vmwgfx
+TARGET_CPPFLAGS += -DGALLIUM_VMWGFX
+TARGET_LIB_DEPS += \
+       $(top_builddir)/src/gallium/winsys/svga/drm/libsvgadrm.la \
+       $(top_builddir)/src/gallium/drivers/svga/libsvga.la \
+       $(LIBDRM_LIBS)
+
+endif
index f76a953148d9ffeb3c0a9e8c590a8bd462d35031..cf4a0252fb0ebb42bca27894e6224125701593a4 100644 (file)
@@ -108,13 +108,7 @@ STATIC_TARGET_LIB_DEPS += \
        $(RADEON_LIBS)
 endif
 
-if HAVE_GALLIUM_SVGA
-MEGADRIVERS += vmwgfx
-STATIC_TARGET_CPPFLAGS += -DGALLIUM_VMWGFX
-STATIC_TARGET_LIB_DEPS += \
-       $(top_builddir)/src/gallium/winsys/svga/drm/libsvgadrm.la \
-       $(top_builddir)/src/gallium/drivers/svga/libsvga.la
-endif
+include $(top_srcdir)/src/gallium/drivers/svga/Automake.inc
 
 include $(top_srcdir)/src/gallium/drivers/freedreno/Automake.inc
 
index 0d231a5914ecdd33c1a1c8ce0b9c4f0686bbbac7..507c9574d28568800ec32e8cf45f5ea5d178b1d2 100644 (file)
@@ -198,12 +198,7 @@ egl_gallium_la_LIBADD += \
        $(RADEON_LIBS)
 endif
 
-if HAVE_GALLIUM_SVGA
-egl_gallium_la_CPPFLAGS += -DGALLIUM_VMWGFX
-egl_gallium_la_LIBADD += \
-       $(top_builddir)/src/gallium/winsys/svga/drm/libsvgadrm.la \
-       $(top_builddir)/src/gallium/drivers/svga/libsvga.la
-endif
+include $(top_srcdir)/src/gallium/drivers/svga/Automake.inc
 
 include $(top_srcdir)/src/gallium/drivers/freedreno/Automake.inc
 
index b7602cc6fda6fb2e8f1ff896f12d05c8e74dcf7e..f1166f0d631d47ff3d1d9b5a20dc7acb376c97dc 100644 (file)
@@ -97,12 +97,7 @@ STATIC_TARGET_LIB_DEPS += \
        $(RADEON_LIBS)
 endif
 
-if HAVE_GALLIUM_SVGA
-STATIC_TARGET_CPPFLAGS += -DGALLIUM_VMWGFX
-STATIC_TARGET_LIB_DEPS += \
-       $(top_builddir)/src/gallium/winsys/svga/drm/libsvgadrm.la \
-       $(top_builddir)/src/gallium/drivers/svga/libsvga.la
-endif
+include $(top_srcdir)/src/gallium/drivers/svga/Automake.inc
 
 include $(top_srcdir)/src/gallium/drivers/freedreno/Automake.inc
 
index a76ea8dd3183c59c8332061fd48d6f98b02d7787..e26b43aaa4167dd46daae7ef38af3ec4abcd1f18 100644 (file)
@@ -67,12 +67,7 @@ include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc
 
 include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc
 
-if HAVE_GALLIUM_SVGA
-STATIC_TARGET_CPPFLAGS += -DGALLIUM_VMWGFX
-STATIC_TARGET_LIB_DEPS += \
-       $(top_builddir)/src/gallium/winsys/svga/drm/libsvgadrm.la \
-       $(top_builddir)/src/gallium/drivers/svga/libsvga.la
-endif
+include $(top_srcdir)/src/gallium/drivers/svga/Automake.inc
 
 include $(top_srcdir)/src/gallium/drivers/freedreno/Automake.inc