From patchwork Fri May 10 21:01:24 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xi Wang X-Patchwork-Id: 2552201 Return-Path: X-Original-To: patchwork-linux-sparse@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id C9F363FC5A for ; Fri, 10 May 2013 21:02:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754711Ab3EJVCn (ORCPT ); Fri, 10 May 2013 17:02:43 -0400 Received: from mail-vc0-f180.google.com ([209.85.220.180]:55595 "EHLO mail-vc0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754678Ab3EJVCn (ORCPT ); Fri, 10 May 2013 17:02:43 -0400 Received: by mail-vc0-f180.google.com with SMTP id hv10so4006761vcb.39 for ; Fri, 10 May 2013 14:02:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer; bh=9nDwQhnWPq5g3Zsi+X6pYe9mjw7leoY6GL3boroMgF0=; b=WxEqKW+f3VothW0IPP3sPCbCusylX7I5OkH5PR6E/F9XllVhyNkyMpt8O4Q8rqIJLt vKra/uiy3hMo5KZjwm9qlX4Fa+oqPlbiZYaVHkRkleYTvs8p1pB2wTnCr9dar4RY2tLx b+delz3hmroBLug4189I0YULH9JgBGyb8Y1ZZS42dKw0PTQK+J0Ul67WOrQ+yL5bHMsN 7/bidJbqEEO7QwwxbL8KwkGYdx1JdQI8XaEESp6UDd3j2x9w5VPBKYyIm1n06/Scbo8R +RPJsvCR9BFE2+Gi/iIQRRovEADs3YrvPU72Z4aFFsW7XK+eBO2oR0QmxiIacouw3JMC zjOA== X-Received: by 10.52.240.48 with SMTP id vx16mr10801561vdc.127.1368219762416; Fri, 10 May 2013 14:02:42 -0700 (PDT) Received: from hchen.csail.mit.edu (hchen.csail.mit.edu. [18.26.5.5]) by mx.google.com with ESMTPSA id tp10sm3553125vec.1.2013.05.10.14.02.41 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 10 May 2013 14:02:41 -0700 (PDT) From: Xi Wang To: sparse@chrisli.org Cc: linux-sparse@vger.kernel.org, Xi Wang , Pekka Enberg Subject: [PATCH] sparse, llvm: fix link errors Date: Fri, 10 May 2013 17:01:24 -0400 Message-Id: <1368219684-4567-1-git-send-email-xi.wang@gmail.com> X-Mailer: git-send-email 1.8.1.2 Sender: linux-sparse-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sparse@vger.kernel.org This patch fixes the following link errors. libLLVMSupport.a(Signals.o): In function `llvm::sys::PrintStackTrace(_IO_FILE*)': Signals.inc:269: undefined reference to `dladdr' Signals.inc:281: undefined reference to `dladdr' Cc: Pekka Enberg Signed-off-by: Xi Wang --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 35e3801..4f53903 100644 --- a/Makefile +++ b/Makefile @@ -84,14 +84,14 @@ HAVE_LLVM=no else LLVM_PROGS := sparse-llvm $(LLVM_PROGS): LD := g++ -LDFLAGS += $(shell llvm-config --ldflags) +LLVM_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) INST_PROGRAMS += sparse-llvm sparsec sparse-llvm_EXTRA_DEPS := sparse-llvm.o sparse-llvm.o $(sparse-llvm_EXTRA_DEPS): BASIC_CFLAGS += $(LLVM_CFLAGS) -sparse-llvm_EXTRA_OBJS := $(LLVM_LIBS) +sparse-llvm_EXTRA_OBJS := $(LLVM_LIBS) $(LLVM_LDFLAGS) endif endif