1include $(top_srcdir)/src/gallium/Automake.inc 2 3if HAVE_ANDROID 4if HAVE_SHARED_GLAPI 5SHARED_GLAPI_LIB = $(top_builddir)/src/mapi/shared-glapi/libglapi.la 6endif 7endif 8 9AM_CFLAGS = \ 10 -I$(top_srcdir)/src/mapi \ 11 -I$(top_srcdir)/src/mesa \ 12 -I$(top_srcdir)/src \ 13 -I$(top_srcdir)/src/mesa/drivers/dri/common \ 14 -I$(top_srcdir)/src/gallium/state_trackers/dri \ 15 $(GALLIUM_TARGET_CFLAGS) 16 17AM_CPPFLAGS = \ 18 $(DEFINES) \ 19 -DGALLIUM_DDEBUG \ 20 -DGALLIUM_NOOP \ 21 -DGALLIUM_RBUG \ 22 -DGALLIUM_TRACE 23 24dridir = $(DRI_DRIVER_INSTALL_DIR) 25dri_LTLIBRARIES = gallium_dri.la 26 27nodist_EXTRA_gallium_dri_la_SOURCES = dummy.cpp 28gallium_dri_la_SOURCES = 29 30gallium_dri_la_LDFLAGS = \ 31 -shared \ 32 -shrext .so \ 33 -module \ 34 -avoid-version \ 35 $(GC_SECTIONS) 36 37if HAVE_LD_VERSION_SCRIPT 38gallium_dri_la_LDFLAGS += \ 39 -Wl,--version-script=$(top_srcdir)/src/gallium/targets/dri/dri.sym 40endif # HAVE_LD_VERSION_SCRIPT 41 42if HAVE_LD_DYNAMIC_LIST 43gallium_dri_la_LDFLAGS += \ 44 -Wl,--dynamic-list=$(top_srcdir)/src/gallium/targets/dri-vdpau.dyn 45endif # HAVE_LD_DYNAMIC_LIST 46 47gallium_dri_la_LIBADD = \ 48 $(top_builddir)/src/mesa/libmesagallium.la \ 49 $(top_builddir)/src/mesa/drivers/dri/common/libdricommon.la \ 50 $(top_builddir)/src/mesa/drivers/dri/common/libmegadriver_stub.la \ 51 $(top_builddir)/src/gallium/state_trackers/dri/libdri.la \ 52 $(top_builddir)/src/gallium/auxiliary/libgalliumvl.la \ 53 $(top_builddir)/src/gallium/auxiliary/libgallium.la \ 54 $(top_builddir)/src/gallium/drivers/ddebug/libddebug.la \ 55 $(top_builddir)/src/gallium/drivers/noop/libnoop.la \ 56 $(top_builddir)/src/gallium/drivers/rbug/librbug.la \ 57 $(top_builddir)/src/gallium/drivers/trace/libtrace.la \ 58 $(SHARED_GLAPI_LIB) \ 59 $(SELINUX_LIBS) \ 60 $(EXPAT_LIBS) \ 61 $(LIBDRM_LIBS) \ 62 $(GALLIUM_COMMON_LIB_DEPS) 63 64EXTRA_gallium_dri_la_DEPENDENCIES = \ 65 dri.sym \ 66 $(top_srcdir)/src/gallium/targets/dri-vdpau.dyn 67EXTRA_DIST = \ 68 SConscript \ 69 dri.sym \ 70 $(top_srcdir)/src/gallium/targets/dri-vdpau.dyn 71 72TARGET_DRIVERS = 73TARGET_CPPFLAGS = 74TARGET_LIB_DEPS = 75 76include $(top_srcdir)/src/gallium/drivers/i915/Automake.inc 77 78include $(top_srcdir)/src/gallium/drivers/ilo/Automake.inc 79 80include $(top_srcdir)/src/gallium/drivers/nouveau/Automake.inc 81 82include $(top_srcdir)/src/gallium/drivers/r300/Automake.inc 83include $(top_srcdir)/src/gallium/drivers/r600/Automake.inc 84include $(top_srcdir)/src/gallium/drivers/radeonsi/Automake.inc 85 86include $(top_srcdir)/src/gallium/drivers/svga/Automake.inc 87 88include $(top_srcdir)/src/gallium/drivers/freedreno/Automake.inc 89 90include $(top_srcdir)/src/gallium/drivers/vc4/Automake.inc 91 92include $(top_srcdir)/src/gallium/drivers/virgl/Automake.inc 93 94include $(top_srcdir)/src/gallium/drivers/etnaviv/Automake.inc 95include $(top_srcdir)/src/gallium/drivers/imx/Automake.inc 96 97include $(top_srcdir)/src/gallium/drivers/softpipe/Automake.inc 98include $(top_srcdir)/src/gallium/drivers/llvmpipe/Automake.inc 99include $(top_srcdir)/src/gallium/drivers/swr/Automake.inc 100 101if HAVE_GALLIUM_STATIC_TARGETS 102 103gallium_dri_la_SOURCES += target.c 104gallium_dri_la_CPPFLAGS = $(AM_CPPFLAGS) $(TARGET_CPPFLAGS) 105gallium_dri_la_LIBADD += \ 106 $(top_builddir)/src/gallium/auxiliary/pipe-loader/libpipe_loader_static.la \ 107 $(GALLIUM_PIPE_LOADER_WINSYS_LIBS) \ 108 $(TARGET_LIB_DEPS) \ 109 $(TARGET_RADEON_WINSYS) $(TARGET_RADEON_COMMON) 110 111else # HAVE_GALLIUM_STATIC_TARGETS 112 113gallium_dri_la_LIBADD += \ 114 $(top_builddir)/src/gallium/auxiliary/pipe-loader/libpipe_loader_dynamic.la 115 116endif # HAVE_GALLIUM_STATIC_TARGETS 117 118if HAVE_GALLIUM_LLVM 119gallium_dri_la_LIBADD += $(LLVM_LIBS) 120gallium_dri_la_LDFLAGS += $(LLVM_LDFLAGS) 121endif 122 123if HAVE_COMPAT_SYMLINKS 124# Add a link to allow setting LIBGL_DRIVERS_PATH to /lib/gallium of the build tree. 125all-local: $(dri_LTLIBRARIES) 126 $(AM_V_GEN)link_dir=$(top_builddir)/$(LIB_DIR)/gallium; \ 127 $(MKDIR_P) $${link_dir}; \ 128 for i in $(TARGET_DRIVERS); do \ 129 ln -f .libs/gallium_dri.so \ 130 $${link_dir}/$${i}_dri.so; \ 131 done 132 133clean-local: 134 $(AM_V_GEN)link_dir=$(top_builddir)/$(LIB_DIR)/gallium; \ 135 $(AM_V_GEN)for i in $(TARGET_DRIVERS); do \ 136 $(RM) $${link_dir}/$${i}_dri.so; \ 137 done; 138endif 139 140# hardlink each megadriver instance, but don't actually have 141# gallium_dri.so in the set of final installed files. 142install-data-hook: 143 for i in $(TARGET_DRIVERS); do \ 144 ln -f $(DESTDIR)$(dridir)/gallium_dri.so \ 145 $(DESTDIR)$(dridir)/$${i}_dri.so; \ 146 done; \ 147 $(RM) $(DESTDIR)$(dridir)/gallium_dri.* 148 149uninstall-hook: 150 for i in $(TARGET_DRIVERS); do \ 151 $(RM) $(DESTDIR)$(dridir)/$${i}_dri.so; \ 152 done; 153