Message ID | 518EFA10.6040108@gmail.com (mailing list archive) |
---|---|
State | Mainlined, archived |
Headers | show |
On 05/11/2013 07:10 PM, Xi Wang wrote: > > This doesn't work for me. > > The problem is that -ldl (`llvm --ldflags`) must come _after_ > -lLLVMSupport (`llvm --libs`). > > Can we move LDFLAGS? > Sorry for the late reply. In that case, your first patch is actually cleaner. I apply your first patch instead. Change pushed. BTW, Pekka, I notice that "sparse-llvm_EXTRA_DEPS" is redundant with the next line, which also have sparse-llvm.o. Am I miss some thing? sparse-llvm_EXTRA_DEPS := sparse-llvm.o sparse-llvm.o $(sparse-llvm_EXTRA_DEPS): BASIC_CFLAGS += $(LLVM_CFLAGS) Chris -- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Wed, May 15, 2013 at 1:09 PM, Christopher Li <sparse@chrisli.org> wrote: > BTW, Pekka, I notice that "sparse-llvm_EXTRA_DEPS" is redundant > with the next line, which also have sparse-llvm.o. Am I miss some > thing? > > sparse-llvm_EXTRA_DEPS := sparse-llvm.o > sparse-llvm.o $(sparse-llvm_EXTRA_DEPS): BASIC_CFLAGS += $(LLVM_CFLAGS) No, I you're not missing anything. Feel free to drop it. -- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/Makefile b/Makefile index 35e3801..3cec8f0 100644 --- a/Makefile +++ b/Makefile @@ -84,7 +84,7 @@ HAVE_LLVM=no else LLVM_PROGS := sparse-llvm $(LLVM_PROGS): LD := g++ -LDFLAGS += $(shell llvm-config --ldflags) +$(LLVM_PROGS): LDFLAGS += $(shell llvm-config --ldflags) LLVM_CFLAGS := $(shell llvm-config --cflags | sed -e "s/-DNDEBUG//g") LLVM_LIBS := $(shell llvm-config --libs) PROGRAMS += $(LLVM_PROGS) @@ -173,7 +173,7 @@ compile_EXTRA_DEPS = compile-i386.o $(foreach p,$(PROGRAMS),$(eval $(p): $($(p)_EXTRA_DEPS) $(LIBS))) $(PROGRAMS): % : %.o - $(QUIET_LINK)$(LD) $(LDFLAGS) -o $@ $^ $($@_EXTRA_OBJS) + $(QUIET_LINK)$(LD) -o $@ $^ $($@_EXTRA_OBJS) $(LDFLAGS) $(LIB_FILE): $(LIB_OBJS) $(QUIET_AR)$(AR) rcs $@ $(LIB_OBJS)