1 include $(top_srcdir)/src/gallium/Automake.inc
4 -I$(top_srcdir)/src/mapi \
5 -I$(top_srcdir)/src/mesa \
6 -I$(top_srcdir)/src/mesa/drivers/dri/common \
7 -I$(top_srcdir)/src/gallium/state_trackers/dri \
8 $(GALLIUM_TARGET_CFLAGS)
18 dridir = $(DRI_DRIVER_INSTALL_DIR)
19 dri_LTLIBRARIES = gallium_dri.la
21 nodist_EXTRA_gallium_dri_la_SOURCES = dummy.cpp
22 gallium_dri_la_SOURCES =
24 gallium_dri_la_LDFLAGS = \
31 if HAVE_LD_VERSION_SCRIPT
32 gallium_dri_la_LDFLAGS += \
33 -Wl,--version-script=$(top_srcdir)/src/gallium/targets/dri/dri.sym
34 endif # HAVE_LD_VERSION_SCRIPT
36 if HAVE_LD_DYNAMIC_LIST
37 gallium_dri_la_LDFLAGS += \
38 -Wl,--dynamic-list=$(top_srcdir)/src/gallium/targets/dri-vdpau.dyn
39 endif # HAVE_LD_DYNAMIC_LIST
41 gallium_dri_la_LIBADD = \
42 $(top_builddir)/src/mesa/libmesagallium.la \
43 $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \
44 $(top_builddir)/src/mesa/drivers/dri/common/libmegadriver_stub.la \
45 $(top_builddir)/src/gallium/state_trackers/dri/libdri.la \
46 $(top_builddir)/src/gallium/auxiliary/libgallium.la \
47 $(top_builddir)/src/gallium/drivers/galahad/libgalahad.la \
48 $(top_builddir)/src/gallium/drivers/noop/libnoop.la \
49 $(top_builddir)/src/gallium/drivers/rbug/librbug.la \
50 $(top_builddir)/src/gallium/drivers/trace/libtrace.la \
54 $(GALLIUM_COMMON_LIB_DEPS)
56 # XXX: Temporary allow duplicated symbols, as the loader pulls in xmlconfig.c
57 # which already provides driParse* and driQuery* amongst others.
58 # Remove this hack as we come up with a cleaner solution.
59 gallium_dri_la_LDFLAGS += \
60 -Wl,--allow-multiple-definition
63 STATIC_TARGET_CPPFLAGS =
64 STATIC_TARGET_LIB_DEPS = \
65 $(top_builddir)/src/loader/libloader.la
71 include $(top_srcdir)/src/gallium/drivers/i915/Automake.inc
73 include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc
75 include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc
77 include $(top_srcdir)/src/gallium/drivers/r300/Automake.inc
78 include $(top_srcdir)/src/gallium/drivers/r600/Automake.inc
79 include $(top_srcdir)/src/gallium/drivers/radeonsi/Automake.inc
81 include $(top_srcdir)/src/gallium/drivers/svga/Automake.inc
83 include $(top_srcdir)/src/gallium/drivers/freedreno/Automake.inc
85 include $(top_srcdir)/src/gallium/drivers/vc4/Automake.inc
87 if HAVE_GALLIUM_SOFTPIPE
89 STATIC_TARGET_CPPFLAGS += -DGALLIUM_SOFTPIPE
90 STATIC_TARGET_LIB_DEPS += \
91 $(top_builddir)/src/gallium/winsys/sw/dri/libswdri.la \
92 $(top_builddir)/src/gallium/drivers/softpipe/libsoftpipe.la
95 MEGADRIVERS += kms_swrast
96 STATIC_TARGET_LIB_DEPS += \
97 $(top_builddir)/src/gallium/winsys/sw/kms-dri/libswkmsdri.la
101 if NEED_GALLIUM_LLVMPIPE_DRIVER
102 STATIC_TARGET_CPPFLAGS += -DGALLIUM_LLVMPIPE
103 STATIC_TARGET_LIB_DEPS += \
104 $(top_builddir)/src/gallium/drivers/llvmpipe/libllvmpipe.la
107 if HAVE_GALLIUM_STATIC_TARGETS
109 gallium_dri_la_SOURCES += target.c
110 AM_CPPFLAGS += $(STATIC_TARGET_CPPFLAGS) $(TARGET_CPPFLAGS)
111 gallium_dri_la_LIBADD += $(STATIC_TARGET_LIB_DEPS) $(TARGET_LIB_DEPS) \
112 $(TARGET_RADEON_WINSYS) $(TARGET_RADEON_COMMON)
114 else # HAVE_GALLIUM_STATIC_TARGETS
116 gallium_dri_la_LIBADD += \
117 $(top_builddir)/src/gallium/auxiliary/pipe-loader/libpipe_loader.la \
118 $(GALLIUM_PIPE_LOADER_WINSYS_LIBS) \
119 $(GALLIUM_PIPE_LOADER_LIBS)
121 endif # HAVE_GALLIUM_STATIC_TARGETS
124 gallium_dri_la_LIBADD += $(LLVM_LIBS)
125 gallium_dri_la_LDFLAGS += $(LLVM_LDFLAGS)
128 if HAVE_COMPAT_SYMLINKS
129 # Add a link to allow setting LIBGL_DRIVERS_PATH to /lib/gallium of the build tree.
130 all-local: $(dri_LTLIBRARIES)
131 $(AM_V_GEN)link_dir=$(top_builddir)/$(LIB_DIR)/gallium; \
132 $(MKDIR_P) $${link_dir}; \
133 for i in $(MEGADRIVERS) $(TARGET_DRIVERS); do \
137 $${link_dir}/$${k}; \
141 # hardlink each megadriver instance, but don't actually have
142 # gallium_dri.so in the set of final installed files.
144 $(AM_V_GEN)dest_dir=$(DESTDIR)/$(dridir); \
145 for i in $(MEGADRIVERS) $(TARGET_DRIVERS); do \
148 ln -f $${dest_dir}/$${j} \
149 $${dest_dir}/$${k}; \
151 $(RM) -f $$dest_dir/gallium_dri.*