2011-05-01 22:18:52 +02:00
|
|
|
######################################################################
|
|
|
|
# rustc LLVM-extensions (C++) library variables and rules
|
|
|
|
######################################################################
|
|
|
|
|
2011-08-12 06:14:08 +02:00
|
|
|
RUSTLLVM_OBJS_CS := $(addprefix rustllvm/, RustGCMetadataPrinter.cpp \
|
|
|
|
RustGCStrategy.cpp RustWrapper.cpp)
|
2011-05-01 22:18:52 +02:00
|
|
|
|
|
|
|
RUSTLLVM_DEF := rustllvm/rustllvm$(CFG_DEF_SUFFIX)
|
|
|
|
|
|
|
|
RUSTLLVM_INCS := -iquote $(CFG_LLVM_INCDIR) \
|
|
|
|
-iquote $(S)src/rustllvm/include
|
|
|
|
RUSTLLVM_OBJS_OBJS := $(RUSTLLVM_OBJS_CS:.cpp=.o)
|
|
|
|
|
2011-07-25 22:18:39 +02:00
|
|
|
rustllvm/$(CFG_RUSTLLVM): $(RUSTLLVM_OBJS_OBJS) \
|
2011-07-17 06:46:54 +02:00
|
|
|
$(MKFILES) $(RUSTLLVM_DEF)
|
2011-05-01 22:18:52 +02:00
|
|
|
@$(call E, link: $@)
|
|
|
|
$(Q)$(call CFG_LINK_C,$@,$(RUSTLLVM_OBJS_OBJS) \
|
2011-05-09 06:10:04 +02:00
|
|
|
$(CFG_GCCISH_PRE_LIB_FLAGS) $(CFG_LLVM_LIBS) \
|
2011-07-25 22:18:39 +02:00
|
|
|
$(CFG_GCCISH_POST_LIB_FLAGS) \
|
2011-05-01 22:18:52 +02:00
|
|
|
$(CFG_LLVM_LDFLAGS),$(RUSTLLVM_DEF))
|
|
|
|
|
|
|
|
rustllvm/%.o: rustllvm/%.cpp $(MKFILES)
|
|
|
|
@$(call E, compile: $@)
|
|
|
|
$(Q)$(call CFG_COMPILE_C, $@, $(CFG_LLVM_CXXFLAGS) $(RUSTLLVM_INCS)) $<
|
|
|
|
|