summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2014-09-22 12:24:21 -0700
committerEric Anholt <eric@anholt.net>2014-09-23 13:40:10 -0700
commit517e01b5c3db9ba750698096e823134b288e213f (patch)
treec45b171316ae6d599b6b19d4c3a5cc7960334491 /src/gallium
parent5e1fcc625824ae962d5f658e151e6bc2665adce8 (diff)
downloadexternal_mesa3d-517e01b5c3db9ba750698096e823134b288e213f.zip
external_mesa3d-517e01b5c3db9ba750698096e823134b288e213f.tar.gz
external_mesa3d-517e01b5c3db9ba750698096e823134b288e213f.tar.bz2
mesa: Move register_allocate.c to util.
The r300 gallium driver is using it outside of the Mesa tree, and I wanted to do so for vc4 as well. Rather than make the multiple-definitions problem even more complicated, just move it to more-shared code. v2: Don't forget to delete the symlink in r300 (review by Matt). Delete more r300-helper references (review by Emil) Don't prefix util/ header inclusion with "util/" (review by Emil) Reviewed-by: Matt Turner <mattst88@gmail.com> (v1) Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> (v1)
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/r300/Makefile.am14
-rw-r--r--src/gallium/drivers/r300/Makefile.sources3
-rw-r--r--src/gallium/drivers/r300/compiler/radeon_pair_regalloc.c2
l---------src/gallium/drivers/r300/register_allocate.c1
-rw-r--r--src/gallium/targets/egl-static/Makefile.am5
-rw-r--r--src/gallium/targets/gbm/Makefile.am1
-rw-r--r--src/gallium/targets/pipe-loader/Makefile.am1
7 files changed, 3 insertions, 24 deletions
diff --git a/src/gallium/drivers/r300/Makefile.am b/src/gallium/drivers/r300/Makefile.am
index 7692bd8..ead7a87 100644
--- a/src/gallium/drivers/r300/Makefile.am
+++ b/src/gallium/drivers/r300/Makefile.am
@@ -13,11 +13,11 @@ AM_CFLAGS = \
$(LLVM_CFLAGS) \
$(RADEON_CFLAGS)
-noinst_LTLIBRARIES = libr300.la libr300-helper.la
+noinst_LTLIBRARIES = libr300.la
check_PROGRAMS = r300_compiler_tests
TESTS = r300_compiler_tests
-r300_compiler_tests_LDADD = libr300.la libr300-helper.la \
+r300_compiler_tests_LDADD = libr300.la \
$(top_builddir)/src/gallium/auxiliary/libgallium.la \
$(top_builddir)/src/util/libmesautil.la \
$(GALLIUM_COMMON_LIB_DEPS)
@@ -28,16 +28,6 @@ r300_compiler_tests_SOURCES = $(COMPILER_TESTS_SOURCES)
libr300_la_SOURCES = $(C_SOURCES)
-# These two files are included in libmesagallium, which is included in the dri
-# targets. So, they were added directly to r300g the dri-r300 target would have
-# duplicated symbols, and if they weren't the other *-r300 targets would fail
-# with undefined symbols.
-#
-# Solve this by building them into a separate helper library that can be linked
-# in place of libmesagallium.
-libr300_helper_la_CPPFLAGS = -I$(top_srcdir)/src
-libr300_helper_la_SOURCES = $(HELPER_SOURCES)
-
EXTRA_DIST = Android.mk \
compiler/tests/omod_two_writers.test \
compiler/tests/regalloc_tex_1d_swizzle.test
diff --git a/src/gallium/drivers/r300/Makefile.sources b/src/gallium/drivers/r300/Makefile.sources
index ab1c9de..1ba6db0 100644
--- a/src/gallium/drivers/r300/Makefile.sources
+++ b/src/gallium/drivers/r300/Makefile.sources
@@ -108,6 +108,3 @@ COMPILER_TESTS_SOURCES := \
compiler/tests/rc_test_helpers.h \
compiler/tests/unit_test.c \
compiler/tests/unit_test.h
-
-HELPER_SOURCES := \
- register_allocate.c
diff --git a/src/gallium/drivers/r300/compiler/radeon_pair_regalloc.c b/src/gallium/drivers/r300/compiler/radeon_pair_regalloc.c
index b854a2f..64b225d 100644
--- a/src/gallium/drivers/r300/compiler/radeon_pair_regalloc.c
+++ b/src/gallium/drivers/r300/compiler/radeon_pair_regalloc.c
@@ -31,7 +31,7 @@
#include <stdio.h>
#include "main/glheader.h"
-#include "program/register_allocate.h"
+#include "util/register_allocate.h"
#include "util/u_memory.h"
#include "util/ralloc.h"
diff --git a/src/gallium/drivers/r300/register_allocate.c b/src/gallium/drivers/r300/register_allocate.c
deleted file mode 120000
index 2117950..0000000
--- a/src/gallium/drivers/r300/register_allocate.c
+++ /dev/null
@@ -1 +0,0 @@
-../../../mesa/program/register_allocate.c \ No newline at end of file
diff --git a/src/gallium/targets/egl-static/Makefile.am b/src/gallium/targets/egl-static/Makefile.am
index 84f3338..a428be5 100644
--- a/src/gallium/targets/egl-static/Makefile.am
+++ b/src/gallium/targets/egl-static/Makefile.am
@@ -196,11 +196,6 @@ egl_gallium_la_CPPFLAGS += -DGALLIUM_R300
egl_gallium_la_LIBADD += \
$(top_builddir)/src/gallium/drivers/r300/libr300.la \
$(RADEON_LIBS)
-
-if !HAVE_OPENGL
-egl_gallium_la_LIBADD += \
- $(top_builddir)/src/gallium/drivers/r300/libr300-helper.la
-endif
endif
if HAVE_GALLIUM_R600
diff --git a/src/gallium/targets/gbm/Makefile.am b/src/gallium/targets/gbm/Makefile.am
index a5f7070..31a8b47 100644
--- a/src/gallium/targets/gbm/Makefile.am
+++ b/src/gallium/targets/gbm/Makefile.am
@@ -94,7 +94,6 @@ if HAVE_GALLIUM_R300
STATIC_TARGET_CPPFLAGS += -DGALLIUM_R300
STATIC_TARGET_LIB_DEPS += \
$(top_builddir)/src/gallium/drivers/r300/libr300.la \
- $(top_builddir)/src/gallium/drivers/r300/libr300-helper.la \
$(RADEON_LIBS)
endif
diff --git a/src/gallium/targets/pipe-loader/Makefile.am b/src/gallium/targets/pipe-loader/Makefile.am
index ee93078..5f1330a 100644
--- a/src/gallium/targets/pipe-loader/Makefile.am
+++ b/src/gallium/targets/pipe-loader/Makefile.am
@@ -97,7 +97,6 @@ nodist_EXTRA_pipe_r300_la_SOURCES = dummy.cpp
pipe_r300_la_LIBADD = \
$(PIPE_LIBS) \
$(top_builddir)/src/gallium/winsys/radeon/drm/libradeonwinsys.la \
- $(top_builddir)/src/gallium/drivers/r300/libr300-helper.la \
$(top_builddir)/src/gallium/drivers/r300/libr300.la \
$(LIBDRM_LIBS) \
$(RADEON_LIBS)