From patchwork Sun Aug 4 00:14:28 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Duskett X-Patchwork-Id: 1141625 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.138; helo=whitealder.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="mMprV0Q3"; dkim-atps=neutral Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 461Lxg5GS9z9sMr for ; Sun, 4 Aug 2019 10:14:47 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 483B1871F4; Sun, 4 Aug 2019 00:14:44 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id I2VkWMTASTlJ; Sun, 4 Aug 2019 00:14:42 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id C5A7B869D3; Sun, 4 Aug 2019 00:14:41 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 602491BF964 for ; Sun, 4 Aug 2019 00:14:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 5CEE9203D7 for ; Sun, 4 Aug 2019 00:14:39 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ODz23Hz7CtZf for ; Sun, 4 Aug 2019 00:14:38 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-io1-f48.google.com (mail-io1-f48.google.com [209.85.166.48]) by silver.osuosl.org (Postfix) with ESMTPS id A95BC203D0 for ; Sun, 4 Aug 2019 00:14:38 +0000 (UTC) Received: by mail-io1-f48.google.com with SMTP id k20so6955365ios.10 for ; Sat, 03 Aug 2019 17:14:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=3jhk6UTxTo37ktp0NtFI8kF7bp53MCmJ3C4UrdIaJew=; b=mMprV0Q3Xso7FIoDYxVWBqrkH4lsFBv42nCOttRFF83cP+UJP9ZsNxh6HDbSQ9h/Z9 q86aZngXaBEPJfbJmiceB9VhN7qvOx3KpVT0OKLgzVkNQRtw77GHpnv7wn2MG3yvl4ex zscM5kts05lBLlJZMGykWvofjsRwO0okp3Ja+Jh2tnolRFxQPFHKomb/2sKQBNwxdGZ9 gwGlVivhppV3HUOFZYfX2/GhEsGg0crvcHdwayGQUfXq665y+wjxuXzcHX7B0q/JN8IU 72Fe0QNv9x16lmSZ0Uc79l4HGD+Mu8TRGnDeUURkoiur0QeN0SJzKo4r1XQWO9zF7YwI lRFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=3jhk6UTxTo37ktp0NtFI8kF7bp53MCmJ3C4UrdIaJew=; b=RkWPYTNfak0y0kQUCeIF40mS9D6uKyzVa/u/NYxQBzwapHsHB78GI4NjHNBbVuix8K iFCpSQnJ7xT4psuIZtUCvOL0TdmwIC1NCUq8wTztswZVtpmSZqR8hJhwDQg6gHOa4quq 0pzm3O2FoWF41MD/R2mb7uA2DLX445gPq8SooIFKCDYLI5sUIFePO6FvbX8q+K0SOBtF j4OtjWs9d22N9rQcoh1Gc8t/TkKdGWZuJYBuUz9mr39CEOEJ+d/cWRB24xxUbffmx/DM ZNiK9kxSZCZcu2jaBgWlWZz/B4qd63VULguc/Dzf7IOOBz4+j5RijXaSZtShhOnnfMKP /gKQ== X-Gm-Message-State: APjAAAUP7+4xiGL3TNIUzUOeQiHkHXFcYUMQ+B/1+qw2FuBf2HTvZ1k6 d21SfremM2xrGGGD7WCuY61MUIr/ X-Google-Smtp-Source: APXvYqzkD94NWbFdgeDomPTWYQ4WC17DooXJRjYMyIVsibcsJsRm4yrMWMV3HsY21ckR+DHgCC7eKA== X-Received: by 2002:a6b:b9c2:: with SMTP id j185mr911615iof.148.1564877677803; Sat, 03 Aug 2019 17:14:37 -0700 (PDT) Received: from localhost.localdomain (68-188-149-81.dhcp.aldl.mi.charter.com. [68.188.149.81]) by smtp.gmail.com with ESMTPSA id p3sm122543923iom.7.2019.08.03.17.14.36 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Sat, 03 Aug 2019 17:14:37 -0700 (PDT) From: aduskett@gmail.com To: buildroot@buildroot.org Date: Sat, 3 Aug 2019 20:14:28 -0400 Message-Id: <20190804001429.51451-4-aduskett@gmail.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190804001429.51451-1-aduskett@gmail.com> References: <20190804001429.51451-1-aduskett@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCH v13 4/5] package/meson: prevent python include path manipulation X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Adam Duskett Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Adam Duskett From: https://github.com/openembedded/openembedded-core/blob/master/meta/recipes-devtools/meson/meson/ Meson exports a bunch of PKG_CONFIG_ variables which causes a double prefix for the staging python include directory. Signed-off-by: Adam Duskett --- Changes v11 -> v12: - Remove accidental copy and paste in the commit message. Changes v1 -> v11: - Add this patch to the series ...-environment-when-calling-pkg-config.patch | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 package/meson/0002-python-module-do-not-manipulate-the-environment-when-calling-pkg-config.patch diff --git a/package/meson/0002-python-module-do-not-manipulate-the-environment-when-calling-pkg-config.patch b/package/meson/0002-python-module-do-not-manipulate-the-environment-when-calling-pkg-config.patch new file mode 100644 index 0000000000..a72be80bae --- /dev/null +++ b/package/meson/0002-python-module-do-not-manipulate-the-environment-when-calling-pkg-config.patch @@ -0,0 +1,48 @@ +From 3cb2c811dc6d4890342afa5b709cd30cf7b8f3ca Mon Sep 17 00:00:00 2001 +From: Alexander Kanavin +Date: Mon, 19 Nov 2018 14:24:26 +0100 +Subject: [PATCH] python module: do not manipulate the environment when calling pkg-config + +From: https://github.com/openembedded/openembedded-core/blob/master/meta/recipes-devtools/meson/meson/ + +Meson exports a bunch of PKG_CONFIG_ variables which causes a double prefix to +the python include directory. + +Upstream-Status: Inappropriate [embedded specific] +Signed-off-by: Alexander Kanavin +Signed-off-by: Adam Duskett + +--- + mesonbuild/modules/python.py | 12 ------------ + 1 file changed, 12 deletions(-) + +diff --git a/mesonbuild/modules/python.py b/mesonbuild/modules/python.py +index 9cfbd6f..3ff687a 100644 +--- a/mesonbuild/modules/python.py ++++ b/mesonbuild/modules/python.py +@@ -76,11 +76,6 @@ class PythonDependency(ExternalDependency): + old_pkg_libdir = os.environ.get('PKG_CONFIG_LIBDIR') + old_pkg_path = os.environ.get('PKG_CONFIG_PATH') + +- os.environ.pop('PKG_CONFIG_PATH', None) +- +- if pkg_libdir: +- os.environ['PKG_CONFIG_LIBDIR'] = pkg_libdir +- + try: + self.pkgdep = PkgConfigDependency('python-{}'.format(pkg_version), environment, kwargs) + mlog.debug('Found "python-{}" via pkgconfig lookup in LIBPC ({})'.format(pkg_version, pkg_libdir)) +@@ -89,13 +84,6 @@ class PythonDependency(ExternalDependency): + mlog.debug('"python-{}" could not be found in LIBPC ({})'.format(pkg_version, pkg_libdir)) + mlog.debug(e) + +- if old_pkg_path is not None: +- os.environ['PKG_CONFIG_PATH'] = old_pkg_path +- +- if old_pkg_libdir is not None: +- os.environ['PKG_CONFIG_LIBDIR'] = old_pkg_libdir +- else: +- os.environ.pop('PKG_CONFIG_LIBDIR', None) + else: + mlog.debug('"python-{}" could not be found in LIBPC ({}), this is likely due to a relocated python installation'.format(pkg_version, pkg_libdir)) +