[cfe-dev] OpenCL : invalid operands to binary expression

Xiuxia zhangxiuxia1 at gmail.com
Mon Apr 21 09:20:11 PDT 2014


Hi Sam,
       I am using clang3.4 version.
My makefile is 

CXX := clang++
LLVMCOMPONENTS := cppbackend
RTTIFLAG := -fno-rtti
LLVMCONFIG := /sandbox/xiuxia/llvm_build/Debug+Asserts/bin/llvm-config

CXXFLAGS := -I$(shell $(LLVMCONFIG) --src-root)/tools/clang/include
-I$(shell $(LLVMCONFIG) --obj-root)/tools/clang/include $(shell
$(LLVMCONFIG) --cxxflags) $(RTTIFLAG)
LLVMLDFLAGS := $(shell $(LLVMCONFIG) --ldflags --libs $(LLVMCOMPONENTS))

SOURCES = CI_opencl.cpp

OBJECTS = $(SOURCES:.cpp=.o)
EXES = $(OBJECTS:.o=)
CLANGLIBS = \
                -lclangTooling\
                -lclangFrontendTool\
                -lclangFrontend\
                -lclangDriver\
                -lclangSerialization\
                -lclangCodeGen\
                -lclangParse\
                -lclangSema\
                -lclangStaticAnalyzerFrontend\
                -lclangStaticAnalyzerCheckers\
                -lclangStaticAnalyzerCore\
                -lclangAnalysis\
                -lclangARCMigrate\
                -lclangRewriteFrontend\
                -lclangRewriteCore\
                -lclangEdit\
                -lclangAST\
                -lclangLex\
                -lclangBasic\
                $(shell $(LLVMCONFIG) --libs)\
                -lcurses

all: $(OBJECTS) $(EXES)

%: %.o 
    $(CXX) -o $@ $< $(CLANGLIBS) $(LLVMLDFLAGS)


Here is my source file : I put it on the attachment. CI_opencl.cpp
<http://clang-developers.42468.n3.nabble.com/file/n4038913/CI_opencl.cpp>  





-----
Good good study, day day up
--
View this message in context: http://clang-developers.42468.n3.nabble.com/OpenCL-invalid-operands-to-binary-expression-tp4038893p4038913.html
Sent from the Clang Developers mailing list archive at Nabble.com.



More information about the cfe-dev mailing list