From patchwork Wed Apr 27 11:11:53 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Roger_Pau_Monn=C3=A9?= X-Patchwork-Id: 8955211 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D4EA5BF29F for ; Wed, 27 Apr 2016 11:14:52 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DC19B201E4 for ; Wed, 27 Apr 2016 11:14:51 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 423DC2025B for ; Wed, 27 Apr 2016 11:14:50 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1avNOp-0003mq-JY; Wed, 27 Apr 2016 11:12:55 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1avNOp-0003l3-5u for xen-devel@lists.xenproject.org; Wed, 27 Apr 2016 11:12:55 +0000 Received: from [85.158.139.211] by server-1.bemta-5.messagelabs.com id 96/86-27880-6BE90275; Wed, 27 Apr 2016 11:12:54 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrGIsWRWlGSWpSXmKPExsXitHSDve7WeQr hBl3TdS2+b5nM5MDocfjDFZYAxijWzLyk/IoE1oxnK/6xF2zmrri2cxljA+Mfzi5GTg4JAX+J 2d/2M4LYbAI6Ehfn7mTrYuTgEBFQkbi91wAkzCxQLPF1VR8riC0sECDx/OkmNhCbRUBV4uCiK 2BxXgFXiedbTzJDjNSVOLl7EzuIzQkUb2uawAJiCwm4SDy9fQeqXlDi5MwnLBDzNSVat/9mh7 DlJZq3zmaGqFeU6J/3AOwcCQFuib/d9hMY+Wch6Z6FpHsWku4FjMyrGNWLU4vKUot0DfWSijL TM0pyEzNzdA0NTPVyU4uLE9NTcxKTivWS83M3MQLDr56BgXEHY1Ov8yFGSQ4mJVHehe0K4UJ8 SfkplRmJxRnxRaU5qcWHGGU4OJQkeE/PBcoJFqWmp1akZeYAIwEmLcHBoyTCWz8HKM1bXJCYW 5yZDpE6xagoJc6bCNInAJLIKM2Da4NF3yVGWSlhXkYGBgYhnoLUotzMElT5V4ziHIxKwrwHQK bwZOaVwE1/BbSYCWjx5UOyIItLEhFSUg2Mk6RmJDH81jlx7Lz9unc5lW+31b0TCb31SD/yfoJ 1a9WSSf7rt5+M1P7Tk+tU1snGviD8hMee6LUHdFenrT9+P1C4SXjNJBOHQO2/AhmbVfcs/ZDn IpDVt1hPUS9Y5OE8dvlDYlcO3VdM6exbaSvh6ndixqHLnzlzHk3PWirVed501gmfcwtjlViKM xINtZiLihMBEr3cwLkCAAA= X-Env-Sender: prvs=918322aae=roger.pau@citrix.com X-Msg-Ref: server-7.tower-206.messagelabs.com!1461755568!36497476!5 X-Originating-IP: [66.165.176.63] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogNjYuMTY1LjE3Ni42MyA9PiAzMDYwNDg=\n, received_headers: No Received headers X-StarScan-Received: X-StarScan-Version: 8.34; banners=-,-,- X-VirusChecked: Checked Received: (qmail 54839 invoked from network); 27 Apr 2016 11:12:53 -0000 Received: from smtp02.citrix.com (HELO SMTP02.CITRIX.COM) (66.165.176.63) by server-7.tower-206.messagelabs.com with RC4-SHA encrypted SMTP; 27 Apr 2016 11:12:53 -0000 X-IronPort-AV: E=Sophos;i="5.24,541,1454976000"; d="scan'208";a="356738755" From: Roger Pau Monne To: Date: Wed, 27 Apr 2016 13:11:53 +0200 Message-ID: <1461755514-23754-16-git-send-email-roger.pau@citrix.com> X-Mailer: git-send-email 2.6.4 (Apple Git-63) In-Reply-To: <1461755514-23754-1-git-send-email-roger.pau@citrix.com> References: <1461755514-23754-1-git-send-email-roger.pau@citrix.com> MIME-Version: 1.0 X-DLP: MIA1 Cc: Wei Liu , Ian Jackson , Roger Pau Monne Subject: [Xen-devel] [PATCH v3 for-4.7 15/16] tools/python: corrently use LDFLAGS and CFLAGS X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP It is incorrect to add the LDFLAGS to the CFLAGS, and some compilers will error out if linker flags are passed when creating object files. Fix this by properly passing CFLAGS and LDFLAGS, instead of putting everything in CFLAGS. Signed-off-by: Roger Pau Monné Reviewed-by: Doug Goldstein Acked-by: Wei Liu --- Cc: Ian Jackson Cc: Wei Liu --- tools/python/Makefile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tools/python/Makefile b/tools/python/Makefile index 2363537..da08f46 100644 --- a/tools/python/Makefile +++ b/tools/python/Makefile @@ -4,7 +4,8 @@ include $(XEN_ROOT)/tools/Rules.mk .PHONY: all all: build -PY_CFLAGS = $(CFLAGS) $(PY_NOOPT_CFLAGS) $(LDFLAGS) $(APPEND_LDFLAGS) +PY_CFLAGS = $(CFLAGS) $(PY_NOOPT_CFLAGS) +PY_LDFLAGS = $(LDFLAGS) $(APPEND_LDFLAGS) .PHONY: build build: @@ -14,8 +15,9 @@ build: install: $(INSTALL_DIR) $(DESTDIR)$(LIBEXEC_BIN) - CC="$(CC)" CFLAGS="$(PY_CFLAGS)" $(PYTHON) setup.py install \ - $(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" --force + CC="$(CC)" CFLAGS="$(PY_CFLAGS)" LDFLAGS="$(PY_LDFLAGS)" $(PYTHON) \ + setup.py install $(PYTHON_PREFIX_ARG) --root="$(DESTDIR)" \ + --force $(INSTALL_PROG) scripts/convert-legacy-stream $(DESTDIR)$(LIBEXEC_BIN) $(INSTALL_PROG) scripts/verify-stream-v2 $(DESTDIR)$(LIBEXEC_BIN)