1# 2# Permission is hereby granted, free of charge, to any person obtaining a 3# copy of this software and associated documentation files (the "Software"), 4# to deal in the Software without restriction, including without limitation 5# the rights to use, copy, modify, merge, publish, distribute, sublicense, 6# and/or sell copies of the Software, and to permit persons to whom the 7# Software is furnished to do so, subject to the following conditions: 8# 9# The above copyright notice and this permission notice (including the next 10# paragraph) shall be included in all copies or substantial portions of the 11# Software. 12# 13# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 14# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 15# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 16# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 17# HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 18# WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 20# DEALINGS IN THE SOFTWARE. 21 22include $(top_srcdir)/src/gallium/Automake.inc 23 24AM_CFLAGS = \ 25 $(GALLIUM_CFLAGS) \ 26 $(VISIBILITY_CFLAGS) 27 28AM_CPPFLAGS = \ 29 -I$(top_srcdir)/include \ 30 -I$(top_srcdir)/src/mapi \ 31 -I$(top_srcdir)/src/mesa \ 32 -I$(top_srcdir)/src/gallium/include \ 33 -I$(top_srcdir)/src/gallium/drivers \ 34 -I$(top_srcdir)/src/gallium/winsys \ 35 -I$(top_srcdir)/src/gallium/auxiliary \ 36 -DGALLIUM_SOFTPIPE \ 37 -DGALLIUM_TRACE 38 39lib_LTLIBRARIES = lib@OSMESA_LIB@.la 40 41nodist_EXTRA_lib@OSMESA_LIB@_la_SOURCES = dummy.cpp 42lib@OSMESA_LIB@_la_SOURCES = target.c 43 44lib@OSMESA_LIB@_la_LDFLAGS = \ 45 -no-undefined \ 46 -version-number @OSMESA_VERSION@ \ 47 $(GC_SECTIONS) \ 48 $(LD_NO_UNDEFINED) 49 50if HAVE_LD_VERSION_SCRIPT 51lib@OSMESA_LIB@_la_LDFLAGS += \ 52 -Wl,--version-script=$(top_srcdir)/src/gallium/targets/osmesa/osmesa.sym 53endif 54 55if HAVE_SHARED_GLAPI 56SHARED_GLAPI_LIB = $(top_builddir)/src/mapi/shared-glapi/libglapi.la 57endif 58 59lib@OSMESA_LIB@_la_LIBADD = \ 60 $(top_builddir)/src/mesa/libmesagallium.la \ 61 $(top_builddir)/src/gallium/auxiliary/libgallium.la \ 62 $(top_builddir)/src/gallium/winsys/sw/null/libws_null.la \ 63 $(top_builddir)/src/gallium/drivers/trace/libtrace.la \ 64 $(top_builddir)/src/gallium/drivers/softpipe/libsoftpipe.la \ 65 $(top_builddir)/src/gallium/state_trackers/osmesa/libosmesa.la \ 66 $(top_builddir)/src/mapi/glapi/libglapi.la \ 67 $(SHARED_GLAPI_LIB) \ 68 $(OSMESA_LIB_DEPS) \ 69 $(CLOCK_LIB) \ 70 $(LIBUNWIND_LIBS) 71 72if HAVE_GALLIUM_LLVM 73AM_CPPFLAGS += -DGALLIUM_LLVMPIPE 74lib@OSMESA_LIB@_la_LDFLAGS += $(LLVM_LDFLAGS) 75lib@OSMESA_LIB@_la_LIBADD += $(top_builddir)/src/gallium/drivers/llvmpipe/libllvmpipe.la $(LLVM_LIBS) 76endif 77 78if HAVE_GALLIUM_SWR 79AM_CPPFLAGS += -DGALLIUM_SWR 80lib@OSMESA_LIB@_la_LDFLAGS += $(LLVM_LDFLAGS) 81lib@OSMESA_LIB@_la_LIBADD += $(top_builddir)/src/gallium/drivers/swr/libmesaswr.la $(LLVM_LIBS) 82endif 83 84EXTRA_lib@OSMESA_LIB@_la_DEPENDENCIES = osmesa.sym 85EXTRA_DIST = \ 86 osmesa.sym \ 87 osmesa.def \ 88 osmesa.mingw.def \ 89 SConscript \ 90 meson.build 91 92include $(top_srcdir)/install-gallium-links.mk 93 94pkgconfigdir = $(libdir)/pkgconfig 95pkgconfig_DATA = osmesa.pc 96