diff options
author | Luc Verhaegen <libv@skynet.be> | 2010-03-16 03:29:34 +0100 |
---|---|---|
committer | Luc Verhaegen <libv@skynet.be> | 2010-03-16 03:29:34 +0100 |
commit | 2d1bc850e4bf2001aee40955998fb4c41bc3687f (patch) | |
tree | 1abcfa35ec391a5198cba9e07d15e80dbc490043 | |
parent | bf1e6581a56884c383e5446d84c56b39a7f4e0a0 (diff) |
Provide dri shared library building and SDK installation.dri-sdk-7.4.0
-rw-r--r-- | Makefile | 13 | ||||
-rw-r--r-- | configs/default | 2 | ||||
-rw-r--r-- | src/mesa/Makefile | 48 | ||||
-rw-r--r-- | src/mesa/drivers/dri/common/Makefile | 77 | ||||
-rw-r--r-- | src/mesa/drivers/dri/common/libmesadricommon.pc.in | 9 | ||||
-rw-r--r-- | src/mesa/drivers/dri/swrast/Makefile | 12 | ||||
-rw-r--r-- | src/mesa/libmesadri.pc.in | 9 | ||||
-rw-r--r-- | src/mesa/sources | 97 |
8 files changed, 265 insertions, 2 deletions
@@ -13,6 +13,19 @@ default: $(TOP)/configs/current done +dri-sdk: + cd src/mesa/ && $(MAKE) dri-sdk + +dri-sdk-install: + cd src/mesa/ && $(MAKE) dri-sdk-install + +dri-swrast: + cd src/mesa/drivers/dri/swrast && $(MAKE) dri-swrast + +dri-swrast-install: + cd src/mesa/drivers/dri/swrast && $(MAKE) dri-swrast-install + + doxygen: cd doxygen && $(MAKE) diff --git a/configs/default b/configs/default index 7b79cf2c1b..d5d76e69ff 100644 --- a/configs/default +++ b/configs/default @@ -9,7 +9,7 @@ CONFIG_NAME = default # Version info MESA_MAJOR=7 -MESA_MINOR=3 +MESA_MINOR=4 MESA_TINY=0 MESA_VERSION = $(MESA_MAJOR).$(MESA_MINOR).$(MESA_TINY) diff --git a/src/mesa/Makefile b/src/mesa/Makefile index 6b4057030e..9ce27aba1a 100644 --- a/src/mesa/Makefile +++ b/src/mesa/Makefile @@ -32,6 +32,17 @@ default: depend asm_subdirs libmesa.a libglapi.a driver_subdirs libmesa.a: $(MESA_OBJECTS) @ $(MKLIB) -o mesa -static $(MESA_OBJECTS) +libmesadri.so.$(MESA_VERSION): asm_subdirs $(MESA_OBJECTS) + $(MKLIB) -major $(MESA_MAJOR) -minor $(MESA_MINOR) \ + -patch $(MESA_TINY) -o mesadri $(MESA_OBJECTS) + +libmesadri: libmesadri.so.$(MESA_VERSION) + +libmesadricommon: + (cd drivers/dri/common && $(MAKE)) || exit 1 + +dri-sdk: libmesadri libmesadricommon + # Make archive of gl* API dispatcher functions only libglapi.a: $(GLAPI_OBJECTS) @ $(MKLIB) -o glapi -static $(GLAPI_OBJECTS) @@ -134,14 +145,49 @@ install-osmesa: default osmesa.pc install-dri: default cd drivers/dri && $(MAKE) install +libmesadri_pcedit = sed \ + -e 's,@INSTALL_DIR@,$(INSTALL_DIR),' \ + -e 's,@INSTALL_LIB_DIR@,$(INSTALL_LIB_DIR),' \ + -e 's,@INSTALL_INC_DIR@,$(INSTALL_INC_DIR),' \ + -e 's,@VERSION@,$(MESA_MAJOR).$(MESA_MINOR).$(MESA_TINY),' + +libmesadri.pc: libmesadri.pc.in + $(libmesadri_pcedit) $< > $@ + +install-libmesadricommon: + cd drivers/dri/common && $(MAKE) install + +$(DESTDIR)$(INSTALL_INC_DIR)/mesa/%: $(subst $(DESTDIR)$(INSTALL_INC_DIR)/mesa/,,$@) + $(INSTALL) -d $(dir $@) + $(INSTALL) -m 644 $(subst $(DESTDIR)$(INSTALL_INC_DIR)/mesa/,,$(dir $@))$(notdir $@) $(dir $@) + +install-libmesadri-headers: $(addprefix $(DESTDIR)$(INSTALL_INC_DIR)/mesa/,$(LIBMESADRI_HEADERS)) + # since glproto's internal/glcore.h is vastly out of sync anyway. + $(INSTALL) -d $(DESTDIR)$(INSTALL_INC_DIR)/GL + $(INSTALL) -d $(DESTDIR)$(INSTALL_INC_DIR)/GL/internal + $(INSTALL) -m 644 $(TOP)/include/GL/internal/glcore.h $(DESTDIR)$(INSTALL_INC_DIR)/GL/internal + +install-libmesadri: libmesadri.so libmesadri.pc install-libmesadri-headers + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig + $(INSTALL) libmesadri.so.$(MESA_VERSION) $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) libmesadri.so.$(MESA_MAJOR) $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) libmesadri.so $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) -m 644 libmesadri.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig +dri-sdk-install: install-libmesadri install-libmesadricommon # Emacs tags tags: etags `find . -name \*.[ch]` $(TOP)/include/GL/*.h -clean: +libmesadri-clean: + -rm -f libmesadri.so* + -rm -f libmesadri.pc + cd drivers/dri/common && $(MAKE) clean + +clean: libmesadri-clean -rm -f */*.o -rm -f */*/*.o -rm -f depend depend.bak libmesa.a libglapi.a diff --git a/src/mesa/drivers/dri/common/Makefile b/src/mesa/drivers/dri/common/Makefile new file mode 100644 index 0000000000..39a8977af4 --- /dev/null +++ b/src/mesa/drivers/dri/common/Makefile @@ -0,0 +1,77 @@ +TOP = ../../../../.. +include $(TOP)/configs/current + +DRIVER_DEFINES = -DIN_DRI_DRIVER + +COMMON_SOURCES = \ + utils.c \ + texmem.c \ + vblank.c \ + dri_util.c \ + xmlconfig.c \ + drirenderbuffer.c \ + +LIBMESADRICOMMON_HEADERS = \ + drivers/common/driverfuncs.h \ + drivers/dri/common/depthtmp.h \ + drivers/dri/common/drirenderbuffer.h \ + drivers/dri/common/dri_util.h \ + drivers/dri/common/extension_helper.h \ + drivers/dri/common/mmio.h \ + drivers/dri/common/spantmp2.h \ + drivers/dri/common/spantmp_common.h \ + drivers/dri/common/spantmp.h \ + drivers/dri/common/stenciltmp.h \ + drivers/dri/common/texmem.h \ + drivers/dri/common/utils.h \ + drivers/dri/common/vblank.h \ + drivers/dri/common/xmlconfig.h \ + drivers/dri/common/xmlpool.h \ + drivers/dri/common/xmlpool/options.h + +COMMON_OBJECTS = $(COMMON_SOURCES:.c=.o) + +INCLUDES = \ + -I. \ + -I$(TOP)/include \ + -I$(TOP)/src/mesa \ + -I/usr/include/drm + +.c.o: + $(CC) -c $(INCLUDES) $(CFLAGS) $(DRIVER_DEFINES) $< -o $@ + +libmesadricommon.so: $(COMMON_OBJECTS) + $(MKLIB) -major $(MESA_MAJOR) -minor $(MESA_MINOR) \ + -patch $(MESA_TINY) -o mesadricommon $(COMMON_OBJECTS) + +pcedit = sed \ + -e 's,@INSTALL_DIR@,$(INSTALL_DIR),' \ + -e 's,@INSTALL_LIB_DIR@,$(INSTALL_LIB_DIR),' \ + -e 's,@INSTALL_INC_DIR@,$(INSTALL_INC_DIR),' \ + -e 's,@VERSION@,$(MESA_MAJOR).$(MESA_MINOR).$(MESA_TINY),' \ + -e 's,@DRI_DRIVER_DIR@,$(DRI_DRIVER_INSTALL_DIR),' \ + -e 's,@DRI_PC_REQ_PRIV@,$(DRI_PC_REQ_PRIV),' + +libmesadricommon.pc: libmesadricommon.pc.in + $(pcedit) $< > $@ + +default: libmesadricommon.so + +install: libmesadricommon.so libmesadricommon.pc install-libmesadricommon-headers + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig + $(INSTALL) libmesadricommon.so.$(MESA_VERSION) $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) libmesadricommon.so.$(MESA_MAJOR) $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) libmesadricommon.so $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) -m 644 libmesadricommon.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig + +$(DESTDIR)$(INSTALL_INC_DIR)/mesa/%: $(subst $(DESTDIR)$(INSTALL_INC_DIR)/mesa/drivers/,../../,$@) + $(INSTALL) -d $(dir $@) + $(INSTALL) -m 644 $(subst $(DESTDIR)$(INSTALL_INC_DIR)/mesa/drivers/,../../,$(dir $@))$(notdir $@) $(dir $@) + +install-libmesadricommon-headers: $(addprefix $(DESTDIR)$(INSTALL_INC_DIR)/mesa/,$(LIBMESADRICOMMON_HEADERS)) + +clean: + -rm -f *.o + -rm -f libmesadricommon.so* + -rm -f libmesadricommon.pc diff --git a/src/mesa/drivers/dri/common/libmesadricommon.pc.in b/src/mesa/drivers/dri/common/libmesadricommon.pc.in new file mode 100644 index 0000000000..3a752af644 --- /dev/null +++ b/src/mesa/drivers/dri/common/libmesadricommon.pc.in @@ -0,0 +1,9 @@ +prefix=@INSTALL_DIR@ +libdir=@INSTALL_LIB_DIR@ +includedir=@INSTALL_INC_DIR@ + +Name: libmesadricommon +Description: Common dri driver infrastructure for Mesa/dri. +Version: @VERSION@ +Libs: -L${libdir} -lmesadricommon -lexpat +Cflags: -I${includedir}/mesa -I${includedir}/mesa/drivers/dri/common diff --git a/src/mesa/drivers/dri/swrast/Makefile b/src/mesa/drivers/dri/swrast/Makefile index 5f3a4f2191..bdaa161200 100644 --- a/src/mesa/drivers/dri/swrast/Makefile +++ b/src/mesa/drivers/dri/swrast/Makefile @@ -21,4 +21,16 @@ SWRAST_COMMON_SOURCES = \ include ../Makefile.template + +dri-swrast: $(OBJECTS) + $(MKLIB) -major $(MESA_MAJOR) -minor $(MESA_MINOR) -patch $(MESA_TINY) \ + -o swrast_dri.so -noprefix $(OBJECTS) -lmesadri \ + $(EXTRA_MODULES) $(DRI_LIB_DEPS) + +dri-swrast-install: dri-swrast + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR) + $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/dri + $(INSTALL) swrast_dri.so $(DESTDIR)$(INSTALL_LIB_DIR)/dri + + symlinks: diff --git a/src/mesa/libmesadri.pc.in b/src/mesa/libmesadri.pc.in new file mode 100644 index 0000000000..0cab4b2104 --- /dev/null +++ b/src/mesa/libmesadri.pc.in @@ -0,0 +1,9 @@ +prefix=@INSTALL_DIR@ +libdir=@INSTALL_LIB_DIR@ +includedir=@INSTALL_INC_DIR@ + +Name: libmesadri +Description: Core library for Mesa/dri. +Version: @VERSION@ +Libs: -L${libdir} -lmesadri -lpthread +Cflags: -I${includedir}/mesa -DPTHREADS diff --git a/src/mesa/sources b/src/mesa/sources index 01a3fb89e6..43baf9258b 100644 --- a/src/mesa/sources +++ b/src/mesa/sources @@ -303,3 +303,100 @@ INCLUDE_DIRS = \ -I$(TOP)/include \ -I$(TOP)/src/mesa \ -I$(TOP)/src/mesa/main + +LIBMESADRI_HEADERS = \ + glapi/dispatch.h \ + glapi/glapi.h \ + glapi/glapitable.h \ + glapi/glthread.h \ + main/api_arrayelt.h \ + main/api_noop.h \ + main/api_validate.h \ + main/attrib.h \ + main/bitset.h \ + main/blend.h \ + main/bufferobj.h \ + main/buffers.h \ + main/clip.h \ + main/colormac.h \ + main/colortab.h \ + main/config.h \ + main/context.h \ + main/convolve.h \ + main/dd.h \ + main/depth.h \ + main/depthstencil.h \ + main/enable.h \ + main/enums.h \ + main/extensions.h \ + main/fbobject.h \ + main/framebuffer.h \ + main/glheader.h \ + main/hash.h \ + main/image.h \ + main/imports.h \ + main/light.h \ + main/macros.h \ + main/matrix.h \ + main/mfeatures.h \ + main/mipmap.h \ + main/mm.h \ + main/mtypes.h \ + main/pixelstore.h \ + main/points.h \ + main/renderbuffer.h \ + main/shaders.h \ + main/simple_list.h \ + main/state.h \ + main/stencil.h \ + main/texcompress.h \ + main/texenv.h \ + main/texformat.h \ + main/teximage.h \ + main/texobj.h \ + main/texparam.h \ + main/texrender.h \ + main/texstate.h \ + main/texstore.h \ + main/varray.h \ + main/vtxfmt.h \ + math/m_matrix.h \ + math/m_translate.h \ + math/m_vector.h \ + math/m_xform.h \ + shader/arbprogram.h \ + shader/atifragshader.h \ + shader/prog_execute.h \ + shader/prog_instruction.h \ + shader/prog_parameter.h \ + shader/prog_print.h \ + shader/program.h \ + shader/programopt.h \ + shader/prog_statevars.h \ + shader/shader_api.h \ + swrast/s_context.h \ + swrast_setup/ss_context.h \ + swrast_setup/swrast_setup.h \ + swrast/s_fog.h \ + swrast/s_span.h \ + swrast/swrast.h \ + tnl_dd/t_dd_dmatmp2.h \ + tnl_dd/t_dd_dmatmp.h \ + tnl_dd/t_dd_rendertmp.h \ + tnl_dd/t_dd_triemit.h \ + tnl_dd/t_dd_tritmp.h \ + tnl_dd/t_dd_unfilled.h \ + tnl_dd/t_dd_vb.c \ + tnl_dd/t_dd_vbtmp.h \ + tnl_dd/t_dd_vertex.h \ + tnl/t_context.h \ + tnl/tnl.h \ + tnl/t_pipeline.h \ + tnl/t_vb_rendertmp.h \ + tnl/t_vertex.h \ + tnl/t_vp_build.h \ + vbo/vbo_attrib.h \ + vbo/vbo_context.h \ + vbo/vbo_exec.h \ + vbo/vbo.h \ + vbo/vbo_save.h |