]> rtime.felk.cvut.cz Git - hercules2020/hercules-compiler.git/blobdiff - Makefile
Add require-cuda.patch
[hercules2020/hercules-compiler.git] / Makefile
index e2f656f0c8b49310d02bf3a3061964a514fe4115..d89a1e24f7b80ccbf08c57c0b3315456b5c85623 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,10 @@
 PREFIX ?= $(HOME)/opt/hercules-compiler
 TMP_DESTDIR = $(CURDIR)/install
 
+# With gcc > 5, we get strange CUDA-related errors in clang.
+export CC = gcc-5
+export CXX = g++-5
+
 all: libpremnotify-cpu
 all: passes
 
@@ -23,8 +27,8 @@ ifneq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
 LLVM_TBLGEN=$(CURDIR)/build_native/bin/llvm-tblgen
 CLANG_TBLGEN=$(CURDIR)/build_native/bin/clang-tblgen
 
-LLVM_CROSS_FLAGS += -DCMAKE_C_COMPILER=$(DEB_HOST_GNU_TYPE)-gcc
-LLVM_CROSS_FLAGS += -DCMAKE_CXX_COMPILER=$(DEB_HOST_GNU_TYPE)-g++
+LLVM_CROSS_FLAGS += -DCMAKE_C_COMPILER=$(DEB_HOST_GNU_TYPE)-gcc-5
+LLVM_CROSS_FLAGS += -DCMAKE_CXX_COMPILER=$(DEB_HOST_GNU_TYPE)-g++-5
 LLVM_CROSS_FLAGS += -DCMAKE_SYSTEM_PROCESSOR=$(DEB_HOST_GNU_CPU)
 
 LLVM_CROSS_FLAGS += -DCMAKE_CROSSCOMPILING=True