libdricommon.la is available whenever a non swrast driver is built.
All the classic dri drivers make use of the prebuild library but all
of the gallium ones rebuild it explicitly.
While we're here gallium/{llvm,soft}pipe does not require HAVE_COMMON_DRI
thus do not set in during configure.
v2: [Emil] Add commit message and drop HAVE_COMMON_DRI from configure.ac
v3: [Emil] Rebase and resolve targets/r*/dri conflicts
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
if test "x$enable_dri" = xyes; then
GALLIUM_TARGET_DIRS="$GALLIUM_TARGET_DIRS dri-swrast"
- HAVE_COMMON_DRI=yes
fi
if test "x$enable_vdpau" = xyes; then
GALLIUM_TARGET_DIRS="$GALLIUM_TARGET_DIRS vdpau-softpipe"
dridir = $(DRI_DRIVER_INSTALL_DIR)
dri_LTLIBRARIES = kgsl_dri.la msm_dri.la
-COMMON_SOURCES = \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
-
COMMON_LDFLAGS = -module -avoid-version -shared -no-undefined
COMMON_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/state_trackers/dri/drm/libdridrm.la \
endif
nodist_EXTRA_kgsl_dri_la_SOURCES = dummy.cpp
-kgsl_dri_la_SOURCES = target-kgsl.c $(COMMON_SOURCES)
+kgsl_dri_la_SOURCES = target-kgsl.c
kgsl_dri_la_LDFLAGS = $(COMMON_LDFLAGS)
kgsl_dri_la_LIBADD = $(COMMON_LIBADD)
nodist_EXTRA_msm_dri_la_SOURCES = dummy.cpp
-msm_dri_la_SOURCES = target-msm.c $(COMMON_SOURCES)
+msm_dri_la_SOURCES = target-msm.c
msm_dri_la_LDFLAGS = $(COMMON_LDFLAGS)
msm_dri_la_LIBADD = $(COMMON_LIBADD)
dridir = $(DRI_DRIVER_INSTALL_DIR)
dri_LTLIBRARIES = i915_dri.la
-i915_dri_la_SOURCES = \
- target.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+i915_dri_la_SOURCES = target.c
i915_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined
i915_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/state_trackers/dri/drm/libdridrm.la \
noinst_LTLIBRARIES = ilo_dri.la
-ilo_dri_la_SOURCES = \
- target.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+ilo_dri_la_SOURCES = target.c
# need -rpath to create a noinst shared library
ilo_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined \
-rpath $(abs_builddir)
ilo_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/state_trackers/dri/drm/libdridrm.la \
dri_LTLIBRARIES = nouveau_dri.la
nodist_EXTRA_nouveau_dri_la_SOURCES = dummy.cpp
-nouveau_dri_la_SOURCES = \
- target.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+nouveau_dri_la_SOURCES = target.c
nouveau_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined
nouveau_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/state_trackers/dri/drm/libdridrm.la \
vmwgfx_dri_la_SOURCES = \
target.c \
- vmw_powf.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+ vmw_powf.c
vmwgfx_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined
vmwgfx_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/state_trackers/dri/drm/libdridrm.la \
nodist_EXTRA_r300_dri_la_SOURCES = dummy.cpp
r300_dri_la_SOURCES = \
- ../drm_target.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+ ../drm_target.c
r300_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined
r300_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/state_trackers/dri/drm/libdridrm.la \
dri_LTLIBRARIES = r600_dri.la
r600_dri_la_SOURCES = \
- ../drm_target.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+ ../drm_target.c
r600_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined
r600_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/drivers/r600/libr600.la \
nodist_EXTRA_radeonsi_dri_la_SOURCES = dummy.cpp
radeonsi_dri_la_SOURCES = \
- ../drm_target.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/utils.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/dri_util.c \
- $(top_srcdir)/src/mesa/drivers/dri/common/xmlconfig.c
+ ../drm_target.c
radeonsi_dri_la_LDFLAGS = -module -avoid-version -shared -no-undefined
radeonsi_dri_la_LIBADD = \
+ $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
$(top_builddir)/src/mesa/libmesagallium.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/gallium/drivers/radeonsi/libradeonsi.la \