From patchwork Mon Jan 25 16:49:16 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 60374 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp1469334lbb; Mon, 25 Jan 2016 08:50:33 -0800 (PST) X-Received: by 10.140.145.196 with SMTP id 187mr23526962qhr.15.1453740630742; Mon, 25 Jan 2016 08:50:30 -0800 (PST) Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id x69si25142901qha.127.2016.01.25.08.50.30 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 25 Jan 2016 08:50:30 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org; dkim=fail header.i=@linaro.org Received: from localhost ([::1]:39638 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aNkLW-0008Sb-8l for patch@linaro.org; Mon, 25 Jan 2016 11:50:30 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34220) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aNkKj-0007VP-Kr for qemu-devel@nongnu.org; Mon, 25 Jan 2016 11:49:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aNkKg-0005ev-Sq for qemu-devel@nongnu.org; Mon, 25 Jan 2016 11:49:41 -0500 Received: from mail-wm0-x231.google.com ([2a00:1450:400c:c09::231]:37465) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aNkKg-0005eg-Lg for qemu-devel@nongnu.org; Mon, 25 Jan 2016 11:49:38 -0500 Received: by mail-wm0-x231.google.com with SMTP id n5so89749748wmn.0 for ; Mon, 25 Jan 2016 08:49:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; bh=5uGzWjf5KVSAAKyk5mOJmgM/T/tE2ShTjD1et9UnVZs=; b=GBZRkfEgJu76DGPo5EYw/IqI8okaW9tr/fBshHN4mEFGAKUIsoHAm/1J091gfaeN7d QQpeqtM0x9NvVj6jTicGWWF4VrRi6UWAAt79yVtn6WInwEr1hQp3lanklTyP9iWQ9+Wv vWgdMAQRYaSpdr56dywE371jsuzlHx4wF+J10= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-type:content-transfer-encoding; bh=5uGzWjf5KVSAAKyk5mOJmgM/T/tE2ShTjD1et9UnVZs=; b=jtfGnzJOm0MIMhtj96eo7xl32HpnIMiv8shZm4kkiOIstM56+ZQKbiWUCLOs/ZTxI/ HVAXts/5VPNcWH8BQLox5uzxUSBVJBbY6U99TATetbJ1HencP1H14OTErQYLoJkfMRLu 3Q3RoJsFmBnGtqFIcT3VbBHdM+2UG9CUFNWUTknxKc9pYu+SC5l0jDoycIwg4MFhUCCR Kx7j5I3pPtIkxD0pPXxWI05mc5mXAzTspYRhdbGJ0U2FCBHiqX4ccxIE1irI9AiyNnEx e0Ksxd3SSFeOAAPGqGqVKeIwd8DV4L9SuqN5bhNepaB+qMbozH3+c0glHG5zPom/cfl0 BIig== X-Gm-Message-State: AG10YOQka1Ksrfb6b3CtbZQ13rVHDh0JWoMiG8iJV2lUL61NYa0JrdOfKBg6jUR3tk2BMzSF X-Received: by 10.28.158.194 with SMTP id h185mr20621141wme.48.1453740577974; Mon, 25 Jan 2016 08:49:37 -0800 (PST) Received: from zen.linaro.local ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id i2sm19916170wjx.42.2016.01.25.08.49.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 25 Jan 2016 08:49:34 -0800 (PST) Received: from zen.linaroharston (localhost [127.0.0.1]) by zen.linaro.local (Postfix) with ESMTP id BC1DA3E1103; Mon, 25 Jan 2016 16:49:33 +0000 (GMT) From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Date: Mon, 25 Jan 2016 16:49:16 +0000 Message-Id: <1453740558-16303-3-git-send-email-alex.bennee@linaro.org> X-Mailer: git-send-email 2.7.0 In-Reply-To: <1453740558-16303-1-git-send-email-alex.bennee@linaro.org> References: <1453740558-16303-1-git-send-email-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::231 Cc: mttcg@listserver.greensocs.com, peter.maydell@linaro.org, mark.burton@greensocs.com, a.rigo@virtualopensystems.com, pbonzini@redhat.com, =?UTF-8?q?Alex=20Benn=C3=A9e?= , fred.konrad@greensocs.com Subject: [Qemu-devel] [RFC PATCH 2/4] configure: introduce --extra-libs X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org If for example you want to use the thread sanitizer you want to ensure all binaries are linked with the library: ./configure ${TARGETS} --cc=gcc-5 --cxx=g++-5 \ --extra-cflags="-fsanitize=thread" --extra-libs="-ltsan" This is more explicit than just specifying --extra-ldflags which might not get applied in the right place all the time. Signed-off-by: Alex Bennée --- configure | 11 +++++++++++ 1 file changed, 11 insertions(+) -- 2.7.0 diff --git a/configure b/configure index 7d23c6c..194bae9 100755 --- a/configure +++ b/configure @@ -365,6 +365,8 @@ for opt do --extra-ldflags=*) LDFLAGS="$LDFLAGS $optarg" EXTRA_LDFLAGS="$optarg" ;; + --extra-libs=*) EXTRA_LIBS="$optarg" + ;; --enable-debug-info) debug_info="yes" ;; --disable-debug-info) debug_info="no" @@ -785,6 +787,8 @@ for opt do ;; --extra-ldflags=*) ;; + --extra-libs=*) + ;; --enable-debug-info) ;; --disable-debug-info) @@ -1281,6 +1285,7 @@ Advanced options (experts only): --objcc=OBJCC use Objective-C compiler OBJCC [$objcc] --extra-cflags=CFLAGS append extra C compiler flags QEMU_CFLAGS --extra-ldflags=LDFLAGS append extra linker flags LDFLAGS + --extra-libs=LIBS append extra libraries when linking --make=MAKE use specified make [$make] --install=INSTALL use specified install [$install] --python=PYTHON use specified python [$python] @@ -4718,6 +4723,11 @@ libs_softmmu="$pixman_libs $libs_softmmu" CFLAGS="$CFLAGS $EXTRA_CFLAGS" QEMU_CFLAGS="$QEMU_CFLAGS $EXTRA_CFLAGS" +# extra-libs +LIBS="$LIBS $EXTRA_LIBS" +libs_softmmu="$libs_softmmu $EXTRA_LIBS" +libs_qga="$libs_qga $EXTRA_LIBS" + echo "Install prefix $prefix" echo "BIOS directory `eval echo $qemu_datadir`" echo "binary directory `eval echo $bindir`" @@ -4888,6 +4898,7 @@ fi echo "qemu_helperdir=$libexecdir" >> $config_host_mak echo "extra_cflags=$EXTRA_CFLAGS" >> $config_host_mak echo "extra_ldflags=$EXTRA_LDFLAGS" >> $config_host_mak +echo "extra_libs=$EXTRA_LIBS" >> $config_host_mak echo "qemu_localedir=$qemu_localedir" >> $config_host_mak echo "libs_softmmu=$libs_softmmu" >> $config_host_mak