r600g: fix RSQ of negative value on Cayman
[mesa.git] / src / gallium / drivers / r600 / Makefile.am
index 8acd36ac865b2de0dc23af33a93a27f1d38d6d81..628eaab568584bdcc025f20e8f88f530a3d97040 100644 (file)
@@ -9,9 +9,42 @@ AM_CFLAGS = \
        -I$(top_srcdir)/include \
        $(RADEON_CFLAGS) \
        $(DEFINES) \
-       $(ASM_FLAGS) \
        $(PIC_FLAGS) \
        $(VISIBILITY_CFLAGS)
 
 libr600_a_SOURCES = \
        $(C_SOURCES)
+
+if NEED_RADEON_GALLIUM
+
+# This is a hack until we can move the backend into the LLVM project.
+# We need to use mklib, because it splits up libradeon.a into object files
+# so that we can link it with the r600 objects.
+libr600_a_AR = $(top_srcdir)/bin/mklib -o r600 -static
+
+libr600_a_SOURCES += \
+       $(LLVM_C_SOURCES) \
+       $(LLVM_CXX_SOURCES)
+
+libr600_a_LIBADD = \
+       $(top_builddir)/src/gallium/drivers/radeon/libradeon.a
+
+AM_CFLAGS += \
+       $(LLVM_CFLAGS) \
+       -I$(top_srcdir)/src/gallium/drivers/radeon/
+
+AM_CXXFLAGS= \
+       $(LLVM_CXXFLAGS)
+else
+libr600_a_AR = $(AR) $(ARFLAGS)
+endif
+
+if USE_R600_LLVM_COMPILER
+AM_CFLAGS += \
+       -DR600_USE_LLVM
+endif
+
+if HAVE_GALLIUM_COMPUTE
+AM_CFLAGS += \
+       -DHAVE_OPENCL
+endif