X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmesa%2FMakefile.am;h=5a7884c939e080bfa367174d2af85df96d6cc9fe;hb=faaca237341abc0f784edfb16df50104110365b8;hp=4387415facf7ec6fcf54d21189853abbf3446d48;hpb=fd03dd6ddd96afe782d8686fcba437d23c878da1;p=mesa.git diff --git a/src/mesa/Makefile.am b/src/mesa/Makefile.am index 4387415facf..5a7884c939e 100644 --- a/src/mesa/Makefile.am +++ b/src/mesa/Makefile.am @@ -25,7 +25,7 @@ if HAVE_X11_DRIVER SUBDIRS += drivers/x11 endif -if HAVE_DRI +if HAVE_DRICOMMON SUBDIRS += drivers/dri endif @@ -36,18 +36,18 @@ endif gldir = $(includedir)/GL gl_HEADERS = $(top_srcdir)/include/GL/*.h -.PHONY: main/git_sha1.h.tmp -main/git_sha1.h.tmp: +.PHONY: $(BUILDDIR)main/git_sha1.h.tmp +$(BUILDDIR)main/git_sha1.h.tmp: @touch main/git_sha1.h.tmp - @if test -d ../../.git; then \ + @if test -d $(top_srcdir)/.git; then \ if which git > /dev/null; then \ - git log -n 1 --oneline | \ + git --git-dir=$(top_srcdir)/.git log -n 1 --oneline | \ sed 's/^\([^ ]*\) .*/#define MESA_GIT_SHA1 "git-\1"/' \ > main/git_sha1.h.tmp ; \ fi \ fi -main/git_sha1.h: main/git_sha1.h.tmp +$(BUILDDIR)main/git_sha1.h: $(BUILDDIR)main/git_sha1.h.tmp @echo "updating main/git_sha1.h" @if ! cmp -s main/git_sha1.h.tmp main/git_sha1.h; then \ mv main/git_sha1.h.tmp main/git_sha1.h ;\ @@ -62,15 +62,35 @@ include $(GLAPI)/glapi_gen.mk BUILDDIR = $(builddir)/ include Makefile.sources +EXTRA_DIST = \ + drivers/haiku \ + drivers/SConscript \ + drivers/windows \ + main/format_info.py \ + main/format_parser.py \ + main/formats.csv \ + main/get_hash_generator.py \ + main/get_hash_params.py \ + program/program_lexer.l \ + program/program_parse.y \ + SConscript \ + swrast/NOTES \ + swrast_setup/NOTES \ + tnl/NOTES \ + tnl_dd + BUILT_SOURCES = \ - main/git_sha1.h \ main/get_hash.h \ + main/format_info.c \ + $(BUILDDIR)main/git_sha1.h \ + main/format_pack.c \ + main/format_unpack.c \ $(BUILDDIR)program/program_parse.tab.c \ $(BUILDDIR)program/lex.yy.c CLEANFILES = \ $(BUILT_SOURCES) \ $(BUILDDIR)program/program_parse.tab.h \ - git_sha1.h.tmp + $(BUILDDIR)main/git_sha1.h.tmp GET_HASH_GEN = main/get_hash_generator.py @@ -81,7 +101,32 @@ main/get_hash.h: $(GLAPI)/gl_and_es_API.xml main/get_hash_params.py \ -f $< > $@.tmp; \ mv $@.tmp $@; -noinst_LTLIBRARIES = +main/format_info.c: main/formats.csv \ + main/format_parser.py main/format_info.py + $(AM_V_GEN)set -e; \ + $(PYTHON2) $(PYTHON_FLAGS) $(srcdir)/main/format_info.py \ + $< > $@.tmp; \ + mv $@.tmp $@; + +main/format_pack.c: main/format_pack.py main/formats.csv \ + main/format_parser.py + $(AM_V_GEN)set -e; \ + $(PYTHON2) $(PYTHON_FLAGS) \ + $(srcdir)/main/format_pack.py \ + $(srcdir)/main/formats.csv \ + | $(INDENT) $(INDENT_FLAGS) > $@; + +main/format_unpack.c: main/format_unpack.py main/formats.csv \ + main/format_parser.py + $(AM_V_GEN)set -e; \ + $(PYTHON2) $(PYTHON_FLAGS) \ + $(srcdir)/main/format_unpack.py \ + $(srcdir)/main/formats.csv \ + | $(INDENT) $(INDENT_FLAGS) > $@; + +main/formats.c: main/format_info.c + +noinst_LTLIBRARIES = $(ARCH_LIBS) if NEED_LIBMESA noinst_LTLIBRARIES += libmesa.la else @@ -95,6 +140,12 @@ AM_CPPFLAGS = $(DEFINES) $(INCLUDE_DIRS) AM_CFLAGS = $(LLVM_CFLAGS) $(VISIBILITY_CFLAGS) AM_CXXFLAGS = $(LLVM_CFLAGS) $(VISIBILITY_CXXFLAGS) +ARCH_LIBS = + +if SSE41_SUPPORTED +ARCH_LIBS += libmesa_sse41.la +endif + MESA_ASM_FILES_FOR_ARCH = if HAVE_X86_ASM @@ -119,30 +170,37 @@ endif libmesa_la_SOURCES = \ $(MESA_FILES) \ $(PROGRAM_FILES) \ - $(MESA_ASM_FILES_FOR_ARCH) + $(MESA_ASM_FILES_FOR_ARCH) libmesa_la_LIBADD = \ - $(top_builddir)/src/glsl/libglsl.la \ - $() + $(top_builddir)/src/glsl/libglsl.la \ + $(ARCH_LIBS) libmesagallium_la_SOURCES = \ $(MESA_GALLIUM_FILES) \ $(PROGRAM_FILES) \ - $(MESA_ASM_FILES_FOR_ARCH) + $(MESA_ASM_FILES_FOR_ARCH) libmesagallium_la_LIBADD = \ - $(top_builddir)/src/glsl/libglsl.la \ - $() + $(top_builddir)/src/glsl/libglsl.la \ + $(ARCH_LIBS) + +libmesa_sse41_la_SOURCES = \ + main/streaming-load-memcpy.c \ + main/streaming-load-memcpy.h \ + main/sse_minmax.c \ + main/sse_minmax.h +libmesa_sse41_la_CFLAGS = $(AM_CFLAGS) $(SSE41_CFLAGS) pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = gl.pc $(BUILDDIR)program/lex.yy.c: program/program_lexer.l - $(MKDIR_P) $(builddir)/program + $(AM_V_at)$(MKDIR_P) program $(AM_V_GEN) $(LEX) --never-interactive --outfile=$@ $< $(BUILDDIR)program/program_parse.tab.c $(BUILDDIR)program/program_parse.tab.h: program/program_parse.y - $(MKDIR_P) $(builddir)/program + $(AM_V_at)$(MKDIR_P) program $(AM_V_GEN) $(YACC) -p "_mesa_program_" -v -d --output=$(BUILDDIR)program/program_parse.tab.c $< if GEN_ASM_OFFSETS