ilo: add support for indirect access of CONST in FS
[mesa.git] / src / gallium / drivers / r300 / Makefile.am
index 020134985bf314fedf84dbd2b56573c2d73a7945..49264c4a719c168af8b4ccb639faa87e080309b6 100644 (file)
@@ -1,34 +1,41 @@
 include Makefile.sources
+include $(top_srcdir)/src/gallium/Automake.inc
 
-noinst_LIBRARIES = libr300.a
+noinst_LTLIBRARIES = libr300.la libr300-helper.la
 check_PROGRAMS = r300_compiler_tests
 testdir = compiler/tests
 TESTS = r300_compiler_tests
 
 AM_CFLAGS = \
-       -I$(top_srcdir)/src/gallium/include \
-       -I$(top_srcdir)/src/gallium/auxiliary \
        -I$(top_srcdir)/src/gallium/drivers \
        -I$(top_srcdir)/include \
        -I$(top_srcdir)/src/mesa \
        -I$(top_srcdir)/src/glsl \
        -I$(top_srcdir)/src/mapi \
        $(VISIBILITY_CFLAGS) \
+       $(GALLIUM_CFLAGS) \
        $(LLVM_CFLAGS) \
-       $(RADEON_CFLAGS) \
-       $(DEFINES) \
-       $(PIC_FLAGS)
+       $(RADEON_CFLAGS)
 
-libr300_a_SOURCES = \
-       $(C_SOURCES) \
-       $(top_srcdir)/src/glsl/ralloc.c \
-       $(top_srcdir)/src/mesa/program/register_allocate.c
-
-r300_compiler_tests_LDADD = libr300.a
+r300_compiler_tests_LDADD = libr300.la
 r300_compiler_tests_CPPFLAGS = \
        -I$(top_srcdir)/src/gallium/drivers/r300/compiler
 r300_compiler_tests_SOURCES = \
        $(testdir)/r300_compiler_tests.c \
+       $(testdir)/radeon_compiler_optimize_tests.c \
        $(testdir)/radeon_compiler_util_tests.c \
        $(testdir)/rc_test_helpers.c \
        $(testdir)/unit_test.c
+
+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_SOURCES = \
+       $(top_srcdir)/src/glsl/ralloc.c \
+       $(top_srcdir)/src/mesa/program/register_allocate.c