From patchwork Sun Jul 14 12:44:00 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnout Vandecappelle X-Patchwork-Id: 1131725 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.137; helo=fraxinus.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=mind.be Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=mind-be.20150623.gappssmtp.com header.i=@mind-be.20150623.gappssmtp.com header.b="yqAnC8AU"; dkim-atps=neutral Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45mmYy3bVTz9sN6 for ; Sun, 14 Jul 2019 22:44:06 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 79E208458E; Sun, 14 Jul 2019 12:44:04 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7yeWdlbSgwJB; Sun, 14 Jul 2019 12:44:04 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id ED97F8461B; Sun, 14 Jul 2019 12:44:03 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 88BFA1BF289 for ; Sun, 14 Jul 2019 12:44:02 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 855858461B for ; Sun, 14 Jul 2019 12:44:02 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2ZZnam7jRERx for ; Sun, 14 Jul 2019 12:44:01 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-ed1-f50.google.com (mail-ed1-f50.google.com [209.85.208.50]) by fraxinus.osuosl.org (Postfix) with ESMTPS id E9B308458E for ; Sun, 14 Jul 2019 12:44:00 +0000 (UTC) Received: by mail-ed1-f50.google.com with SMTP id i11so12941460edq.0 for ; Sun, 14 Jul 2019 05:44:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mind-be.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=e9COLDuIgLrA7oJ32QgeBBCSJOqus3fJfwIP+oajkPI=; b=yqAnC8AUAmh1EKYKgS05mNFxbdViKjf6XVvtYD/BgffSoAWncbeyIcrZSvrG9R0NLk W2g2iS140dk9dC1yqqu+K1NuRLf53ZD0PVM9tDRZnL4xuNIwWc1svIHhnMOuUjXX4e0l S/V1rwZywm3Sd4M3ldEhtx5/QTYWhQvnCBiXqaL2Ncp7N/9he66ICmGnJ8GW/5bj1sOC Y/gn4daQEqmNaWhBcsn/B6ElQU/qyyl58gBNNf0NegiNA3fhZ00//m9AH/SUXqpCshTq zhdFVwGQ/8Bq16iWMLin6XLYgnHpubJuLvyges7JNIgHRG8+Ywmp7Mw1/bWXGaFlXID7 3gDQ== 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:mime-version :content-transfer-encoding; bh=e9COLDuIgLrA7oJ32QgeBBCSJOqus3fJfwIP+oajkPI=; b=NonvHPfc3IwGZPDlNzMW0MrJm7ZgnhYabcEQxBJmGblF1PGuQme1Va6rLNKFUDfcFr P48orbkIfs4lJ+iVM/T3tQRi8CChQK/8zhmnc55n2OFBkrYlB0PrYOuHDsqHZGRUyKj6 45ffprpBvX55XhODJlbSGZ/1AtvXiTWITTAYT9s6BboFzsqnR03zfR3VgRYLVXGtU8Ax AyArWq4VpCaSfnxaInu8/yleS20u3EqJea+HqyyQygVRloWO+PUYarkgIsozRm7Cj0a7 /C0SaA0Ep8+RLJa/9XAjQ6uNS5zzCdbEhza6NN4J8DkkFRtLS39V6THMnYHEwtH5NVD+ JOIQ== X-Gm-Message-State: APjAAAV40thOL5RJSLO+gZzKsizUXQZyb7lix26s+czxngAA5rdWEy6C gthNfBd0n1HcWkrwM+QWBrbLKur2w/defQ== X-Google-Smtp-Source: APXvYqz6S/xqqR+9yW8g30pPd2Sbl5UYPeQxEurKOAwoXO8OCCHv22DH9dmDLSyQri3H/4vgWt8Gnw== X-Received: by 2002:a17:906:2599:: with SMTP id m25mr15793627ejb.177.1563108239079; Sun, 14 Jul 2019 05:43:59 -0700 (PDT) Received: from localhost.localdomain (084035125246.static.ipv4.infopact.nl. [84.35.125.246]) by smtp.gmail.com with ESMTPSA id y11sm3068565ejb.54.2019.07.14.05.43.58 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Sun, 14 Jul 2019 05:43:58 -0700 (PDT) From: "Arnout Vandecappelle (Essensium/Mind)" To: buildroot@buildroot.org Date: Sun, 14 Jul 2019 14:44:00 +0200 Message-Id: <20190714124400.29431-1-arnout@mind.be> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Subject: [Buildroot] [PATCH] utils/checkpackagelib: CommentsMenusPackagesOrder: fix 'menuconfig' handling 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: Jerzy Grzegorek Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" The CommentsMenusPackagesOrder check builds the 'state' to track the depth of menus and conditions. However, a menuconfig doesn't create a menu by itself - it is always followed by a condition that implies the menu. As a result, when unwinding the 'state', the level will be wrong. Fix this by checking for menu followed by a space, so it no longer matches menuconfig. Fixes: https://gitlab.com/buildroot.org/buildroot/-/jobs/251214899 Signed-off-by: Arnout Vandecappelle (Essensium/Mind) Cc: Jerzy Grzegorek --- utils/checkpackagelib/lib_config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/checkpackagelib/lib_config.py b/utils/checkpackagelib/lib_config.py index f0edb9993d..94faf1b0fc 100644 --- a/utils/checkpackagelib/lib_config.py +++ b/utils/checkpackagelib/lib_config.py @@ -73,7 +73,7 @@ class CommentsMenusPackagesOrder(_CheckFunction): def check_line(self, lineno, text): if text.startswith("comment") or text.startswith("if") or \ - text.startswith("menu"): + text.startswith("menu "): if text.startswith("comment"): if not self.state.endswith("-comment"):