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.veli...@gmail.com> --- src/gallium/drivers/ilo/Automake.inc | 11 +++++++++++ src/gallium/targets/dri/Makefile.am | 9 +-------- src/gallium/targets/egl-static/Makefile.am | 8 +------- src/gallium/targets/gbm/Makefile.am | 8 +------- src/gallium/targets/xa/Makefile.am | 8 +------- 5 files changed, 15 insertions(+), 29 deletions(-) create mode 100644 src/gallium/drivers/ilo/Automake.inc diff --git a/src/gallium/drivers/ilo/Automake.inc b/src/gallium/drivers/ilo/Automake.inc new file mode 100644 index 0000000..5124671 --- /dev/null +++ b/src/gallium/drivers/ilo/Automake.inc @@ -0,0 +1,11 @@ +if HAVE_GALLIUM_ILO + +TARGET_DRIVERS += ilo +TARGET_CPPFLAGS += -DGALLIUM_ILO +TARGET_LIB_DEPS += \ + $(top_builddir)/src/gallium/winsys/intel/drm/libintelwinsys.la \ + $(top_builddir)/src/gallium/drivers/ilo/libilo.la \ + $(INTEL_LIBS) \ + $(LIBDRM_LIBS) + +endif diff --git a/src/gallium/targets/dri/Makefile.am b/src/gallium/targets/dri/Makefile.am index 9fabdc2..f76a953 100644 --- a/src/gallium/targets/dri/Makefile.am +++ b/src/gallium/targets/dri/Makefile.am @@ -70,14 +70,7 @@ TARGET_LIB_DEPS = include $(top_srcdir)/src/gallium/drivers/i915/Automake.inc -if HAVE_GALLIUM_ILO -MEGADRIVERS += ilo -STATIC_TARGET_CPPFLAGS += -DGALLIUM_ILO -STATIC_TARGET_LIB_DEPS += \ - $(top_builddir)/src/gallium/winsys/intel/drm/libintelwinsys.la \ - $(top_builddir)/src/gallium/drivers/ilo/libilo.la \ - $(INTEL_LIBS) -endif +include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc diff --git a/src/gallium/targets/egl-static/Makefile.am b/src/gallium/targets/egl-static/Makefile.am index 9f87677..43feb63 100644 --- a/src/gallium/targets/egl-static/Makefile.am +++ b/src/gallium/targets/egl-static/Makefile.am @@ -163,13 +163,7 @@ TARGET_LIB_DEPS = include $(top_srcdir)/src/gallium/drivers/i915/Automake.inc -if HAVE_GALLIUM_ILO -egl_gallium_la_CPPFLAGS += -DGALLIUM_ILO -egl_gallium_la_LIBADD += \ - $(top_builddir)/src/gallium/winsys/intel/drm/libintelwinsys.la \ - $(top_builddir)/src/gallium/drivers/ilo/libilo.la \ - $(INTEL_LIBS) -endif +include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc diff --git a/src/gallium/targets/gbm/Makefile.am b/src/gallium/targets/gbm/Makefile.am index 2ac04c8..53f8c1a 100644 --- a/src/gallium/targets/gbm/Makefile.am +++ b/src/gallium/targets/gbm/Makefile.am @@ -62,13 +62,7 @@ TARGET_LIB_DEPS = include $(top_srcdir)/src/gallium/drivers/i915/Automake.inc -if HAVE_GALLIUM_ILO -STATIC_TARGET_CPPFLAGS += -DGALLIUM_ILO -STATIC_TARGET_LIB_DEPS += \ - $(top_builddir)/src/gallium/winsys/intel/drm/libintelwinsys.la \ - $(top_builddir)/src/gallium/drivers/ilo/libilo.la \ - $(INTEL_LIBS) -endif +include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc diff --git a/src/gallium/targets/xa/Makefile.am b/src/gallium/targets/xa/Makefile.am index c03edd4..a76ea8d 100644 --- a/src/gallium/targets/xa/Makefile.am +++ b/src/gallium/targets/xa/Makefile.am @@ -63,13 +63,7 @@ TARGET_LIB_DEPS = include $(top_srcdir)/src/gallium/drivers/i915/Automake.inc -if HAVE_GALLIUM_ILO -STATIC_TARGET_CPPFLAGS += -DGALLIUM_ILO -STATIC_TARGET_LIB_DEPS += \ - $(top_builddir)/src/gallium/winsys/intel/drm/libintelwinsys.la \ - $(top_builddir)/src/gallium/drivers/ilo/libilo.la \ - $(INTEL_LIBS) -endif +include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc -- 2.1.0 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev