From patchwork Sun Nov 27 13:07:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709328 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpnH1c5Kz23nB for ; Mon, 28 Nov 2022 00:08:19 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 9097A60B10; Sun, 27 Nov 2022 13:08:14 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 9097A60B10 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tadZzwEcYQ4r; Sun, 27 Nov 2022 13:08:13 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id AB98B60AD2; Sun, 27 Nov 2022 13:08:12 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org AB98B60AD2 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id B89A61BF42C for ; Sun, 27 Nov 2022 13:08:00 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id A184060AD2 for ; Sun, 27 Nov 2022 13:08:00 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org A184060AD2 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZXJIyiqVPndP for ; Sun, 27 Nov 2022 13:07:59 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 5A45C605A1 Received: from mail-oa1-x29.google.com (mail-oa1-x29.google.com [IPv6:2001:4860:4864:20::29]) by smtp3.osuosl.org (Postfix) with ESMTPS id 5A45C605A1 for ; Sun, 27 Nov 2022 13:07:59 +0000 (UTC) Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-14286d5ebc3so10202178fac.3 for ; Sun, 27 Nov 2022 05:07:59 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3cqdnmzB1uck8A5PFV23hRp+qyirNspWzYVEiHTntrY=; b=lotHCEY1qPPNnVGBo/Qg6wVyKlovGtMstEEIScfwZ6yxaGBrfj9QdzM4aqoNjt63M3 Pv0N+FmXIr9GAHWQY4BhfmCK+qcx+uz/o1vOPQ8KCzo4J62HluDqxMOaUPQ41iGCnkSA DY7XKui1OZweE5B1rccUC1KaCQHqmyNYBTWB2aa3aigBua1UD5jdprAhkHB2vB77wQmx rvXw6FiTutChM7U94v3bt6ZOpHccgoVJfW/CbkllHaQczsAnpkSMCwkRJXwuxyULxIm1 zSCV9yaO9Vro5aFCPE+aYeOJYm2V18pPCIRPbYkt9ZZbBYDnjmMWb0hoedYFou5NqCXJ TZKw== X-Gm-Message-State: ANoB5plOo0JbEWnQbJiw0SmE3wCGSj+C4hA7fASxuxEHjWkHWOEFjlNu oXgaeFnCrxkMsASJoRB5EYlPonSNZUE= X-Google-Smtp-Source: AA0mqf7gwfTxwbEPyrVxgJ0Pdjng6MapG3L734Lr2S9YyZD2lUB096dLrQDUHWik0IjilTYDrKDHCw== X-Received: by 2002:a05:6870:9d09:b0:143:2972:e928 with SMTP id pp9-20020a0568709d0900b001432972e928mr12539702oab.69.1669554478396; Sun, 27 Nov 2022 05:07:58 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.07.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:07:57 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:15 -0300 Message-Id: <20221127130739.1862398-2-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=3cqdnmzB1uck8A5PFV23hRp+qyirNspWzYVEiHTntrY=; b=ON7EHo+Sv4BCTKHHd4gXJ3xPfivbUlv4MjIfRpWEA9est7g1Zyob5vJ9amXARGSeED 3b1Jns8dYUnCGmm6nlO5ZKfFWZgYOalkJ7rqWZPE/Cmtd6JPdaSfoF+5UrZq+wRyRjor WEnN6o8H78OxmseyG4BEUMRwbMM4ZJCg72fO2tKbbN/TxGoP1b9R+zbMVeAZUjZ0OILK 7iMJ+3dztaHJfStPRRufHlp60wy1Kj7dfEOcnt/fOLXQYppGwjLP1A7Ia651IDJ/3Hrn uqWHNDBd95fd4UyX3RBBkFjFd2ZSaZxPdNt38RTp9iygs2r2VYARlFsDVWnxhgi0SnDX OdrQ== X-Mailman-Original-Authentication-Results: smtp3.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=ON7EHo+S Subject: [Buildroot] [next 01/25] *: fix typo for separate(d|) in text X-BeenThere: buildroot@buildroot.org 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: Bernd Kuhls , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" seperate is a common misspelling of separate Fix all the typos in the tree that are not related to patch files. CHANGES seperate -> separate, in the list of changes Config.in.legacy seperate -> separate, in option name and help texts package/leafnode2/leafnode2.mk seperate -> separate, in a comment system/Config.in seperated -> separated, in a help text Cc: Bernd Kuhls Signed-off-by: Ricardo Martincoski --- CHANGES | 4 ++-- Config.in.legacy | 6 +++--- package/leafnode2/leafnode2.mk | 2 +- system/Config.in | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/CHANGES b/CHANGES index 3090466d2e..192546993f 100644 --- a/CHANGES +++ b/CHANGES @@ -7475,7 +7475,7 @@ Architecture: Default to bf532 CPU variant for blackfin, Fix flat one memory region support for m68k and disable flat - seperate data support because of compatibility issues. + separate data support because of compatibility issues. Defconfigs: Minnowboard and Raspberrypi: Fix errors with post-build scripts when systemd is used. @@ -8011,7 +8011,7 @@ Minor fixes. - Merged/seperate /usr handling is now also performed for + Merged/separate /usr handling is now also performed for staging so cross-gdb / gdbserver can find the libraries. Updated/fixed packages: autossh, conntrack-tools, dcron, diff --git a/Config.in.legacy b/Config.in.legacy index 17f0858e70..284e7bf887 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -3240,7 +3240,7 @@ config BR2_PACKAGE_POLICYCOREUTILS_RESTORECOND select BR2_PACKAGE_RESTORECOND help The policycoreutils package no longer offers restorecond - as a option. This package has been moved into a seperate + as a option. This package has been moved into a separate package maintained by the SELinux maintainers. config BR2_PACKAGE_SEPOLGEN @@ -3834,7 +3834,7 @@ config BR2_GDB_VERSION_7_9 comment "Legacy options removed in 2016.11" config BR2_PACKAGE_PHP_SAPI_CLI_CGI - bool "PHP CGI and CLI options are now seperate" + bool "PHP CGI and CLI options are now separate" select BR2_PACKAGE_PHP_SAPI_CLI select BR2_PACKAGE_PHP_SAPI_CGI select BR2_LEGACY @@ -4864,7 +4864,7 @@ config BR2_PACKAGE_KODI_PVR_ADDONS select BR2_PACKAGE_KODI_PVR_VUPLUS select BR2_PACKAGE_KODI_PVR_WMC help - Kodi PVR addon was split into seperate modules + Kodi PVR addon was split into separate modules config BR2_BINUTILS_VERSION_2_23_2 bool "binutils 2.23 option renamed" diff --git a/package/leafnode2/leafnode2.mk b/package/leafnode2/leafnode2.mk index a02aad4302..e82ca2e1ee 100644 --- a/package/leafnode2/leafnode2.mk +++ b/package/leafnode2/leafnode2.mk @@ -23,7 +23,7 @@ LEAFNODE2_CONF_OPTS = \ --enable-runas-user=root # Leafnode2 needs the host version of b_sortnl during -# compilation. Instead of creating a seperate host package and +# compilation. Instead of creating a separate host package and # installing b_sortnl to $(HOST_DIR) this binary is compiled # on-the-fly, host-pcre is needed for this define LEAFNODE2_BUILD_SORTNL_TOOL diff --git a/system/Config.in b/system/Config.in index 888c24ce81..e6dcd25455 100644 --- a/system/Config.in +++ b/system/Config.in @@ -443,7 +443,7 @@ config BR2_ENABLE_LOCALE_WHITELIST default "C en_US" depends on BR2_ENABLE_LOCALE_PURGE help - Whitespace seperated list of locales to allow on target. + Whitespace separated list of locales to allow on target. Locales not listed here will be removed from the target. See 'locale -a' on your host for a list of locales available on your build host, or have a look in /usr/share/locale in From patchwork Sun Nov 27 13:07:16 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709329 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpnT1MdZz23nB for ; Mon, 28 Nov 2022 00:08:29 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 41FAF81AEF; Sun, 27 Nov 2022 13:08:27 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 41FAF81AEF X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GGROHdeo6w0m; Sun, 27 Nov 2022 13:08:26 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 7A15181AAB; Sun, 27 Nov 2022 13:08:25 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 7A15181AAB X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 161FF1BF42C for ; Sun, 27 Nov 2022 13:08:03 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id E43C94099F for ; Sun, 27 Nov 2022 13:08:02 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org E43C94099F X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aZmOkID16_Wh for ; Sun, 27 Nov 2022 13:08:02 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org CFA134098A Received: from mail-oi1-x22c.google.com (mail-oi1-x22c.google.com [IPv6:2607:f8b0:4864:20::22c]) by smtp4.osuosl.org (Postfix) with ESMTPS id CFA134098A for ; Sun, 27 Nov 2022 13:08:01 +0000 (UTC) Received: by mail-oi1-x22c.google.com with SMTP id q83so9007810oib.10 for ; Sun, 27 Nov 2022 05:08:01 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xif48wvjxmSFCzPkEj+GZMOC7ubIcSZuLpdw5rzTfGA=; b=t6me8EKjqxoe+kIlcZV3sowUzqzChCCt77umzTdUUwjF2lEDe1j7xNpG3rFuqfC4jr nFBImsVU0B5rrUK9a+IL8N1DOp2UF3/9r8DOrzPBuoEhv3M+GIKEnAzZ1dAXlpwx/nEa xqHtFmghVENw5gV7bcw74WMqPLeSlZj2ZXROv9CcXhbeDbs+PiBdl6R7EAW1k1rNg0Vm 5kNUbSUkiFOD84X9V7Nk4cfJi4zDwZHvkhVbInJTYNHU4xIkpBMs6VbwNMNJgHCzyyX3 n0bMwHMuYzMAcM0VfesPtHWL9ST4w6FuLcHIdYZDE8IyIGU/cu2Q+1LnJyCd6xFxR+A5 LNJg== X-Gm-Message-State: ANoB5pn6e48UcIfwoQBrVbI11kOth18hnoCEZpssgU+HRbjyRNvh7Bmf 2kOMUPf7lF9NsCuzBg2Ajg2meq8leCg= X-Google-Smtp-Source: AA0mqf6wY6+0ob15J3U2bfqQyb63NMClcN+svmFpeXWf/Cw4EPW4ZwVOHyKxp4goDGy5nkW4AioatA== X-Received: by 2002:aca:d10:0:b0:359:ad61:e574 with SMTP id 16-20020aca0d10000000b00359ad61e574mr12574623oin.221.1669554480934; Sun, 27 Nov 2022 05:08:00 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.07.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:07:59 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:16 -0300 Message-Id: <20221127130739.1862398-3-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=xif48wvjxmSFCzPkEj+GZMOC7ubIcSZuLpdw5rzTfGA=; b=TvamxyC+3AFCna+neHgU4qODqU1k4TqDN+m8m+QcF3zQc40q1hP/Xh07VBq+okgiq8 quuuu1XUjZzRawKa23LubdBz5F0aTIaRZbRq/He2gO7eyuq/ln+LyDaNsu5UBDeB2yBT yZZuw/8BKOwR2I+UJ6Mb4HZmd/oK3aZTxTYmb9yq+PcnqkdOngituddc7dS1eQ91KEFH f7UVHglzxbFvcROGgNZeRTdg/2PTJwyniblB4A/1SfWYUnouX+YB65VcsPC5WJ3FcmfM G72Dv9YgEPCtxcbv5vyqOvpaaa2HJM6SrBQtcj5yZDIeGRsvAVISm1NsdQt/DxDOyTh6 p4pw== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=TvamxyC+ Subject: [Buildroot] [next 02/25] package, legacy: fix typo for "daemon" on help text X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" deamon -> daemon At same time, in Config.in.legacy fix other typos in the same help text: spae -> space monolitic -> monolithic Signed-off-by: Ricardo Martincoski --- Config.in.legacy | 4 ++-- package/ngircd/Config.in | 2 +- package/rp-pppoe/Config.in | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Config.in.legacy b/Config.in.legacy index 284e7bf887..4eff5b55d6 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -4324,8 +4324,8 @@ config BR2_PACKAGE_OPENPOWERLINK_LIBPCAP select BR2_PACKAGE_OPENPOWERLINK_STACK_USERSPACE_DAEMON_LIB help The user space support has been split in two part: - - a monolitic user space library - - a user spae deamon driver + - a monolithic user space library + - a user space daemon driver config BR2_LINUX_KERNEL_SAME_AS_HEADERS bool "using the linux headers version for the kernel has been removed" diff --git a/package/ngircd/Config.in b/package/ngircd/Config.in index 9b3d430922..1e93a5702c 100644 --- a/package/ngircd/Config.in +++ b/package/ngircd/Config.in @@ -2,6 +2,6 @@ config BR2_PACKAGE_NGIRCD bool "ngircd" depends on BR2_USE_MMU # fork() help - Next Generation IRC server deamon. + Next Generation IRC server daemon. http://ngircd.barton.de diff --git a/package/rp-pppoe/Config.in b/package/rp-pppoe/Config.in index 2ac81cbb2d..6ff005a1e1 100644 --- a/package/rp-pppoe/Config.in +++ b/package/rp-pppoe/Config.in @@ -9,7 +9,7 @@ config BR2_PACKAGE_RP_PPPOE select BR2_PACKAGE_PPPD help An implementation of the Point-to-point protocol over - Ethernet. Has userspace client and server deamons. You + Ethernet. Has userspace client and server daemons. You likely only need this package if you are implementing the pppoe server that will service other pppoe client devices. Otherwise the normal client functionality already From patchwork Sun Nov 27 13:07:17 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709330 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpnk0Kbrz23nB for ; Mon, 28 Nov 2022 00:08:42 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id C40608144F; Sun, 27 Nov 2022 13:08:39 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org C40608144F X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lTSK2WeXRotW; Sun, 27 Nov 2022 13:08:39 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 1557E81419; Sun, 27 Nov 2022 13:08:38 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 1557E81419 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id EE8251BF42C for ; Sun, 27 Nov 2022 13:08:04 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id CA5AE81AC1 for ; Sun, 27 Nov 2022 13:08:04 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org CA5AE81AC1 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xq9nPi7MpgHG for ; Sun, 27 Nov 2022 13:08:04 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 2F41A81AAB Received: from mail-oi1-x230.google.com (mail-oi1-x230.google.com [IPv6:2607:f8b0:4864:20::230]) by smtp1.osuosl.org (Postfix) with ESMTPS id 2F41A81AAB for ; Sun, 27 Nov 2022 13:08:04 +0000 (UTC) Received: by mail-oi1-x230.google.com with SMTP id v82so9037730oib.4 for ; Sun, 27 Nov 2022 05:08:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fuTtuQDZkYQSTRkD9VcL6aJwMXipj85xN8sWamDOY6g=; b=f5gU9eELEoIsuen1RU5Vw/gl1U0KcQBwlHMQAMr4C69+ABlK9ewoG8b+bw4FCp62Os NhRsiSSxvtNqHDcD5oG8NxOzxDlLSDe8GB/f/E/YnXnbEncXYXEbS6PhXW+acHBo+Wuf mK3Jea72SekNMV9WiI4NxAHPxhvxi6NI3ztioyd/6Rmhu0N+W9+Byd1WaEhGnP5oyYS/ ZchTojylWJ4odDycqoaqBPqvkONTQxT8dQV31++9YZ3ffGB9nL1rJGq4foIRKJ54y909 BkUa7cqzsnM5f+rIIcDYkOvJ9D63z7nEEg2CLqmZV3QqBSck5eVIduMe3qKNdQNQRXLi EfoA== X-Gm-Message-State: ANoB5pnplyIPhMI0rPXwvaf3vdVRcaBpu+RPyyCh81aykt4iBVOwTK+U q3Z01JgjoSsk/nblP+9/Bt/nkvmJJQo= X-Google-Smtp-Source: AA0mqf6IJJYvF0I67/BBA/Na4NyfXxOkX8tpZdWbI/nC12hqexMISj2T/BeMvjSny29X9d/UJ8s8fg== X-Received: by 2002:aca:3d07:0:b0:35b:4cbf:b9e9 with SMTP id k7-20020aca3d07000000b0035b4cbfb9e9mr12385426oia.127.1669554483879; Sun, 27 Nov 2022 05:08:03 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:02 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:17 -0300 Message-Id: <20221127130739.1862398-4-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=fuTtuQDZkYQSTRkD9VcL6aJwMXipj85xN8sWamDOY6g=; b=TYOGwYo8w+dnDluw5acpEloDp/n/nTwJJCcVAqsAx12ePYn24SjYjvuSyiuNhCBFWf oiqjdVy5PgRhKwW2Y0Vtxpnx1XR06ZyTkvuhAATHQAFNK1HGr9xNbLTLFD9bKGUBgnCA qd/4OghLQBaDj7B0GbkdTfdIKUc8Q7S3MvhZZnvsc6dmmQk4QWk8tsKIXVs//ujFJhiX 4isb47NKJv2mGCK4lFYvqxKDB+mOkFttvLB4ankQ4OKhWPsL3oSRvdLoIlFOMQTVFFK0 SMvI8AB62Uf2LK/jnHnXwdK/shhBmqWsIQVX+hI73gzExFwaJ8NR0+jmKFMQHS9siRu8 hkUg== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=TYOGwYo8 Subject: [Buildroot] [next 03/25] Config.in.legacy: fix typo on BR2_PACKAGE_MEDIAART_BACKEND_QT X-BeenThere: buildroot@buildroot.org 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: Thomas Petazzoni , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Currently using this minimal .config: BR2_PACKAGE_MEDIAART_BACKEND_GDK_PIXBUF=y triggers: *** Legacy options removed in 2018.05 *** [ ] libmediaart none backend option renamed (NEW) [*] libmediaart gdk-pixbuf backend option renamed [*] libmediaart qt backend option renamed Commit "8553b39887 libmediaart: rename options to have proper prefix", part of the 2018.05 release had a copy&paste error. As stated in the beginning of the file: The oldest symbols will be removed again after about two years. But while we carry these legacy symbols, let's fix the typo. Cc: Thomas Petazzoni Signed-off-by: Ricardo Martincoski --- NOTE: Maybe it is time to drop old legacy symbols again? If so, some patches in this series can be dropped. --- Config.in.legacy | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Config.in.legacy b/Config.in.legacy index 4eff5b55d6..9ce1004b0c 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -2594,7 +2594,7 @@ config BR2_PACKAGE_MEDIAART_BACKEND_GDK_PIXBUF BR2_PACKAGE_MEDIAART_BACKEND_GDK_PIXBUF has been renamed to BR2_PACKAGE_LIBMEDIAART_BACKEND_GDK_PIXBUF -config BR2_PACKAGE_MEDIAART_BACKEND_GDK_PIXBUF +config BR2_PACKAGE_MEDIAART_BACKEND_QT bool "libmediaart qt backend option renamed" select BR2_LEGACY help From patchwork Sun Nov 27 13:07:18 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709331 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpnz2jXZz23nB for ; Mon, 28 Nov 2022 00:08:55 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id CBB42410BD; Sun, 27 Nov 2022 13:08:52 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org CBB42410BD X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7ly7qHT5cvBv; Sun, 27 Nov 2022 13:08:51 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id 86FAB410BE; Sun, 27 Nov 2022 13:08:50 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 86FAB410BE X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 269431BF42C for ; Sun, 27 Nov 2022 13:08:09 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 0E8544099F for ; Sun, 27 Nov 2022 13:08:09 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 0E8544099F X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2zw6UxtoO7tp for ; Sun, 27 Nov 2022 13:08:08 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org D7BFC4098A Received: from mail-oi1-x229.google.com (mail-oi1-x229.google.com [IPv6:2607:f8b0:4864:20::229]) by smtp4.osuosl.org (Postfix) with ESMTPS id D7BFC4098A for ; Sun, 27 Nov 2022 13:08:07 +0000 (UTC) Received: by mail-oi1-x229.google.com with SMTP id c129so9058631oia.0 for ; Sun, 27 Nov 2022 05:08:07 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=rBRMadNFAJQZBi6uC9EFFKI9wHDhRLKABQ7RU8KdhxU=; b=VXGih6I0R2eGs7jwxomqmqgX5oLQdzcZGjSsysujsNyd+hz0U275MmnJuzUwQDq+VW Wu+ZrlUCEjn2XwElh+mishSVttFsDRBfzXH0vV30I1pz8VYIFrI3xVwZZ6SI/Qe4JC8O uh/sC64YnLmwCM8I+st+R/Phl2HlEz7B0I/I87eylm9d2C+wp/PC/Aqjb5AhKjXktLf+ WFq+xnjjeuemhL1DTAVLiu8IGYrdTJ+1H/TW9k7k9MFw/PjeZYXUtogFqJE7xuPc/m2L BPyzVZB8Z94ZrUhoplOkgB2giWGbGI2B2Caxl5qQ3GRB/DZt493x1rSb/pV7Xz7YUpvB gAKg== X-Gm-Message-State: ANoB5pkWNE66IkdLYpy6DDYih2x0aooiWTNFZnC5m4CoNSz124JUiJ3B UBa9SGVHgNhS5W6dCxMgGmeGYf6Y0So= X-Google-Smtp-Source: AA0mqf6ph562pb/cDstWFD8h/EtGeWSTtUWI57Nm52sMlmr7BfLlpYSIGbi9mZlUvYcd36cx+I2jWA== X-Received: by 2002:a54:401a:0:b0:35a:f075:6791 with SMTP id x26-20020a54401a000000b0035af0756791mr13134379oie.20.1669554486877; Sun, 27 Nov 2022 05:08:06 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:05 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:18 -0300 Message-Id: <20221127130739.1862398-5-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=rBRMadNFAJQZBi6uC9EFFKI9wHDhRLKABQ7RU8KdhxU=; b=YlAzORdnGg9ezS0yuKlZmkgAZRbPBpLt2QtPhd8DbfOeVStk3tOwp22Woe2yLpdsho zWtTeWjBPeNhnp4huW6BSmZ8e5dvEKVRC8yZFcITxlveePHh/ERt9mVJAsrarp63f1Gw oCxYfidpYNu3ua4zReIoC73VIh+mx6u1QSY9HR3za5uaGanCQquJOe7vG3Q8eNKGe/z0 JmM3tTQTxwbOTdsDzuEW//U9sjyq0i49QPHZi5oO3GpxJMPQBSzUX4sV9J1262qAquGU IwmyV7TYyMd+DCFrMKeXujiYZNkwq4W1OTg0wo9HJpZ/aUwiMJIqug2x5UehWBq+w6cC 0pVw== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=YlAzORdn Subject: [Buildroot] [next 04/25] utils/checkpackagelib: warn about redefined config X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Warn the developer in the case the same config is declared more than once in the same Config.in file. But take into account the conditional code that lets the config be visible and warn only when it is declared more than once in the same conditions. For instance, do not warn for: if BR2_PACKAGE_BUSYBOX config BR2_PACKAGE_BUSYBOX_SHOW_OTHERS endif if !BR2_PACKAGE_BUSYBOX # kconfig doesn't support else config BR2_PACKAGE_BUSYBOX_SHOW_OTHERS endif Signed-off-by: Ricardo Martincoski --- Applying only this patch on current master, check-package returns: Config.in.legacy:2597: config BR2_PACKAGE_MEDIAART_BACKEND_GDK_PIXBUF redeclared (previous line: 2589) --- utils/checkpackagelib/lib_config.py | 38 ++++++++++++ utils/checkpackagelib/test_lib_config.py | 78 ++++++++++++++++++++++++ 2 files changed, 116 insertions(+) diff --git a/utils/checkpackagelib/lib_config.py b/utils/checkpackagelib/lib_config.py index b05831f2c3..f26ca0d898 100644 --- a/utils/checkpackagelib/lib_config.py +++ b/utils/checkpackagelib/lib_config.py @@ -233,3 +233,41 @@ class Indent(_CheckFunction): return ["{}:{}: should not be indented" .format(self.filename, lineno), text] + + +class RedefinedConfig(_CheckFunction): + CONFIG = re.compile(r"^\s*(menu|)config\s+(BR2_\w+)\b") + IF = re.compile(r"^\s*if\s+([^#]*)\b") + ENDIF = re.compile(r"^\s*endif\b") + + def before(self): + self.configs = {} + self.conditional = [] + + def check_line(self, lineno, text): + if _empty_or_comment(text) or _part_of_help_text(text): + return + + m = self.IF.search(text) + if m is not None: + condition = m.group(1) + self.conditional.append(condition) + return + + m = self.ENDIF.search(text) + if m is not None: + self.conditional.pop() + return + + m = self.CONFIG.search(text) + if m is None: + return + config = m.group(2) + + key = (config, ' AND '.join(self.conditional)) + if key in self.configs.keys(): + previous_line = self.configs[key] + return ["{}:{}: config {} redeclared (previous line: {})" + .format(self.filename, lineno, config, previous_line), + text] + self.configs[key] = lineno diff --git a/utils/checkpackagelib/test_lib_config.py b/utils/checkpackagelib/test_lib_config.py index 91a549adf2..474d17105e 100644 --- a/utils/checkpackagelib/test_lib_config.py +++ b/utils/checkpackagelib/test_lib_config.py @@ -385,3 +385,81 @@ Indent = [ def test_Indent(testname, filename, string, expected): warnings = util.check_file(m.Indent, filename, string) assert warnings == expected + + +RedefinedConfig = [ + ('no redefinition', + 'any', + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'config BR2_PACKAGE_FOO_BAR\n' + 'bool "foo"\n', + []), + ('no conditional', + 'any', + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'config BR2_PACKAGE_BAR\n' + 'bool "bar"\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n', + [['any:5: config BR2_PACKAGE_FOO redeclared (previous line: 1)', + 'config BR2_PACKAGE_FOO\n']]), + ('three times', + 'any', + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n', + [['any:3: config BR2_PACKAGE_FOO redeclared (previous line: 1)', + 'config BR2_PACKAGE_FOO\n'], + ['any:5: config BR2_PACKAGE_FOO redeclared (previous line: 1)', + 'config BR2_PACKAGE_FOO\n']]), + ('same conditional', + 'any', + 'if BR2_PACKAGE_BAZ\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'config BR2_PACKAGE_BAR\n' + 'bool "bar"\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'endif\n', + [['any:6: config BR2_PACKAGE_FOO redeclared (previous line: 2)', + 'config BR2_PACKAGE_FOO\n']]), + ('equivalent conditional', + 'any', + 'if BR2_PACKAGE_BAZ\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'endif\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'if BR2_PACKAGE_BAZ\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'endif\n', + [['any:8: config BR2_PACKAGE_FOO redeclared (previous line: 2)', + 'config BR2_PACKAGE_FOO\n']]), + ('not equivalent conditional', + 'any', + 'if BR2_PACKAGE_BAZ\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'endif\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'if !BR2_PACKAGE_BAZ\n' + 'config BR2_PACKAGE_FOO\n' + 'bool "foo"\n' + 'endif\n', + []), + ] + + +@pytest.mark.parametrize('testname,filename,string,expected', RedefinedConfig) +def test_RedefinedConfig(testname, filename, string, expected): + warnings = util.check_file(m.RedefinedConfig, filename, string) + assert warnings == expected From patchwork Sun Nov 27 13:07:19 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709332 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKppC33VGz23nB for ; Mon, 28 Nov 2022 00:09:07 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id A6B9E60B10; Sun, 27 Nov 2022 13:09:05 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org A6B9E60B10 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wq2hLU8ixRwU; Sun, 27 Nov 2022 13:09:04 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id E22F6605A1; Sun, 27 Nov 2022 13:09:03 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org E22F6605A1 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id A6BA31BF42C for ; Sun, 27 Nov 2022 13:08:11 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 9022260AD2 for ; Sun, 27 Nov 2022 13:08:11 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 9022260AD2 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TRD1BLh055ko for ; Sun, 27 Nov 2022 13:08:10 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org A3C00605A1 Received: from mail-oi1-x229.google.com (mail-oi1-x229.google.com [IPv6:2607:f8b0:4864:20::229]) by smtp3.osuosl.org (Postfix) with ESMTPS id A3C00605A1 for ; Sun, 27 Nov 2022 13:08:10 +0000 (UTC) Received: by mail-oi1-x229.google.com with SMTP id e205so8997937oif.11 for ; Sun, 27 Nov 2022 05:08:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=cikp0EEulpzCFR0AlDmg2kXgITR4MKVNwwpswSFcFm0=; b=eYQgpZPwsWsyG97ILuv2/goJtDNRzHsyW8k+98My0PgSzrHVWtJ/XBO+XGU8RqdKPc NG1n8ma0n8j6ICOQ6a45skgWYe8+Uemyzo7kQ6tdt3k6UDgpR0iISLmAjxqf3O6kgazc N53wti390OxRNAQoTj1P4D5ZRI8bF7hj6pj0tKNR5VaSiJtL1mmr2N7dEJ1aqAmKBBss NHINiooC9nDVNa0wA2kijPjclioRhnCwMpKG9C2GbpKf79Lza8K517LBTIGyLvgX1UBG j/gmqn3mhAF8JSq8R3NkK+wN4fe4E5fmIuHXOxuWqXpuDzRg8acD2k89phwmBeWCEtOB fc+w== X-Gm-Message-State: ANoB5pl/xqt+UT84LYO+ddLBcSk2AokdZgBuoXlBteFawtNHaTfDsD0t Io0IsmixymjyML/RGJj4mkwtmp+AL5o= X-Google-Smtp-Source: AA0mqf7l/K+6wEoC5TWoceLB+s4J3UoRg/KyTU88tWpjLQV24N76umo0bkJE+RzO63xlGXNfF3U3GQ== X-Received: by 2002:aca:1306:0:b0:35b:88aa:be80 with SMTP id e6-20020aca1306000000b0035b88aabe80mr6913936oii.41.1669554489543; Sun, 27 Nov 2022 05:08:09 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:08 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:19 -0300 Message-Id: <20221127130739.1862398-6-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=cikp0EEulpzCFR0AlDmg2kXgITR4MKVNwwpswSFcFm0=; b=iho3/hYYeN9BR5B+g/GIFiGDnWDL+y8SjMFq+J7lOSwfGswpkxWl/65nX/X64EcywU foTfYmHzTGNftGlrbwpI+YUBY0Z2I0Q9dwElQ8YlXyRv805WR6p/nbUmc7BOkCa6oWzu iKeVzoQJrRYnJUVYCg/KBBLgoyuMCa2pIsaeiwp1GGoKvoMSMmBrbz82ytVP3g0koPdn Oazku4Th5fHeHb7M48dLD+coLSR6xfB/MZcH9pNOG+T0EixhbnvqfcBDGMwW+6nBWvWo iqAGZECtchJjUnwprQtyAvqCYMOHvManPKs4p9Trenib77cdgmBTd1dk/uia5fDXpkBi rR0g== X-Mailman-Original-Authentication-Results: smtp3.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=iho3/hYY Subject: [Buildroot] [next 05/25] support/scripts/generate-gitlab-ci-yml: improve test-pkg support X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Following the example of test-pkg config described in commit "12c7a05da1 utils/test-pkg: add gitlab-ci support" to test a defconfig fragment that contains a disabled option is currently possible, but it do requires one to change the git config core.commentChart so the lines starting with "#" are not discarded by git when creating/editing the commit message. For instance, without the indentation the 3rd line below would be excluded from the commit message when the editor is closed: test-pkg config: SOME_OPTION=y # OTHER_OPTION is not set SOME_VARIABLE="some value" Requiring to change git configs is not very nice. So make the developer's life easier by changing the sed expression to remove indentation with spaces from a defconfig fragment found on a commit message. For instance these lines become valid and generate a defconfig fragment without the indentation of one space to be tested in GitLab CI: test-pkg config: SOME_OPTION=y # OTHER_OPTION is not set SOME_VARIABLE="some value" Signed-off-by: Ricardo Martincoski --- Example usage: https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/704846763 --- support/scripts/generate-gitlab-ci-yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/support/scripts/generate-gitlab-ci-yml b/support/scripts/generate-gitlab-ci-yml index aa43aac019..27f586f1b6 100755 --- a/support/scripts/generate-gitlab-ci-yml +++ b/support/scripts/generate-gitlab-ci-yml @@ -91,7 +91,7 @@ gen_tests() { # Retrieve defconfig for test-pkg from the git commit message (if any) if grep -q -E '^test-pkg config:$' <<<"${CI_COMMIT_DESCRIPTION}"; then - sed -r -n -e '/^test-pkg config:$/{:a;n;p;ba;}' \ + sed -r -n -e '/^test-pkg config:$/{:a;n;s/^ +//;p;ba;}' \ <<<"${CI_COMMIT_DESCRIPTION}" \ >defconfig.frag if [ ! -s defconfig.frag ]; then From patchwork Sun Nov 27 13:07:20 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709333 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKppS22W9z23nB for ; Mon, 28 Nov 2022 00:09:20 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 69832410D0; Sun, 27 Nov 2022 13:09:18 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 69832410D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id oUB1XC6iHOPo; Sun, 27 Nov 2022 13:09:17 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id 5E879410C2; Sun, 27 Nov 2022 13:09:16 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 5E879410C2 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 73A091BF42C for ; Sun, 27 Nov 2022 13:08:14 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 4E9F181AAB for ; Sun, 27 Nov 2022 13:08:14 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 4E9F181AAB X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PYfN5i2aSv6B for ; Sun, 27 Nov 2022 13:08:13 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org A40CD81B23 Received: from mail-ot1-x335.google.com (mail-ot1-x335.google.com [IPv6:2607:f8b0:4864:20::335]) by smtp1.osuosl.org (Postfix) with ESMTPS id A40CD81B23 for ; Sun, 27 Nov 2022 13:08:13 +0000 (UTC) Received: by mail-ot1-x335.google.com with SMTP id t19-20020a9d7753000000b0066d77a3d474so5359123otl.10 for ; Sun, 27 Nov 2022 05:08:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yWzK7EU8yE8xymo8f/sTWxOVH9jxJl0h8b8Pml8F0hU=; b=Sej+5FBzsho43Eytn2O1KhP/49N/1h6hze0w3s/oTlHSXGaPqfMrlcunRlFETTa9uf 29Da7dff3+L7Bvd7PnzG24St0nejduIu2Me0zJGoKTWCa+xcTCi/eapdiNI/b6D1QVOW LJhKekVBp9HQpFNwq2CIyHnpBIV0k+Hw2Hhqe1rJ9vl2KEaNfR//nEzqnvQZIjO7djeH I0tsYuyRhbVQky9ucLUcXiLVHchq1ip0YvjC9Q3VhkAOZCLOEdGlnDwT1cPIliwVoSqL 4rBkwaWkUrTUKkBOTHhNzXKEQYd/8RSaC2ql9a01/vwoWFlkyhQoYk6bs+HS0x0locTm 81xA== X-Gm-Message-State: ANoB5pmgb3IRxn5mXVJb8V2laRcPa/uq3SkPb4hvlhf1fxjU4WyceEcb 91zJ2sVp31xUIXUu6jwv3MQ2RxTkA/o= X-Google-Smtp-Source: AA0mqf4a0uaduzSeyzdRCMifzyrsCuuUXSh8prK2OO+55ra+tETxmCMo5lRbqKPbKYR8hxRZq9BY4g== X-Received: by 2002:a9d:1281:0:b0:66c:da9e:e801 with SMTP id g1-20020a9d1281000000b0066cda9ee801mr13402721otg.333.1669554492678; Sun, 27 Nov 2022 05:08:12 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:11 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:20 -0300 Message-Id: <20221127130739.1862398-7-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=yWzK7EU8yE8xymo8f/sTWxOVH9jxJl0h8b8Pml8F0hU=; b=i1ESSzxyarEyS8wJ1Eyt0dEx9hzuPN9Zh5DarDJKiannLY8OJy7ytt/Gq6HW+zchHL 5jfjFEXi7PyMsaYSRW5m+ygFbGGuVbGKc4O+joUuv95eQnqJjsr91LJrr61GcrRnfpvO nisoei61q7lpkmB7x9ddEAzpFjIwFe4FbXHYCn3c+uwK9RzHXuZWgMZwwnMQ8IBIQ3c4 kfq2Ot5P17VjhKV2SSgg7zkBEt74DhfUanp5NyrLOCOF0JlzlwumZXq5ZlJa/SmYPR1m W3/R8Db/G7Huw804GadZiGTY0uZSCctoVyie87eUxq3CMtoNlT4yBoPqhsnszcl8wHf9 M+lA== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=i1ESSzxy Subject: [Buildroot] [next 06/25] package/fwts: use ifeq instead of ifdef X-BeenThere: buildroot@buildroot.org 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: Thomas Petazzoni , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The conditional code using ifdef was added in 2018 and works as expected. But there is no reason to use ifdef instead of ifeq. For consistence, switch to use ifeq like almost all packages already do. Cc: Arnout Vandecappelle Cc: Erico Nunes Cc: Thomas Petazzoni Signed-off-by: Ricardo Martincoski --- package/fwts/fwts.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/fwts/fwts.mk b/package/fwts/fwts.mk index b208aa0c14..f04c7a848f 100644 --- a/package/fwts/fwts.mk +++ b/package/fwts/fwts.mk @@ -15,7 +15,7 @@ FWTS_DEPENDENCIES = host-bison host-flex host-pkgconf libglib2 libbsd \ $(if $(BR2_PACKAGE_BASH_COMPLETION),bash-completion) \ $(if $(BR2_PACKAGE_DTC),dtc) -ifdef BR2_PACKAGE_FWTS_EFI_RUNTIME_MODULE +ifeq ($(BR2_PACKAGE_FWTS_EFI_RUNTIME_MODULE),y) FWTS_MODULE_SUBDIRS = efi_runtime $(eval $(kernel-module)) endif From patchwork Sun Nov 27 13:07:21 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709334 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKppj1JG0z23nB for ; Mon, 28 Nov 2022 00:09:33 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 6D1156006A; Sun, 27 Nov 2022 13:09:31 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 6D1156006A X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9cIdGDh_Fam3; Sun, 27 Nov 2022 13:09:30 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id B03C36061B; Sun, 27 Nov 2022 13:09:29 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org B03C36061B X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 3A6A81BF42C for ; Sun, 27 Nov 2022 13:08:17 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 136A281AEA for ; Sun, 27 Nov 2022 13:08:17 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 136A281AEA X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id l5wYWIOghXfE for ; Sun, 27 Nov 2022 13:08:16 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 20CC881AAB Received: from mail-ot1-x336.google.com (mail-ot1-x336.google.com [IPv6:2607:f8b0:4864:20::336]) by smtp1.osuosl.org (Postfix) with ESMTPS id 20CC881AAB for ; Sun, 27 Nov 2022 13:08:16 +0000 (UTC) Received: by mail-ot1-x336.google.com with SMTP id a7-20020a056830008700b0066c82848060so5374872oto.4 for ; Sun, 27 Nov 2022 05:08:15 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1Af+kEOlABrxydTvP9IWQdAEKQCIvsgnvAkaNOyfxIk=; b=vjXFduZn0ZH7xLnOI+Ei4U7gZR5/JkmOij4BSWCFN/pN5VmEBibZVTFYHWKi46vX/I U2F4QeODes4z9nut2dsbun9iaa2bdjc3Iwsh8JCtRk3VzRTwOtHUvToqAloIZdkIh8gy TwzTxyYEgs1Q2qkg70SqjrhIQeItNQLyzJYKJzhGA6QlrMxisl6Uq+aRiyuF1qJ1Js3p PgkI+8AfwGXP7c2yewiobT8A089eIGXNbINDNR1wFXGb1ayy8VFnu0XbN/NFp/l6HuGQ 3mjRI2+5MWR1Nl0xXQLzZ0BstBjqx6F0QQlRw8KHhmJQDpX1Tfue7le3vUBC5MNu8UYN YCgw== X-Gm-Message-State: ANoB5pk/4wbmHhRFdPavp2ki/csA1pffhDOOTo9VQe7lGsY+ouY/+Eox 0lHp0yaIlNd/xNhTgu8l0jMFbLc+ERk= X-Google-Smtp-Source: AA0mqf4M8shsvouppHzhS8/+lUcOij/MM1ZzM3m3CSKOJyzj/b8UeKB6QjRGd/YP4owb8/63jOQxWg== X-Received: by 2002:a05:6830:d85:b0:66d:65a5:b0b3 with SMTP id bv5-20020a0568300d8500b0066d65a5b0b3mr14709391otb.170.1669554495259; Sun, 27 Nov 2022 05:08:15 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:14 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:21 -0300 Message-Id: <20221127130739.1862398-8-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=1Af+kEOlABrxydTvP9IWQdAEKQCIvsgnvAkaNOyfxIk=; b=eVxNCO1/6V12pE2KzKSbPBIGW4Lfuk336nD+eNjzOyuMmoUrq7jqUwBgOxLy4ZFKoQ pWXj/lqMZ751o/FeGBX0yu0fXkQgZioNPDiY6RlgQYQcqZnbb+zgKJqMFRbHovIXzKeM amoiW7qA5o1DNT/HVzOHkQcUteDXLJ3JY+lUMUjoQefKegNdqVzi0nrJJUR+KX6I+uwN Y8Pw0atlGcvpIFiJlAtzTd9bGRPHbhFL93jOINoHzdORa/q7Vliunts24c6HQMZee5yw i4l8GGxbEEzZFO75+C5YeAxXutELpOXX8WP+K81UVkXwxR0+qEBgkBjeutBjIJTnmpAw /AVg== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=eVxNCO1/ Subject: [Buildroot] [next 07/25] package/live555: fix build config with locale X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Using current conditional code, added in 2014: ifndef ($(BR2_ENABLE_LOCALE),y) LIVE555_CFLAGS += -DLOCALE_NOT_USED endif the define LOCALE_NOT_USED is always passed on CFLAGS, because there is no symbol with following names defined: "(y,y)" -> not defined when BR2_ENABLE_LOCALE=y "(,y)" -> not defined when BR2_ENABLE_LOCALE is not set So fix the typo, switching ifndef to ifneq. Signed-off-by: Ricardo Martincoski --- test-pkg config 1: BR2_PACKAGE_LIVE555=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/705379816 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config 2: BR2_PACKAGE_LIVE555=y BR2_PACKAGE_OPENSSL=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/705388345 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config 3: BR2_PACKAGE_LIVE555=y BR2_PACKAGE_OPENSSL=y BR2_STATIC_LIBS=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/705391470 44 builds, 22 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config 4: BR2_PACKAGE_LIVE555=y BR2_STATIC_LIBS=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/705392278 44 builds, 22 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed --- package/live555/live555.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/live555/live555.mk b/package/live555/live555.mk index effd4517cf..56ed705783 100644 --- a/package/live555/live555.mk +++ b/package/live555/live555.mk @@ -39,7 +39,7 @@ else LIVE555_CFLAGS += -DNO_OPENSSL endif -ifndef ($(BR2_ENABLE_LOCALE),y) +ifneq ($(BR2_ENABLE_LOCALE),y) LIVE555_CFLAGS += -DLOCALE_NOT_USED endif From patchwork Sun Nov 27 13:07:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709335 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKppy03P3z23nB for ; Mon, 28 Nov 2022 00:09:45 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 418A28144F; Sun, 27 Nov 2022 13:09:44 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 418A28144F X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id toiptnG2XsoA; Sun, 27 Nov 2022 13:09:43 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 337F281026; Sun, 27 Nov 2022 13:09:42 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 337F281026 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id B53481BF42C for ; Sun, 27 Nov 2022 13:08:20 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 9D684402B3 for ; Sun, 27 Nov 2022 13:08:20 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 9D684402B3 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id oWvU6NTpseL4 for ; Sun, 27 Nov 2022 13:08:19 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 8203A40275 Received: from mail-oa1-x34.google.com (mail-oa1-x34.google.com [IPv6:2001:4860:4864:20::34]) by smtp4.osuosl.org (Postfix) with ESMTPS id 8203A40275 for ; Sun, 27 Nov 2022 13:08:19 +0000 (UTC) Received: by mail-oa1-x34.google.com with SMTP id 586e51a60fabf-142612a5454so10200791fac.2 for ; Sun, 27 Nov 2022 05:08:19 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=m8iIxLp8HkA5AVcbXS7tkQO8JGxif7YGagEWxm0OmRM=; b=Pcc/vV1Y5znmVHuCddP8Zm64UCZF+g9xuttUUWnhk62S3sWfoxCGTC4FqTTiKFrgkO seWmTMF1n1vcA776kewMweOTaJytabtPnLLt/65qAsou3cVJaVvraxkA45Uj5Xt0gHnI ByHhhiqZmwJLRdjdS9gJ2zSt3KuiyIA/j2AQX2M+i65nP5cgtogxuOLaJpfd7kexFjQV XDbJ41m3DXTCP/lcV+VpWY/VNNTLKKq7HfA4NsNGy0kgnuD8pnC+yguVxnaoIoyEbixD +I3a3JnVikHDp0uC7rWoS/I2PwuWFlGm/rAZXGtR+k9aOU6ilLfN+Y2uYhlc/fA/C4fq zAgg== X-Gm-Message-State: ANoB5pmFCkynPxy5S9xeft5nsYcfMCheKon5yE5gSmoZLKXYIGqd5fTS IPlzWHEflhNKvoclbjKGVXP3ANDp48w= X-Google-Smtp-Source: AA0mqf5iCloWEP0yBfi60uWf7OuXOKf3fuXupAIGfRuo/tbAHbxX504VAzxuL+QF6esyi+LicHttgw== X-Received: by 2002:a05:6870:e983:b0:141:f267:1bd0 with SMTP id r3-20020a056870e98300b00141f2671bd0mr25421605oao.144.1669554498584; Sun, 27 Nov 2022 05:08:18 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:17 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:22 -0300 Message-Id: <20221127130739.1862398-9-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=m8iIxLp8HkA5AVcbXS7tkQO8JGxif7YGagEWxm0OmRM=; b=BsGA2f540MgoZOifExk6/5nwWyY77uZQcR2qP+wTgPA8v2zHFZtngylqlHpQ5n3BRj zvtJP45Vmn+9HYR60n5Sr2esAb4XKYsqaTWAtp7Th/WgHeyPRsKKmFntTnHQN1d4R6v2 cnNUZ1ryiPOP9/cwpV7hDZQW94du7ITfayMXrZP/Idiutm02h/V3nWnFFQu7ghBtVpcy xbTUqWhDbNtXyKR1qoKcnvC478BNGAluwqsFRWUZAlxyuZR//QohtSCrLi5hneXr3r2l DyS1t4Ov8gi4P+kaLq4/0RF0FJSZOZWT3sVfSykT5I/OPKJLO6wzM6TkMXFSlS/TCG5O rlHA== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=BsGA2f54 Subject: [Buildroot] [next 08/25] package/pugixml: unconditionally set BUILD_DEFINES X-BeenThere: buildroot@buildroot.org 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: Theo Debrouwere , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The ifdef construct intended to avoid passing -DBUILD_DEFINES="" was never needed, because even upstream version v1.9 used in 2019 when the configuration options were added, can handle an empty string for BUILD_DEFINES. In fact an empty string is the default for v1.9 if it is not passed during configure. Also, the host variant already sets BUILD_DEFINES unconditionally. So remove the unneeded conditional. Cc: Arnout Vandecappelle Cc: Theo Debrouwere Signed-off-by: Ricardo Martincoski --- NOTE 1: For versions starting from v1.11 this flag BUILD_DEFINES is ignored, but it will be fixed in the next patch. I had split into 2 patches because this first one applies to old versions of the package too. Someone could theoretically decide to backport to a local copy of buildroot 2020.05.x for instance. NOTE 2: It doesn't test much, since BUILD_DEFINES is ignored, but anyway: https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/704554673 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config: BR2_PACKAGE_PUGIXML=y --- package/pugixml/pugixml.mk | 2 -- 1 file changed, 2 deletions(-) diff --git a/package/pugixml/pugixml.mk b/package/pugixml/pugixml.mk index 9137f04630..6c756e9c29 100644 --- a/package/pugixml/pugixml.mk +++ b/package/pugixml/pugixml.mk @@ -29,9 +29,7 @@ ifeq ($(BR2_PACKAGE_PUGIXML_HEADER_ONLY),y) PUGIXML_BUILD_DEFINES += PUGIXML_HEADER_ONLY endif -ifdef PUGIXML_BUILD_DEFINES PUGIXML_CONF_OPTS += -DBUILD_DEFINES="$(subst $(space),;,$(PUGIXML_BUILD_DEFINES))" -endif HOST_PUGIXML_CONF_OPTS += \ -DBUILD_PKGCONFIG=ON \ From patchwork Sun Nov 27 13:07:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709336 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [IPv6:2605:bc80:3010::136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpqB2p3hz23nB for ; Mon, 28 Nov 2022 00:09:58 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 918A06006A; Sun, 27 Nov 2022 13:09:56 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 918A06006A X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5uBHob2ykDyV; Sun, 27 Nov 2022 13:09:55 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id A3CEC6061B; Sun, 27 Nov 2022 13:09:54 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org A3CEC6061B X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 0FDF71BF42C for ; Sun, 27 Nov 2022 13:08:24 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id DDC64403CC for ; Sun, 27 Nov 2022 13:08:23 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org DDC64403CC X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FLeGLAqRaCD1 for ; Sun, 27 Nov 2022 13:08:22 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 8A1F640275 Received: from mail-oo1-xc2c.google.com (mail-oo1-xc2c.google.com [IPv6:2607:f8b0:4864:20::c2c]) by smtp4.osuosl.org (Postfix) with ESMTPS id 8A1F640275 for ; Sun, 27 Nov 2022 13:08:22 +0000 (UTC) Received: by mail-oo1-xc2c.google.com with SMTP id o140-20020a4a2c92000000b0049effb01130so1283227ooo.9 for ; Sun, 27 Nov 2022 05:08:22 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=iOEPUu99b6w71IR/et2TIUFQ6iXLw9RkT/6N8Js4jXw=; b=ZYsCjRZ3U2BfUqWgz/CvgH7x7dJkus1VuzaswGrI9O3k56BWJQulGYxlL2q3TwnyHq 9m97dstB+NhKYK6ImFWtFhJEchcViCS7YiWlIGJctcWewEr6/r606GH4oSBGUL8mqajO hgk5I9Gv8trAEdk8UPSF9pO/o9hf2qxA95Ay00Y6oyP9iZ/fPYKczpfsXuHmzPTxH9CV 6xDBufh/MEkeUIBwm3esRvSJrkJeKuNeG2akpndvM+zLPFUT5JmpaF9H6ZsKvvaR5g5U swd6CDbjdEArqxFawEXT0CvaTP+sMWZyodsT1i1rWcS2KbzmSerrbKT5jMIB1S/gaEQu J+Bg== X-Gm-Message-State: ANoB5plPO8eIY/GzJL0aGV/R4Wjho0wuK8Gla/RHQNAr3xg/05QEhdkb XfRN8LVyg3SBVzjhQPiigb9fs8UhJYw= X-Google-Smtp-Source: AA0mqf4M3LLqF7SxywBxtQBb+KG6h5jWOqeX1zX79YbTmRzcxV5IUM0cCL5fkqJcdYUWJpWbJJZkqw== X-Received: by 2002:a4a:dcd2:0:b0:49f:b5fe:2b43 with SMTP id h18-20020a4adcd2000000b0049fb5fe2b43mr19602874oou.49.1669554501628; Sun, 27 Nov 2022 05:08:21 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:20 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:23 -0300 Message-Id: <20221127130739.1862398-10-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=iOEPUu99b6w71IR/et2TIUFQ6iXLw9RkT/6N8Js4jXw=; b=GZhSroWuKMVbGQjjLyq9DXlZxePRbNEKh1vi0jP3ifqVfyuJB9+LDb8/5NkF1v8WV8 6KuK/lLK93IYqALoblUelbNsKgq68SYSy1SKTbUkmqgOURzx79Fi7QzNvSQ0CgHLg0// iJZ90jCJt+CkNQ5+0QRmqWzLo866pbCFdIjIlQz98mMGF5MEAJUglumjNvGj3FXjnwZR rj4SYye0QB0czCG6u5vmm/4nAghmFPoN5JxOau9Z9hmSUmgQ8gr9i4nnppLUJ6GzyGjP JuiXxy3wDUgiunQ8HRW3RN63nDXXC4PlfeuG8t64DCvWQ5Qlcfic7+5MVWfQbnjupwyD xenw== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=GZhSroWu Subject: [Buildroot] [next 09/25] package/pugixml: fix configuration options X-BeenThere: buildroot@buildroot.org 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: Theo Debrouwere , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit upstream 1c5a0bb32583fd294022e68e66b541bf6ff71a67 ":sparkles: Update CMake to modern approach" removed all feature toogles, so starting from release v1.11 any flag passed in BUILD_DEFINES was completely ignored during the build. Version 1.11.4 was in use in buildroot since February 2021. Commit upstream 0f1e75a902ef1751dd63a67fe223b5e8daf4c7f1 "Re-introduced the custom build defines" added PUGIXML_BUILD_DEFINES to release v1.12, but BUILD_DEFINES is still completely ignored during the build. Version 1.12.1 is in use in buildroot since March 2022. So switch the config options to use PUGIXML_BUILD_DEFINES instead of BUILD_DEFINES. Cc: Arnout Vandecappelle Cc: Theo Debrouwere Signed-off-by: Ricardo Martincoski --- NOTE 1: The code below can be useful to verify the statements above, after commenting some lines: |PUGIXML_VERSION = 1.11.4 |PUGIXML_VERSION = 1.10 |PUGIXML_VERSION = 1.9 |define PUGIXML_FORCE_BUILD_ERROR | echo '#ifdef PUGIXML_COMPACT' >> $(@D)/src/pugixml.cpp | echo '#error 111' >> $(@D)/src/pugixml.cpp | echo '#else' >> $(@D)/src/pugixml.cpp | echo '#error 222' >> $(@D)/src/pugixml.cpp | echo '#endif' >> $(@D)/src/pugixml.cpp |endef |PUGIXML_POST_PATCH_HOOKS += PUGIXML_FORCE_BUILD_ERROR |PUGIXML_BUILD_DEFINES += PUGIXML_COMPACT |PUGIXML_CONF_OPTS += -DBUILD_DEFINES="$(subst $(space),;,$(PUGIXML_BUILD_DEFINES))" |PUGIXML_CONF_OPTS += -DPUGIXML_BUILD_DEFINES="$(subst $(space),;,$(PUGIXML_BUILD_DEFINES))" |PUGIXML_CONF_OPTS += -DPUGIXML_COMPACT=ON NOTE 2: Current version for each branch: $ git grep ^PUGIXML_VERSION \ origin/next origin/master $(git branch -a | grep origin/202) \ | sed -e 's,^remotes/,,g' -e 's,^origin/,,g' | sort 2020.02.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2020.05.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.10 2020.08.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.10 2020.11.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2021.02.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2021.05.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2021.08.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2021.11.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2022.02.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.11.4 2022.05.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.12.1 2022.08.x:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.12.1 master:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.12.1 next:package/pugixml/pugixml.mk:PUGIXML_VERSION = 1.12.1 NOTE 3: local build tests to check size: pugixml-compact/graphs/package-size-stats.csv:pugixml,165216,1.9q pugixml-default/graphs/package-size-stats.csv:pugixml,152928,1.8q pugixml-header-only/graphs/package-size-stats.csv:pugixml,13660,0.2 pugixml-noxpath/graphs/package-size-stats.csv:pugixml,95532,1.1 pugixml-compact/defconfig:BR2_x86_i686=y pugixml-compact/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-compact/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-compact/defconfig:BR2_PACKAGE_PUGIXML_COMPACT=y pugixml-default/defconfig:BR2_x86_i686=y pugixml-default/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-default/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-header-only/defconfig:BR2_x86_i686=y pugixml-header-only/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-header-only/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-header-only/defconfig:BR2_PACKAGE_PUGIXML_HEADER_ONLY=y pugixml-noxpath/defconfig:BR2_x86_i686=y pugixml-noxpath/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-noxpath/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-noxpath/defconfig:# BR2_PACKAGE_PUGIXML_XPATH_SUPPORT is not set NOTE 4: build tests on GitLab CI test-pkg config 1: BR2_PACKAGE_PUGIXML=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/704564417 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config 2: BR2_PACKAGE_PUGIXML=y BR2_PACKAGE_PUGIXML_COMPACT=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/704755515 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config 3: BR2_PACKAGE_PUGIXML=y # BR2_PACKAGE_PUGIXML_XPATH_SUPPORT is not set https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/704849811 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed test-pkg config 4: BR2_PACKAGE_PUGIXML=y BR2_PACKAGE_PUGIXML_HEADER_ONLY=y https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/704851087 44 builds, 1 skipped, 0 build failed, 0 legal-info failed, 0 show-info failed --- package/pugixml/pugixml.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package/pugixml/pugixml.mk b/package/pugixml/pugixml.mk index 6c756e9c29..c54148d98f 100644 --- a/package/pugixml/pugixml.mk +++ b/package/pugixml/pugixml.mk @@ -29,11 +29,11 @@ ifeq ($(BR2_PACKAGE_PUGIXML_HEADER_ONLY),y) PUGIXML_BUILD_DEFINES += PUGIXML_HEADER_ONLY endif -PUGIXML_CONF_OPTS += -DBUILD_DEFINES="$(subst $(space),;,$(PUGIXML_BUILD_DEFINES))" +PUGIXML_CONF_OPTS += -DPUGIXML_BUILD_DEFINES="$(subst $(space),;,$(PUGIXML_BUILD_DEFINES))" HOST_PUGIXML_CONF_OPTS += \ -DBUILD_PKGCONFIG=ON \ - -DBUILD_DEFINES="$(subst $(space),;,$(HOST_PUGIXML_BUILD_DEFINES))" + -DPUGIXML_BUILD_DEFINES="$(subst $(space),;,$(HOST_PUGIXML_BUILD_DEFINES))" $(eval $(cmake-package)) $(eval $(host-cmake-package)) From patchwork Sun Nov 27 13:07:24 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709337 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpqT2GgXz23nJ for ; Mon, 28 Nov 2022 00:10:12 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id E68A6812E2; Sun, 27 Nov 2022 13:10:10 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org E68A6812E2 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Cd_1HpNNG6fi; Sun, 27 Nov 2022 13:10:08 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 12C948144F; Sun, 27 Nov 2022 13:10:07 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 12C948144F X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 7200B1BF42C for ; Sun, 27 Nov 2022 13:08:26 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 4E190400D0 for ; Sun, 27 Nov 2022 13:08:26 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 4E190400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ABFzcfJGxSSN for ; Sun, 27 Nov 2022 13:08:25 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 78D0B400B8 Received: from mail-oi1-x22d.google.com (mail-oi1-x22d.google.com [IPv6:2607:f8b0:4864:20::22d]) by smtp2.osuosl.org (Postfix) with ESMTPS id 78D0B400B8 for ; Sun, 27 Nov 2022 13:08:25 +0000 (UTC) Received: by mail-oi1-x22d.google.com with SMTP id h132so9033968oif.2 for ; Sun, 27 Nov 2022 05:08:25 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=A8yll0irFcKidjDx9shXry21SMl8cILBTTNyIp9otbg=; b=LjcZ+LAzoXzI06PdPpkB7T5hvbOclMnMQZHlu20v4eKmXtxYsphCWdpgEJjGOZyrb4 4KmUd1heAlchTRmFcmr8Hl0BHZVCiJLIkcmsqgGIyISgEDOitEqxKU+5vfNT3/Tu3j5l Yc/NO+lFYrM5fzK1qcLLWJ+LQXn8aoCQo539IrTxwvOA8GKGgO5CxU4NM6bA0seM+B/6 t9ubnLHo+ryG7wn2QiC8GiGWdUcR9ijm7je7rn06VvnphOnHi2oKfGT07N+294lv8ZlB tnMMns0G9OSzQPtZBWWC9zvan2x7mQe3U7NU7bS/ZT0hpPaIii8BMxgx7r2s+WsrzD7y Nq/Q== X-Gm-Message-State: ANoB5pmMQVOG6l1jgdytlbY1ZiGYwBbZU8d6KmaQqcLKz4St6s4ySx3h olr1DEa+c0bF3QUC5QXGW4aX3n2G0ms= X-Google-Smtp-Source: AA0mqf6RYPxS4uoTDI+Qmim3LDxVVIKEQZYq0dGSh8Iyyt7aip/v3SH9hnd+phhJymdbGV/3M7tXoQ== X-Received: by 2002:aca:180c:0:b0:35a:13a4:c1e3 with SMTP id h12-20020aca180c000000b0035a13a4c1e3mr13598954oih.200.1669554504476; Sun, 27 Nov 2022 05:08:24 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:23 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:24 -0300 Message-Id: <20221127130739.1862398-11-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=A8yll0irFcKidjDx9shXry21SMl8cILBTTNyIp9otbg=; b=BiG+qW/EV1nbnyUbV3C+iH2MaaPBr1ii7kB/JJTLVmoT/5XG96Dk+TzFv2qvT4qXMB Rv50M+TGSxkJJnwR7rCq67zs+zoBI+ovMweDgXbzAIYB0B7J/V+Qmo1laitvLn6eakkr BdRw6y6G3mni2GTgSRPR2R+hVn94EzYlhC1x497Txpw/zoeLmHAfQ1lajMSdBvn4ITqV 0SFLhDw5jVwlUyyOzNeY2lqammxxc9oy+9etM/AZy3zodeWOnErwWFB8WeaFDHRALxXV Wtw+1GIp56EgmRjvlGuyOAfoKOlInkaOT5OAkv3W2AYlGuK4qqhJdWUAdfwgUllfOojd r8Cw== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=BiG+qW/E Subject: [Buildroot] [next 10/25] package/pugixml: use explicit build options X-BeenThere: buildroot@buildroot.org 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: Theo Debrouwere , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit upstream 986b7ffd01aedcd4f2aa16e78e4cad9313b6d7b2 "Add Cmake options for pugiconfig.hpp" added feature toogles to release v1.12, including PUGIXML_NO_XPATH and PUGIXML_COMPACT. Commit upstream 5f49f2c6575cc2b7d343f8d41581fe92d69d7b52 "Mark advanced options and removed redundant ones" removed CMake specific support for PUGIXML_HEADER_ONLY and PUGIXML_HAS_LONG_LONG, but they can still be provided using PUGIXML_BUILD_DEFINES, starting from release v1.12. So use the explicit build options PUGIXML_NO_XPATH and PUGIXML_COMPACT, but keep using PUGIXML_BUILD_DEFINES to set PUGIXML_HEADER_ONLY and PUGIXML_HAS_LONG_LONG. Cc: Arnout Vandecappelle Cc: Theo Debrouwere Signed-off-by: Ricardo Martincoski --- local build tests to check size: pugixml-compact/graphs/package-size-stats.csv:pugixml,165216,1.9q pugixml-default/graphs/package-size-stats.csv:pugixml,152928,1.8q pugixml-header-only/graphs/package-size-stats.csv:pugixml,13660,0.2 pugixml-noxpath/graphs/package-size-stats.csv:pugixml,95532,1.1 pugixml-compact/defconfig:BR2_x86_i686=y pugixml-compact/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-compact/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-compact/defconfig:BR2_PACKAGE_PUGIXML_COMPACT=y pugixml-default/defconfig:BR2_x86_i686=y pugixml-default/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-default/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-header-only/defconfig:BR2_x86_i686=y pugixml-header-only/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-header-only/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-header-only/defconfig:BR2_PACKAGE_PUGIXML_HEADER_ONLY=y pugixml-noxpath/defconfig:BR2_x86_i686=y pugixml-noxpath/defconfig:BR2_TOOLCHAIN_EXTERNAL=y pugixml-noxpath/defconfig:BR2_PACKAGE_PUGIXML=y pugixml-noxpath/defconfig:# BR2_PACKAGE_PUGIXML_XPATH_SUPPORT is not set --- package/pugixml/pugixml.mk | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/package/pugixml/pugixml.mk b/package/pugixml/pugixml.mk index c54148d98f..1cf81c45f3 100644 --- a/package/pugixml/pugixml.mk +++ b/package/pugixml/pugixml.mk @@ -12,6 +12,18 @@ PUGIXML_CPE_ID_VENDOR = pugixml_project PUGIXML_INSTALL_STAGING = YES +ifeq ($(BR2_PACKAGE_PUGIXML_XPATH_SUPPORT),y) +PUGIXML_CONF_OPTS += -DPUGIXML_NO_XPATH=OFF +else +PUGIXML_CONF_OPTS += -DPUGIXML_NO_XPATH=ON +endif + +ifeq ($(BR2_PACKAGE_PUGIXML_COMPACT),y) +PUGIXML_CONF_OPTS += -DPUGIXML_COMPACT=ON +else +PUGIXML_CONF_OPTS += -DPUGIXML_COMPACT=OFF +endif + # Pugixml will automatically enable 'long long' support on C++11 compilers, # which means gcc 4.8+. As gcc always supports the 'long long' type, # force-enable this option to support older gcc versions. See also: @@ -19,12 +31,6 @@ PUGIXML_INSTALL_STAGING = YES PUGIXML_BUILD_DEFINES += PUGIXML_HAS_LONG_LONG HOST_PUGIXML_BUILD_DEFINES += PUGIXML_HAS_LONG_LONG -ifeq ($(BR2_PACKAGE_PUGIXML_XPATH_SUPPORT),) -PUGIXML_BUILD_DEFINES += PUGIXML_NO_XPATH -endif -ifeq ($(BR2_PACKAGE_PUGIXML_COMPACT),y) -PUGIXML_BUILD_DEFINES += PUGIXML_COMPACT -endif ifeq ($(BR2_PACKAGE_PUGIXML_HEADER_ONLY),y) PUGIXML_BUILD_DEFINES += PUGIXML_HEADER_ONLY endif From patchwork Sun Nov 27 13:07:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709338 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpqg4NGbz23mg for ; Mon, 28 Nov 2022 00:10:23 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id D598E6006A; Sun, 27 Nov 2022 13:10:21 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org D598E6006A X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id wK4jvnYj7bcY; Sun, 27 Nov 2022 13:10:20 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id 9B27D6061B; Sun, 27 Nov 2022 13:10:19 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 9B27D6061B X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id A97961BF42C for ; Sun, 27 Nov 2022 13:08:28 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 85242400D0 for ; Sun, 27 Nov 2022 13:08:28 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 85242400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MEc-OnvATJSZ for ; Sun, 27 Nov 2022 13:08:28 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org E9B7C400B8 Received: from mail-oa1-x34.google.com (mail-oa1-x34.google.com [IPv6:2001:4860:4864:20::34]) by smtp2.osuosl.org (Postfix) with ESMTPS id E9B7C400B8 for ; Sun, 27 Nov 2022 13:08:27 +0000 (UTC) Received: by mail-oa1-x34.google.com with SMTP id 586e51a60fabf-1433ef3b61fso10162348fac.10 for ; Sun, 27 Nov 2022 05:08:27 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8hdQZ8AMJUyglJxZYsLoNTfnTcD72v5AayjXVTScM8o=; b=3XVD6CWuDGDMi6ETHlHKWqDr1dZ7n4r0jTl/diJYGTgn95jw3zy2iOsZiRloKWrpOv t9hJuo/FlDKbOczy+O2fCemHQEKZX9lVA+CYhye20c39/Hwoa5KybBxie6lM4U9Wa/yg /w0fRMHZSgnigBG4dz/k3D2OipC10X9hXExt4SdLr3Gqbvm/onrk4BK6jMfsSeEtJy7Z 1Jxtw+fHuXezuHoksGp7/7wVSvfqi50VIHfNwUc/EiQOrMa2H8/CWoti8Z90+QGWhP8v f1RSSOPkUEFmkYNX4EuNLAt0ODZV5m0fBh9BRNwF6jLiqM+QUT3jTsWILsfZQgHnjtOp BqfA== X-Gm-Message-State: ANoB5plCGnJFFl53iP64SOwNga+gnhem8BxhyZ0syOPM4KJXKX4Kqyda 2JmgeF8o9PR4wUFJ/858UdMPp7EjgVY= X-Google-Smtp-Source: AA0mqf7NVNT3czRTLQo0yHIDruiqz815w+kU+Fj0yIGK0E+f07/PYxXSyCAK/BT6YPaUvSw5lMQi1Q== X-Received: by 2002:a05:6870:4e03:b0:143:2467:f004 with SMTP id pl3-20020a0568704e0300b001432467f004mr12953992oab.20.1669554507002; Sun, 27 Nov 2022 05:08:27 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:25 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:25 -0300 Message-Id: <20221127130739.1862398-12-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8hdQZ8AMJUyglJxZYsLoNTfnTcD72v5AayjXVTScM8o=; b=YztKnhkw5ws8wKFhCUubyvETX3e69BpDTN5/n3Z+6QTSgWfBqtWZyVpOGWttQb2AOa SFwBaRKx/rxtH9fUDNQYqkpBxpBzrNADsH9SUHnzPFMKI5qXgYImgeoRmJk21dGnbUrt OqeuVhi3TfEcvLz6CgduDUuXRZbUqVvY81JZJS4yvXXLPyyu/BQz/TONdZU6grE8cet9 MNFjeTKEPPQLSLlfN9KzS08VJ0aZT4k5aTKKaIjuFIeevBQ/+86Mma6RYpl5oiG94nN5 EeoZt1HnZyBUYvJ9vxu2Zniwvm/hnxwX2QkVTd2+TaN/9brS2bvpokifZrlw7E5nMAzE TjNw== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=YztKnhkw Subject: [Buildroot] [next 11/25] package/busybox: add comment about variable override X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The same comment already exists for UCLIBC_CONFIG_FILE. Both variables can be override from command-line, as described in the manual, at section 'Environment variables'. Signed-off-by: Ricardo Martincoski --- package/busybox/busybox.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package/busybox/busybox.mk b/package/busybox/busybox.mk index ef628e90e9..0f14bf999d 100644 --- a/package/busybox/busybox.mk +++ b/package/busybox/busybox.mk @@ -108,6 +108,8 @@ BUSYBOX_MAKE_OPTS = \ CONFIG_PREFIX="$(TARGET_DIR)" \ SKIP_STRIP=y +# specifying BUSYBOX_CONFIG_FILE on the command-line overrides the .config +# setting. ifndef BUSYBOX_CONFIG_FILE BUSYBOX_CONFIG_FILE = $(call qstrip,$(BR2_PACKAGE_BUSYBOX_CONFIG)) endif From patchwork Sun Nov 27 13:07:26 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709339 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpqy2yv1z23mg for ; Mon, 28 Nov 2022 00:10:38 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 511F04019B; Sun, 27 Nov 2022 13:10:36 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 511F04019B X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id jl-3BmN5xDzo; Sun, 27 Nov 2022 13:10:33 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id 06E41400D0; Sun, 27 Nov 2022 13:10:31 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 06E41400D0 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 62E611BF42C for ; Sun, 27 Nov 2022 13:08:32 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 3F02260B2E for ; Sun, 27 Nov 2022 13:08:32 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 3F02260B2E X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zXqhggEPETYf for ; Sun, 27 Nov 2022 13:08:31 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 49F9F60B23 Received: from mail-ot1-x32e.google.com (mail-ot1-x32e.google.com [IPv6:2607:f8b0:4864:20::32e]) by smtp3.osuosl.org (Postfix) with ESMTPS id 49F9F60B23 for ; Sun, 27 Nov 2022 13:08:31 +0000 (UTC) Received: by mail-ot1-x32e.google.com with SMTP id 94-20020a9d0067000000b0066c8d13a33dso5359864ota.12 for ; Sun, 27 Nov 2022 05:08:31 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/wOIY4GnwUhp8WEr1GSIiXWzjh1bvKr6ZT95sFLgOn8=; b=zsAriR9exJcDLQk7oOFfNfl+oM5VSqu+UyqwQiYA+/55ZEMxFiqBDFWmqD0YDbWO5L qRvIpJACWEjWP6IrDvqKTnsFhfQ3aPcFRoVmi2oG+PIuCe5TopWWFngSyrlYC2o0dPyY /IF86vXTozvTztV9m7GSLRNkKFtvzxtmsk7yJC+Jb9Ts4cTTz8j3L5VIpCAiEolUi0Zq GFq0PR4Og2Sj0UZ2XJJlKippCyz6InNhzT0Ivf+TfX4d+XQGG1DUxDzKDMhIVlEnT93h O7HxvfmPinqW2rB21bc/88JA6Qtt8MYQfQC9WcFOp4pk2WN+i2MUnrUclTdy+nyTmRcH mbhg== X-Gm-Message-State: ANoB5pmIrerTUfSSDJiGGw1Z8BP0mQlVoFHsnhVz1oNMEqtGphy/4jT4 /j6k1iT7AvN+LS7/F/r33+80hWCoVsg= X-Google-Smtp-Source: AA0mqf6DRLoeuGMXK62KeV99syepvjbQmsf275y9oNvgjHykeiuevSRjUCRWlthD7jb1IkbmnJmF2A== X-Received: by 2002:a05:6830:2002:b0:661:2aa:cf92 with SMTP id e2-20020a056830200200b0066102aacf92mr16218752otp.99.1669554510246; Sun, 27 Nov 2022 05:08:30 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:28 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:26 -0300 Message-Id: <20221127130739.1862398-13-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=/wOIY4GnwUhp8WEr1GSIiXWzjh1bvKr6ZT95sFLgOn8=; b=dedlpusPI7F1CVPrnZGmyt1eng0Q366hQT8AW4MVc56gc7EKsk9l2/ccnPrs7iqaYx 0q0nFSrc2QEjS90KM0Ni1KmepS/2GXZ5yz9WCyC1pL5y5LamDtw3WMj5g11IRGyycoKz 2c7n91u9bYbyvfp9SExLLJlDGO4Nlxw/PqkzfP0X4cNmzcaXqa83StRaPE31Kfz9RrmC /0MWpIkB6p6o+8zWqW6R2kZ7/M52+5LabHGQJr8jpt7oo5coc1BkXOoub8U9IjstfY4m vH6qfhK5trtJBK1uno9FBfMh2Gus/mRnQIsXYbmwOWp9cmtAsRt4aCfIh1yYRokDyBji UZuA== X-Mailman-Original-Authentication-Results: smtp3.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=dedlpusP Subject: [Buildroot] [next 12/25] utils/checkpackagelib: warn about ifdef on .mk X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" There are two legitimate cases to prefer ifdef over ifeq in package recipes: command-line overrides are allowed for busybox and uclibc configs. Except for that, all package in tree already use ifeq, so warn the developer adding/changing a package to use ifeq instead of ifdef, in order to keep consistence across packages. file.mk:2: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL file.mk:5: use ifneq ($(SYMBOL),y) instead of ifndef SYMBOL The difference between ifeq and ifdef is that ifdef doesn't expand recursively. Add comments to busybox and uclibc packages to avoid a warning in such special cases. Cc: Arnout Vandecappelle Signed-off-by: Ricardo Martincoski --- NOTE 1: I only state "all package in tree already use ifeq" because earlier in the series other 3 (2 ifdef and 1 ifndef) uses were removed. NOTE 2: We have both ifneq ($(BR2_ENABLE_LOCALE),y) and ifeq ($(BR2_ENABLE_LOCALE),) in the tree. I assume both do the same. So I choose one for the check-package warning message, for no particular reason. package/dialog/dialog.mk:ifneq ($(BR2_ENABLE_LOCALE),y) package/dosfstools/dosfstools.mk:ifneq ($(BR2_ENABLE_LOCALE),y) package/dvb-apps/dvb-apps.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/gettext-gnu/gettext-gnu.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/guile/guile.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/kodi-audioencoder-lame/kodi-audioencoder-lame.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/kodi/kodi.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/libcddb/libcddb.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/libcdio/libcdio.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/libglib2/libglib2.mk:ifneq ($(BR2_ENABLE_LOCALE),y) package/libpsl/libpsl.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/lsof/lsof.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/sdl_sound/sdl_sound.mk:ifneq ($(BR2_ENABLE_LOCALE),y) package/softether/softether.mk:ifeq ($(BR2_ENABLE_LOCALE),) package/uclibc-ng-test/uclibc-ng-test.mk:ifeq ($(BR2_ENABLE_LOCALE),) NOTE 3: Applying only this patch on current master, check-package returns: package/pugixml/pugixml.mk:32: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL package/live555/live555.mk:42: use ifneq ($(SYMBOL),y) instead of ifndef SYMBOL package/fwts/fwts.mk:18: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL --- package/busybox/busybox.mk | 1 + package/uclibc/uclibc.mk | 1 + utils/checkpackagelib/lib_mk.py | 18 +++++++++++ utils/checkpackagelib/test_lib_mk.py | 48 ++++++++++++++++++++++++++++ 4 files changed, 68 insertions(+) diff --git a/package/busybox/busybox.mk b/package/busybox/busybox.mk index 0f14bf999d..f8f9cb5616 100644 --- a/package/busybox/busybox.mk +++ b/package/busybox/busybox.mk @@ -110,6 +110,7 @@ BUSYBOX_MAKE_OPTS = \ # specifying BUSYBOX_CONFIG_FILE on the command-line overrides the .config # setting. +# check-package disable Ifdef ifndef BUSYBOX_CONFIG_FILE BUSYBOX_CONFIG_FILE = $(call qstrip,$(BR2_PACKAGE_BUSYBOX_CONFIG)) endif diff --git a/package/uclibc/uclibc.mk b/package/uclibc/uclibc.mk index 0ddf7dfa6d..125aa4cdcf 100644 --- a/package/uclibc/uclibc.mk +++ b/package/uclibc/uclibc.mk @@ -22,6 +22,7 @@ UCLIBC_DEPENDENCIES = host-gcc-initial linux-headers # specifying UCLIBC_CONFIG_FILE on the command-line overrides the .config # setting. +# check-package disable Ifdef ifndef UCLIBC_CONFIG_FILE UCLIBC_CONFIG_FILE = $(call qstrip,$(BR2_UCLIBC_CONFIG)) endif diff --git a/utils/checkpackagelib/lib_mk.py b/utils/checkpackagelib/lib_mk.py index b50a19ac62..8adf844e9a 100644 --- a/utils/checkpackagelib/lib_mk.py +++ b/utils/checkpackagelib/lib_mk.py @@ -21,6 +21,24 @@ continue_conditional = ["elif", "else"] end_conditional = ["endif"] +class Ifdef(_CheckFunction): + IFDEF = re.compile(r"^\s*(else\s+|)(ifdef|ifndef)\s") + + def check_line(self, lineno, text): + m = self.IFDEF.search(text) + if m is None: + return + word = m.group(2) + if word == 'ifdef': + return ["{}:{}: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL" + .format(self.filename, lineno), + text] + else: + return ["{}:{}: use ifneq ($(SYMBOL),y) instead of ifndef SYMBOL" + .format(self.filename, lineno), + text] + + class Indent(_CheckFunction): COMMENT = re.compile(r"^\s*#") CONDITIONAL = re.compile(r"^\s*({})\s".format("|".join(start_conditional + end_conditional + continue_conditional))) diff --git a/utils/checkpackagelib/test_lib_mk.py b/utils/checkpackagelib/test_lib_mk.py index 49fa216fcd..80a1736b4e 100644 --- a/utils/checkpackagelib/test_lib_mk.py +++ b/utils/checkpackagelib/test_lib_mk.py @@ -3,6 +3,54 @@ import checkpackagelib.test_util as util import checkpackagelib.lib_mk as m +Ifdef = [ + ('ignore commented line', + 'any', + '# ifdef\n', + []), + ('simple', + 'any', + '\n' + 'ifdef BR2_PACKAGE_FWTS_EFI_RUNTIME_MODULE\n' + 'endif\n', + [['any:2: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL', + 'ifdef BR2_PACKAGE_FWTS_EFI_RUNTIME_MODULE\n']]), + ('ignore indentation', + 'any', + ' ifdef FOO\n' + ' endif\n' + '\tifdef BAR\n' + 'endif\n', + [['any:1: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL', + ' ifdef FOO\n'], + ['any:3: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL', + '\tifdef BAR\n']]), + ('typo', + 'any', + '\n' + 'ifndef ($(BR2_ENABLE_LOCALE),y)\n' + 'endif\n', + [['any:2: use ifneq ($(SYMBOL),y) instead of ifndef SYMBOL', + 'ifndef ($(BR2_ENABLE_LOCALE),y)\n']]), + ('else ifdef', + 'any', + 'else ifdef SYMBOL # comment\n', + [['any:1: use ifeq ($(SYMBOL),y) instead of ifdef SYMBOL', + 'else ifdef SYMBOL # comment\n']]), + ('else ifndef', + 'any', + '\t else ifndef\t($(SYMBOL),y) # comment\n', + [['any:1: use ifneq ($(SYMBOL),y) instead of ifndef SYMBOL', + '\t else ifndef\t($(SYMBOL),y) # comment\n']]), + ] + + +@pytest.mark.parametrize('testname,filename,string,expected', Ifdef) +def test_Ifdef(testname, filename, string, expected): + warnings = util.check_file(m.Ifdef, filename, string) + assert warnings == expected + + Indent = [ ('ignore comment at beginning of line', 'any', From patchwork Sun Nov 27 13:07:27 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709340 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpr94cycz23mg for ; Mon, 28 Nov 2022 00:10:49 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id B4D274016B; Sun, 27 Nov 2022 13:10:46 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org B4D274016B X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RIFtl2LFVG4F; Sun, 27 Nov 2022 13:10:45 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id CC34840223; Sun, 27 Nov 2022 13:10:44 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org CC34840223 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 3B4781BF42C for ; Sun, 27 Nov 2022 13:08:36 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 165AB40890 for ; Sun, 27 Nov 2022 13:08:36 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 165AB40890 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id QV5INP7XxKvn for ; Sun, 27 Nov 2022 13:08:35 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 29FC94087E Received: from mail-ot1-x332.google.com (mail-ot1-x332.google.com [IPv6:2607:f8b0:4864:20::332]) by smtp4.osuosl.org (Postfix) with ESMTPS id 29FC94087E for ; Sun, 27 Nov 2022 13:08:35 +0000 (UTC) Received: by mail-ot1-x332.google.com with SMTP id p10-20020a9d76ca000000b0066d6c6bce58so5361787otl.7 for ; Sun, 27 Nov 2022 05:08:35 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=RsaJkD9zF+ft/7LfN43iIO2QTUVxbhJdTXJA+3gnVXE=; b=aqDpgzyV8QesqvzdzFteENxAA+cNwI+C/LsPih1OEHDuu1yUbzmZspP+FBj80o1Bbv YWhnwzIY9UQ38Nxp6wc0Hw9PjXCOzl2g2E/eCYwOPqbXFsHpTrD/cGBaQPQrf8w0hcJu 3S/q1zprgyCUvbxn/Lf93B2opnZN61oOd1WEoIdgGQXookkvnMdW6w20m6pDQGrvGdZB pld3LdVS/Ua9nvPDLzH+F/XXgrWVZCT5ZPwIVAFf4vVsNZhviaN6EmunXRL8SNzF4QpC EMW2yoDcevu17wKiCHmJlkC3+lT9vJgox+SutdDYxB4KJ6p4QDdW4LGE9DH2VuO26GDH 9TSw== X-Gm-Message-State: ANoB5pnt9lqpmAx1tjcNd02iSZzAFFixB5omda1siCuW+nHJrJJy+Lt1 5EKoPOHMcBo5BhuLbLwDnZvb6mXhm74= X-Google-Smtp-Source: AA0mqf68UNLQ2/IR5vrCNMgLq2C5qgPp57Q9C+27lIdf8p33ao7qJNBglJ/EECfq6q5vGJBf6DMMwQ== X-Received: by 2002:a9d:75c8:0:b0:66c:607e:4afa with SMTP id c8-20020a9d75c8000000b0066c607e4afamr14491804otl.50.1669554514246; Sun, 27 Nov 2022 05:08:34 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:33 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:27 -0300 Message-Id: <20221127130739.1862398-14-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=RsaJkD9zF+ft/7LfN43iIO2QTUVxbhJdTXJA+3gnVXE=; b=jCzFi1pqiQAgfjLSGqg5QK0LT5F0YeywN0Nf9EtoTA51xSpnF2p1vuH2hbuFni0WeK acXGJ7eaW43FQIHeCcsvkIqFOFUWvmvAXh5MN8Vgr0q7MQM+Prmjimq6h402eX/2hUiV 8umLCQ4u0k/CM6sb8p1dAxCtvAgaEO8jFH7GRspRt3fMGlu+tFVcH+VL2+Nq2hADgV/t GiK1P4bMJ5B74/ZQI+pieIwqz5dDDN05NvQmqzh4B8QDDqUEPpDPJmMvMb9ixdaZFOYD bU6ALAC7DRhFxY25ZPAZDLgtvU9bdov6tFB9eUE22khOrGo1ualOeH+rWWOSkbU8vYOY PpXA== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=jCzFi1pq Subject: [Buildroot] [next 13/25] toolchain/toolchain-buildroot: add comment about using virtual package infra X-BeenThere: buildroot@buildroot.org 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: "Yann E . MORIN" , Ricardo Martincoski , Thomas Petazzoni , Giulio Benetti , Romain Naour , Thomas De Schampheleire Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "9a8ec9195c toolchain/toolchain-buildroot: migrate to virtual package infrastructure" made the packages toolchain and toolchain-buildroot to use the virtual package infra even they being generic packages. This works because on package/pkg-virtual.mk when a package do not define neither _PROVIDES_ or _HAS_ symbols, only _IS_VIRTUAL is set to YES and _VERSION and _SOURCE are set to empty before relaying the call to inner-generic-package. Add a comment explaining why the virtual package infra is used in these cases. Cc: Giulio Benetti Cc: Romain Naour Cc: Thomas De Schampheleire Cc: Thomas Petazzoni Cc: Yann E. MORIN Signed-off-by: Ricardo Martincoski --- toolchain/toolchain-buildroot/toolchain-buildroot.mk | 3 +++ toolchain/toolchain/toolchain.mk | 3 +++ 2 files changed, 6 insertions(+) diff --git a/toolchain/toolchain-buildroot/toolchain-buildroot.mk b/toolchain/toolchain-buildroot/toolchain-buildroot.mk index b30cc332d2..6da64b7c77 100644 --- a/toolchain/toolchain-buildroot/toolchain-buildroot.mk +++ b/toolchain/toolchain-buildroot/toolchain-buildroot.mk @@ -14,4 +14,7 @@ TOOLCHAIN_BUILDROOT_DEPENDENCIES = host-gcc-final TOOLCHAIN_BUILDROOT_ADD_TOOLCHAIN_DEPENDENCY = NO +# Not really a virtual package, but we use the virtual package infra here so +# both the build log and build directory look nicer (toolchain-buildroot-virtual +# instead of toolchain-buildroot-undefined) $(eval $(virtual-package)) diff --git a/toolchain/toolchain/toolchain.mk b/toolchain/toolchain/toolchain.mk index 18f1dbea1a..ac60a7b248 100644 --- a/toolchain/toolchain/toolchain.mk +++ b/toolchain/toolchain/toolchain.mk @@ -47,4 +47,7 @@ endef TOOLCHAIN_POST_INSTALL_TARGET_HOOKS += TOOLCHAIN_GLIBC_COPY_NSSWITCH_FILE endif +# Not really a virtual package, but we use the virtual package infra here so +# both the build log and build directory look nicer (toolchain-virtual instead +# of toolchain-undefined) $(eval $(virtual-package)) From patchwork Sun Nov 27 13:07:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709341 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKprQ1vlGz23mg for ; Mon, 28 Nov 2022 00:11:01 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id BB2E8410CA; Sun, 27 Nov 2022 13:10:59 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org BB2E8410CA X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9nEWorCUPIkm; Sun, 27 Nov 2022 13:10:58 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id C343E410C2; Sun, 27 Nov 2022 13:10:57 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org C343E410C2 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id ECF141BF42C for ; Sun, 27 Nov 2022 13:08:38 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id C8B9A8144F for ; Sun, 27 Nov 2022 13:08:38 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org C8B9A8144F X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Bx8hgh503IGQ for ; Sun, 27 Nov 2022 13:08:38 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 18C368141B Received: from mail-oa1-x2f.google.com (mail-oa1-x2f.google.com [IPv6:2001:4860:4864:20::2f]) by smtp1.osuosl.org (Postfix) with ESMTPS id 18C368141B for ; Sun, 27 Nov 2022 13:08:38 +0000 (UTC) Received: by mail-oa1-x2f.google.com with SMTP id 586e51a60fabf-142306beb9aso10156503fac.11 for ; Sun, 27 Nov 2022 05:08:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xkA86t1yd/thDMJiLjMxl3wLuh+GLNYukid4YTHMArk=; b=n3grfzVBqjzhxASdMjngFrZF7UxzQLI/xMD/rhQrLw/EkZD0HfcqeKxukfCanlSKqR NNyKtJwcEmNbd1usbVPTYxAiMtzmEHlQuS/en7fLDumSeFKcwKAfThK2RFWGEcZXnsF4 QNnt7QJjdP29Z/JjW82VgHjwS9Svlf/gf+GxQiSWq/js7Jro1gewAWWVl9wxyR+9CUAa 6AksrPeP2ky/R+oQ+g4F64FT1CGiWT1JGdBbzeU3GQsgAiollw80jaPC9/KKY/Yo517N EZBPyYQRteLfxFyQBFLUY319m4AZWBVfZvVR3yKL1AXRAlMDuY6vPv/QBdynDlIsGiip fDiA== X-Gm-Message-State: ANoB5pnBUB2V189UcVDwIjV6YCdEHlnPHhtyDy0E+sxfaxMdSCe4nHIb yjCy1ZDzzPA2V09jpkL/4sXCK5j0/GM= X-Google-Smtp-Source: AA0mqf7OWcdoTGk0vPa92mT5vRep4qq8N70ThKAmuNHUrkEtTilGhggRItdvXmziZN+6c9eVxGW8ww== X-Received: by 2002:a05:6870:45aa:b0:13b:67fd:ebac with SMTP id y42-20020a05687045aa00b0013b67fdebacmr14368134oao.41.1669554517185; Sun, 27 Nov 2022 05:08:37 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:36 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:28 -0300 Message-Id: <20221127130739.1862398-15-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=xkA86t1yd/thDMJiLjMxl3wLuh+GLNYukid4YTHMArk=; b=c1ILs7bkK/Eyyq+sry4FQUkGwqMMuVYTmt0fF+pEBx7pD2l+Dl+pRx8oJAAArXf0vn GQTus78PtszXlpMU4sPgR9Lo4nD5Hq57y8dH0b4AuIGLodP6JkCN7fS6tzVRhqoHcXEp 4xLObuPdQ4IQx5qmG+Va8H+upjdIr/A6sOW/owXNWzw014R6eQkt5CmkvfFaKZztv/9y X2g936d1i4qqTqOjj/j2Opx8YSagYzfRbWK7lXI7htg8GuTuaTLaUdFK4DAFsxldnarR fLkpzM9WBIy70YHM/kz73abO4AP1hoWmv0nZjN5RRRyAZCsJvUvcXKsb/aYZVI50pvse OKqA== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=c1ILs7bk Subject: [Buildroot] [next 14/25] boot/uboot: remove use of legacy xloader symbol X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "070b183d0c boot/xloader: remove package", from release 2018.11, removed the package, but the symbol is still referenced. Remove the reference to it. Signed-off-by: Ricardo Martincoski --- boot/uboot/Config.in | 1 - 1 file changed, 1 deletion(-) diff --git a/boot/uboot/Config.in b/boot/uboot/Config.in index a729280060..b37fd4c7be 100644 --- a/boot/uboot/Config.in +++ b/boot/uboot/Config.in @@ -442,7 +442,6 @@ endif config BR2_TARGET_UBOOT_SPL bool "Install U-Boot SPL binary image" - depends on !BR2_TARGET_XLOADER help Install the U-Boot SPL binary image to the images directory. From patchwork Sun Nov 27 13:07:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709342 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [IPv6:2605:bc80:3010::136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKprf62Hpz23mg for ; Mon, 28 Nov 2022 00:11:14 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id EF66060B23; Sun, 27 Nov 2022 13:11:12 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org EF66060B23 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZW0yJ2Xv8GVZ; Sun, 27 Nov 2022 13:11:12 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id 31CC3605A1; Sun, 27 Nov 2022 13:11:11 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 31CC3605A1 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id B58B81BF42C for ; Sun, 27 Nov 2022 13:08:41 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 9E46181457 for ; Sun, 27 Nov 2022 13:08:41 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 9E46181457 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IMz5WxeTE_X8 for ; Sun, 27 Nov 2022 13:08:41 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 0555081419 Received: from mail-oi1-x22e.google.com (mail-oi1-x22e.google.com [IPv6:2607:f8b0:4864:20::22e]) by smtp1.osuosl.org (Postfix) with ESMTPS id 0555081419 for ; Sun, 27 Nov 2022 13:08:40 +0000 (UTC) Received: by mail-oi1-x22e.google.com with SMTP id v82so9038647oib.4 for ; Sun, 27 Nov 2022 05:08:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=bL/9Nklc3fpm7dRbc97diMLMLOLpNH116Qk74nmp3bo=; b=y97FmCJ+NF6uHm7fMc7Sm05Vmp8Fg5c5or8UBbuCaWrRuBB/VZ/GKIr8LIJ/fli7dF hBXQ+WHaDHalnbOKnlLyKOGx3szuRNV2utT8op60r7h/njGaiWtw7oaisrhl5N7lr54y AQ8zZDT5h0HCfzRkNnN1FLE4XKcLDBzWiTJzmvA7vgTCmW6g5855bnNjYeySyAgSB0xZ 97TkL/BwC15WN2kLff/thsR0GoaTyOGn6xtHAN8ApDWzS0kodeBatNQqR2w2TfLj0mLA aVfls72MKPayRCap51crvDSXdGU0ilJSOWX5KQe7SCBK98pH/2ddl3GMQWZ43Ph6y/Ap 4rCw== X-Gm-Message-State: ANoB5pkiMYAlKIGvVeVFQaH3C0D7rh2vsd690iqUlUftT1v6dEZDcRKt sXWb/sqT1q881nZiPuzq2uC69X5UUuM= X-Google-Smtp-Source: AA0mqf71BNWLGTboL+7FAwJewQq58JGluGmh0QiS8BvBL6h75Hp1MouKJSfufMmDCaFgX5hps0MF6w== X-Received: by 2002:a05:6808:14d1:b0:35b:92a4:fcae with SMTP id f17-20020a05680814d100b0035b92a4fcaemr5057259oiw.102.1669554520137; Sun, 27 Nov 2022 05:08:40 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:38 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:29 -0300 Message-Id: <20221127130739.1862398-16-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=bL/9Nklc3fpm7dRbc97diMLMLOLpNH116Qk74nmp3bo=; b=FNDRzUWW+UjM+uwfZkQVWm+3qTGoSsjekXu7q364RHXa3NVo9d+/GrdaHHsoyWjFrK yJ1UT0qpSCwDJ4ri+1cK4Qzhby/MxDdQCbnRc4n2VERFQfRJ2Y5ohewCw35quK67xXy+ GmzC317f8s/rtHkDKCiP5wCoj/4aDsEup2Phqm1cgCtU7lysTnaLfK3vf8Sn2Yatns18 6+hKkPXk6IT1p+KiEf9I51TNL4mcv2lRBp9ku8Oy7SBbIKxpSsZsG7wAvW4u98r8xshk iijqZsbtltqOCIyok+qK3VozwwVwRlhVId7HPRxFVUBJXaaiYQFL72kAL5O9URGNJgZA c6XQ== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=FNDRzUWW Subject: [Buildroot] [next 15/25] system: remove use of legacy md5 option X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "bf3626002f system cfg: remove mkpasswd MD5 format option", from release 2019.02, moved the symbol to legacy handling, but the symbol is still referenced. Remove the reference to it. Signed-off-by: Ricardo Martincoski --- system/Config.in | 1 - 1 file changed, 1 deletion(-) diff --git a/system/Config.in b/system/Config.in index e6dcd25455..bf65b07a76 100644 --- a/system/Config.in +++ b/system/Config.in @@ -78,7 +78,6 @@ endchoice # Passwd encoding config BR2_TARGET_GENERIC_PASSWD_METHOD string - default "md5" if BR2_TARGET_GENERIC_PASSWD_MD5 default "sha-256" if BR2_TARGET_GENERIC_PASSWD_SHA256 default "sha-512" if BR2_TARGET_GENERIC_PASSWD_SHA512 From patchwork Sun Nov 27 13:07:30 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709343 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKprv33Lvz23mg for ; Mon, 28 Nov 2022 00:11:27 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 732B8401DD; Sun, 27 Nov 2022 13:11:25 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 732B8401DD X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2YQyYtic3Kx4; Sun, 27 Nov 2022 13:11:24 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id A9C734016B; Sun, 27 Nov 2022 13:11:23 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org A9C734016B X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id CE9021BF42C for ; Sun, 27 Nov 2022 13:08:44 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id B65F1410BD for ; Sun, 27 Nov 2022 13:08:44 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org B65F1410BD X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MO4Gdfqshr5a for ; Sun, 27 Nov 2022 13:08:44 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 0853B410A6 Received: from mail-oi1-x22f.google.com (mail-oi1-x22f.google.com [IPv6:2607:f8b0:4864:20::22f]) by smtp4.osuosl.org (Postfix) with ESMTPS id 0853B410A6 for ; Sun, 27 Nov 2022 13:08:43 +0000 (UTC) Received: by mail-oi1-x22f.google.com with SMTP id e205so8998711oif.11 for ; Sun, 27 Nov 2022 05:08:43 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=leQAAFxOHPIunhmv2ax1c1s54cGL8hlQkpatx32r9IM=; b=CiXjXkY866LVVKh+ul2Z0zlr6tqWX+/Z42/RoLT27g+wtg43bE8RWAsnhGucqWEgDA p2V9Ft0iU4MSuFJAPYII/ns6MO3vKMtaPTUwi9K0v66B87hKRsizznafvesZOY1QwQxv ieVp/0te1QQB2QcDDo2EDyAR1DC+txGGnqsMhGBdrz3lQwErlLk5mwPBflP41b9wgeAq qqoLlOZbwBpRJNrnZN4w25Iy8IXtU4lS/7D5wHx0ruKhyHPFAn7LJ3TWJMmm0ivZ6xmp Zy2M0nHDfNXVh8w3wOBJ9p3ePkSKSpLjpJnNZr6NblgejqwSjGT3sQmKk6+Ljm+F+7b5 gc2Q== X-Gm-Message-State: ANoB5pkIiVM8HzPO3Yi9k+JrqFA5T31gTL9ZcGEyDrc1GunHXQIHBEsT hv9/mGztVkXKrNY6i42Up5mdqqSMFD0= X-Google-Smtp-Source: AA0mqf40A/iVbQ+5UF4Sc7U9tUH8P7OTnUgaO5TFJ/AhM3V69w4zRVqJfWEjf/b10GNun1ZIIXaj1A== X-Received: by 2002:a05:6808:901:b0:354:5bb8:1291 with SMTP id w1-20020a056808090100b003545bb81291mr12369773oih.120.1669554523156; Sun, 27 Nov 2022 05:08:43 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:42 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:30 -0300 Message-Id: <20221127130739.1862398-17-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=leQAAFxOHPIunhmv2ax1c1s54cGL8hlQkpatx32r9IM=; b=UkU2ckRK70btZXIiK/HfBK1UQ1MXontLhwU9SRuszLYfK1Jo9ZvkdYGIPa2V1T5YFz DE2nCC1ktVLKEQ8RWHxiQ1ZCLhjXjiYrQRmd9jCoQiLZBEnUvb71FGkzahof+GCbJnbN 7Zlp9y8U31pIiDizWhHNrHNYR9eYeX04x3lt6bzQZbfwUAJY7G3+xgMJLM8arWzMKspm NtZDclkkBIU5Sa+BFyueao21Hu6lRAyqYHvNidy7ODtM4OLDVP65h1fK34KcJ1hMEqDK WQ19TxCVdASC+aji6YJE9IO80SIi1bdVqiNmK4Spx2dyEGvBNtds5WbCvp7d+163hqEW itSg== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=UkU2ckRK Subject: [Buildroot] [next 16/25] package/linux-headers: remove bogus symbol BR2_PACKAGE_HOST_LINUX_HEADERS X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The package host-linux-headers does not exist and there were never references to this symbol in the tree, do drop it. Signed-off-by: Ricardo Martincoski --- package/linux-headers/Config.in.host | 3 --- 1 file changed, 3 deletions(-) diff --git a/package/linux-headers/Config.in.host b/package/linux-headers/Config.in.host index 8679241a2c..b8318a3a67 100644 --- a/package/linux-headers/Config.in.host +++ b/package/linux-headers/Config.in.host @@ -1,8 +1,5 @@ comment "Kernel Header Options" -config BR2_PACKAGE_HOST_LINUX_HEADERS - bool - choice prompt "Kernel Headers" default BR2_KERNEL_HEADERS_AS_KERNEL if BR2_LINUX_KERNEL From patchwork Sun Nov 27 13:07:31 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709344 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpsK5NKRz23mg for ; Mon, 28 Nov 2022 00:11:49 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 0240940227; Sun, 27 Nov 2022 13:11:48 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 0240940227 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2JI6M-yDTwJk; Sun, 27 Nov 2022 13:11:47 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id 138E34017B; Sun, 27 Nov 2022 13:11:46 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 138E34017B X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id D72441BF42C for ; Sun, 27 Nov 2022 13:08:48 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id B28A5410BE for ; Sun, 27 Nov 2022 13:08:48 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org B28A5410BE X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ppRAq7v7ldvl for ; Sun, 27 Nov 2022 13:08:47 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org C2F61410BD Received: from mail-oa1-x32.google.com (mail-oa1-x32.google.com [IPv6:2001:4860:4864:20::32]) by smtp4.osuosl.org (Postfix) with ESMTPS id C2F61410BD for ; Sun, 27 Nov 2022 13:08:47 +0000 (UTC) Received: by mail-oa1-x32.google.com with SMTP id 586e51a60fabf-12c8312131fso10197864fac.4 for ; Sun, 27 Nov 2022 05:08:47 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=MNus9pujhGsZsPCW7P7qlvB6M/5DPtopZhhdkQ/xOOE=; b=aM8s90X6zlYvnZokZdXvTogLqU6Ir6/lIy6sHU7fpjdTdSkNd5e3BfWE0650ILv/2d 9ol78V8YKG1fIo/q2n1u+eR0zJxfLZTOATtP+210si3Z8VhS3jVggbZI/F2d0bQEZ+Ga pM4Iyy0BipVML7s9YAsyX2oACIoP9Gbcko3uK6zCZPfUQz7Zj6p1hBfWgPRVz3yPj3El vdAvDp5oHYsYha1B0qCefvJowzezON5lyzjBs2OqmCeNEVRGVFbEIeqmJaPAkK0wUgYr zJVgtuwts9P7vsDeie4ZoAfvwdyg1SdmuN4PAXBKdBK8ZBmHR/vslX2eFkDGN3xpgQtm kEFA== X-Gm-Message-State: ANoB5pnEnS0OaafrNd9Q2A2kWIo6Q6i+AMSDqG3RYO3YBXmSnYNMmjIr HVIvu55cN62pjtlkACRwauilfsONZCQ= X-Google-Smtp-Source: AA0mqf7fljkVDweMaeT8Zk587K2e2nRTQ8Gebxt3s9eME1bNJGmoWpRGnlbsVt+n5ING9cZa2AzYRA== X-Received: by 2002:a05:6870:f206:b0:142:efb7:23dd with SMTP id t6-20020a056870f20600b00142efb723ddmr15625645oao.188.1669554526791; Sun, 27 Nov 2022 05:08:46 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:45 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:31 -0300 Message-Id: <20221127130739.1862398-18-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=MNus9pujhGsZsPCW7P7qlvB6M/5DPtopZhhdkQ/xOOE=; b=OhEa5/qn1Q9Pnk5lpRzFV/avjeud3RAvpshmJ/TilyzQc2I9LmNl83+4qS4lh4r2ll kEaVumYSnHP9TIPXUswFw2GzNgFXbLQgu5A110uxTfnzOz1Pif3i1bV+Yc40RhoJ9pW5 mi72Yek6FtEEWGGBGnyztmrrKCvScwIXSZQdZ8JWpaCgwB8x7sUXGRMvzlRfREHzcWUx tqWKpf2FwDtRlJOGHAGpn+1NF7V75eeKctwdhoPPUGjwgsSstiyyqNxtSVQZ5pSaio9l 6SkBSRLLq6vYDdnvAzuR2YxYnjI/MJ81KJCMDcKS/hrlhetKEWwHwrxRTa60k+VIrT5+ IjiQ== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=OhEa5/qn Subject: [Buildroot] [next 17/25] package/gitlab-runner: ensure use of LIBCURL_OPENSSL X-BeenThere: buildroot@buildroot.org 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: Romain Naour , Marcin Niestroj , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Currently this minimal config is accepted while it shouldn't: BR2_x86_i686=y BR2_PACKAGE_BEARSSL=y BR2_PACKAGE_LIBCURL_BEARSSL=y BR2_PACKAGE_GITLAB_RUNNER=y BR2_PACKAGE_GITLAB_RUNNER selects BR2_PACKAGE_LIBCURL_OPENSSL. Kconfig does not enforce a select when the symbol selected is part of a choice. See similar explanation on [1] and [2]. Doing something similar to [3] and depending on the choice option instead of selecting it would create a Kconfig recursive dependency. Just dropping the ineffective select would keep the above defconfig snippet as an accepted one. Adding a comment to the menu, i.e.: comment "gitlab-runner must use BR2_PACKAGE_LIBCURL_OPENSSL" depends on BR2_PACKAGE_GITLAB_RUNNER depends on !BR2_PACKAGE_LIBCURL_OPENSSL could improve user experience but it also keeps the above defconfig snippet as an accepted one. So bail out the build when gitlab-runner is enabled and libcurl-openssl is not selected, similar to what is done in [4]. [1] "a44b1c1405 legacy: update the BR2_PREFER_STATIC_LIB option" [2] "b1d5aa1bc2 package/qwt: Fix selecting OpenGL support in qt4" [3] "9fc652a373 package/libmodsecurity: needs dynamic library with libcurl and mbedtls" [4] "fda53f0791 package/Makefile.in: add detection for the lack of C library" Cc: Marcin Niestroj Cc: Romain Naour Signed-off-by: Ricardo Martincoski --- package/gitlab-runner/Config.in | 1 - package/gitlab-runner/gitlab-runner.mk | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/package/gitlab-runner/Config.in b/package/gitlab-runner/Config.in index 89e3e87b5c..5b8a6cacbe 100644 --- a/package/gitlab-runner/Config.in +++ b/package/gitlab-runner/Config.in @@ -11,7 +11,6 @@ config BR2_PACKAGE_GITLAB_RUNNER select BR2_PACKAGE_GIT # runtime select BR2_PACKAGE_LIBCURL # runtime select BR2_PACKAGE_LIBCURL_CURL # runtime - select BR2_PACKAGE_LIBCURL_OPENSSL # runtime, for ca-certificates. select BR2_PACKAGE_OPENSSL # runtime select BR2_PACKAGE_OPENSSL_FORCE_LIBOPENSSL # runtime select BR2_PACKAGE_LIBOPENSSL_BIN # runtime diff --git a/package/gitlab-runner/gitlab-runner.mk b/package/gitlab-runner/gitlab-runner.mk index c7c2da2fe1..c997785d90 100644 --- a/package/gitlab-runner/gitlab-runner.mk +++ b/package/gitlab-runner/gitlab-runner.mk @@ -12,6 +12,10 @@ GITLAB_RUNNER_LICENSE_FILES = LICENSE GITLAB_RUNNER_LDFLAGS = \ -X gitlab.com/gitlab-org/gitlab-runner/common.VERSION=$(GITLAB_RUNNER_VERSION) +ifeq ($(BR2_PACKAGE_GITLAB_RUNNER):$(BR2_PACKAGE_LIBCURL_OPENSSL):$(BR_BUILDING),y::y) +$(error gitlab-runner must use BR2_PACKAGE_LIBCURL_OPENSSL for ca-certificates at runtime) +endif + # Don't run gitlab runner as root. define GITLAB_RUNNER_USERS gitlab-runner -1 gitlab-runner -1 * /var/run/dbus /bin/false - Gitlab Runner From patchwork Sun Nov 27 13:07:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709345 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpsb0Sytz23mg for ; Mon, 28 Nov 2022 00:12:03 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id DF00C81B35; Sun, 27 Nov 2022 13:12:00 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org DF00C81B35 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id IXWIzos-cdzx; Sun, 27 Nov 2022 13:12:00 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 0621A81B14; Sun, 27 Nov 2022 13:11:59 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 0621A81B14 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 5DC231BF42C for ; Sun, 27 Nov 2022 13:08:51 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 471C5400D0 for ; Sun, 27 Nov 2022 13:08:51 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 471C5400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id q6nw_AncLHOE for ; Sun, 27 Nov 2022 13:08:50 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 8E1EA400B8 Received: from mail-oi1-x22e.google.com (mail-oi1-x22e.google.com [IPv6:2607:f8b0:4864:20::22e]) by smtp2.osuosl.org (Postfix) with ESMTPS id 8E1EA400B8 for ; Sun, 27 Nov 2022 13:08:50 +0000 (UTC) Received: by mail-oi1-x22e.google.com with SMTP id n205so9046850oib.1 for ; Sun, 27 Nov 2022 05:08:50 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=n6oRyXAAeTUDvl9Suu1BQycOsqaseWCKk11ppfJd6Bo=; b=YWix/1M/3HW4Be+iU25d+QXMTEJZFWtQMDZjca+yLmWJ2mKuGCDyGMGfQRWFlBaVMg 35ORYT8YJlCLx3wWRRirxerKiFPhucGr8cYOK0zqCeyimBa0JfHYFqQl+yEvsKvE1Lrg +SOvv0xtrQooymWlpX3mLWQMFEN05HWumC3Yl7KZpyqWbWXYXpttUk8Cu2s7UdiQbJRY azEZHJT6rO9yQPXmPcsXrmwtcNkcFhF8PCY4+Lt488FZUoI13Jgd2Q+zoNUMjNAegHR2 DEucPoErSp8ZlV0oTRD27qjfVglR2ynCBxlpF+E9nDZv6SZrabBINyJEzEzbdDRo8XJC Lz2g== X-Gm-Message-State: ANoB5pnNc2Ftsb6c1+0TWf5qBi86CzB88zQnBcbQ3cFtVB17gAsBJzBW bfZ6zrTLj0ZRPm7fQyYuf9CPKXax38o= X-Google-Smtp-Source: AA0mqf5Ajpq5RBHeEwPuQg9x3ttBJcvEkLJlkx73KqDzp5aZx8Kkq+aeQWkaHAgBUS+pLej98Drgwg== X-Received: by 2002:a05:6808:8c9:b0:351:1a63:a74c with SMTP id k9-20020a05680808c900b003511a63a74cmr13649085oij.288.1669554529673; Sun, 27 Nov 2022 05:08:49 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:48 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:32 -0300 Message-Id: <20221127130739.1862398-19-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=n6oRyXAAeTUDvl9Suu1BQycOsqaseWCKk11ppfJd6Bo=; b=fRgVm4AoMSodbekoaYfK5fVojMysN2TgieG9Ynz/QvYdg1+jLShjtYm340ArGuBurG baTa1EGq/3WEYr5V6FDp3Bukf2LD+pDXpNKTtLX1eeVioSE+hcc/BHfp0G3QMdkaAJH6 7l2gNj3IzB+PiEPriDAkNjrGMdi/ZKVpuWmyirteVq2KzHsuYRjqMuzr8AJ+ayi0aL5E EogF679xW8AbMUQ3EBHjH64OAa3t4UzefuVb7AeTdpZZj4G3f7dniK627GSLvcsXIo40 sg95wFir8UtydukrA6e8+MSUWzTHNZbjH6XnQZu/f+jtm7jXNdCdl8BBNpQncIPeichE r6rg== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=fRgVm4Ao Subject: [Buildroot] [next 18/25] package/openpowerlink: properly handle legacy options X-BeenThere: buildroot@buildroot.org 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: Romain Naour , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "b1063a0136 package/openpowerlink: bump to v2.2.2" tried to add legacy handling but the new symbols are part of a choice, and Kconfig does not enforce the select of a option from a choice. Update the legacy entry for 2016.02, following the example described in the beginning of the file. Cc: Romain Naour Signed-off-by: Ricardo Martincoski --- test config 1: BR2_PACKAGE_OPENPOWERLINK_LIBPCAP=y BR2_PACKAGE_OPENPOWERLINK=y BR2_TOOLCHAIN_BUILDROOT_CXX=y test config 2: BR2_PACKAGE_OPENPOWERLINK_KERNEL_MODULE=y BR2_PACKAGE_OPENPOWERLINK=y BR2_TOOLCHAIN_BUILDROOT_CXX=y BR2_LINUX_KERNEL=y --- Config.in.legacy | 6 ++++-- package/openpowerlink/Config.in | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Config.in.legacy b/Config.in.legacy index 9ce1004b0c..e489458270 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -4313,19 +4313,21 @@ config BR2_PACKAGE_OPENPOWERLINK_DEBUG_LEVEL config BR2_PACKAGE_OPENPOWERLINK_KERNEL_MODULE bool "openpowerlink package has been updated" select BR2_LEGACY - select BR2_PACKAGE_OPENPOWERLINK_STACK_KERNEL_STACK_LIB help openpowerlink kernel modules are built if the kernel stack library is selected. +# Note: BR2_PACKAGE_OPENPOWERLINK_KERNEL_MODULE is still referenced from +# package/openpowerlink/Config.in config BR2_PACKAGE_OPENPOWERLINK_LIBPCAP bool "openpowerlink package has been updated" select BR2_LEGACY - select BR2_PACKAGE_OPENPOWERLINK_STACK_USERSPACE_DAEMON_LIB help The user space support has been split in two part: - a monolithic user space library - a user space daemon driver +# Note: BR2_PACKAGE_OPENPOWERLINK_LIBPCAP is still referenced from +# package/openpowerlink/Config.in config BR2_LINUX_KERNEL_SAME_AS_HEADERS bool "using the linux headers version for the kernel has been removed" diff --git a/package/openpowerlink/Config.in b/package/openpowerlink/Config.in index 1a3dd62acd..ef59a04baf 100644 --- a/package/openpowerlink/Config.in +++ b/package/openpowerlink/Config.in @@ -38,6 +38,8 @@ endchoice choice prompt "stack type" + default BR2_PACKAGE_OPENPOWERLINK_STACK_KERNEL_STACK_LIB if BR2_PACKAGE_OPENPOWERLINK_KERNEL_MODULE # legacy + default BR2_PACKAGE_OPENPOWERLINK_STACK_USERSPACE_DAEMON_LIB if BR2_PACKAGE_OPENPOWERLINK_LIBPCAP # legacy config BR2_PACKAGE_OPENPOWERLINK_STACK_MONOLITHIC_USER_STACK_LIB bool "linked into application" From patchwork Sun Nov 27 13:07:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709346 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpsq21zmz23mg for ; Mon, 28 Nov 2022 00:12:15 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 555E681098; Sun, 27 Nov 2022 13:12:13 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 555E681098 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DOqSp1wGyTW0; Sun, 27 Nov 2022 13:12:12 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 91E1281461; Sun, 27 Nov 2022 13:12:11 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 91E1281461 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 9E7DB1BF42C for ; Sun, 27 Nov 2022 13:08:55 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 8620B81424 for ; Sun, 27 Nov 2022 13:08:55 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 8620B81424 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 21pnsqzleESP for ; Sun, 27 Nov 2022 13:08:54 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 4D4ED80E46 Received: from mail-ot1-x32c.google.com (mail-ot1-x32c.google.com [IPv6:2607:f8b0:4864:20::32c]) by smtp1.osuosl.org (Postfix) with ESMTPS id 4D4ED80E46 for ; Sun, 27 Nov 2022 13:08:54 +0000 (UTC) Received: by mail-ot1-x32c.google.com with SMTP id a7-20020a056830008700b0066c82848060so5375397oto.4 for ; Sun, 27 Nov 2022 05:08:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gc6gD9sf93LsenKv8QngDKX5hyeT7PEgGHrjoHhVZLQ=; b=Ta54CpBWnk+FDzdi7rcRydP4kfiD/FeqorXDsHcBwSoTF550BO7ImO76xYLSu8IViz JZd/JRLX4ADcw9xsP2rjYbKQ+lZuU1H0UtEGt7v16fX7cUMQVF4TEk3WQxrEA+VW1HPy k93nVdUfgGaK9ALITzmXHDya7HbwpgzoZv9Szw0exH9cgkZTqm89ydNeFlR72Lmz2R2z sr1ldDPd55RtyAaPvIJyzyQXRqYp4CAevz1Bo1l9geuz0CT0WmwDh783hEbTHbgr7Lb/ 9Eqsq2P1Z0TCh5vyu4BlRrlP41Dsf3OoBbpLaHTyJ0BNFX0RdlBImXmGXXIrmCPpL3rI /xNg== X-Gm-Message-State: ANoB5pl3SqnWpUnAbil//hZJMLIfFBZDs7VBP4ccdRX1epaxwBTjEI4+ jeDZQg+xWvmIzYDMjlsxvsvrb9YEe9o= X-Google-Smtp-Source: AA0mqf5a5D9rukONuatlryh74Yxnx26Vrp99GDrbcrUzj0rB6EkkYt27ETQhhqbSaia5Y3Z9JWAz5A== X-Received: by 2002:a9d:4809:0:b0:66d:11ed:3d1a with SMTP id c9-20020a9d4809000000b0066d11ed3d1amr13405163otf.379.1669554533425; Sun, 27 Nov 2022 05:08:53 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:52 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:33 -0300 Message-Id: <20221127130739.1862398-20-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=gc6gD9sf93LsenKv8QngDKX5hyeT7PEgGHrjoHhVZLQ=; b=SMU5+sKytOQQEFjX/LSncEtrWX/4fm5HZb0rKOorBkpwfbUKH23r3oJg42RnQn4N/j JMJ299lB5dF2GNGVEF1Dyf+zrqzCe50CZIkpgKx8XPYH134Hxk1C4ADPhhnsR18x7Bt2 hcnCEiewaWAtQIrH/X6bSrLw2+vIiX4d70FYvpEEHA3tYqXQwZF1OS/8Oucj/zE9uPx+ izi7iJVNRinzZ5UHKX0Ze+P87CR4jpcuZdoBMIT7qG477G/dCY2xEsKL+Vd23H9gYNov ZP0pO6chVzRtGhBPAq481lus+pE8/JuOKmPXPteUj77asVyysE5hfTgpemoi9lZKevNb lQkg== X-Mailman-Original-Authentication-Results: smtp1.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=SMU5+sKy Subject: [Buildroot] [next 19/25] package/gcc: properly handle legacy for renamed ARC option X-BeenThere: buildroot@buildroot.org 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: Thomas Petazzoni , Giulio Benetti , Romain Naour , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "50332a530b gcc: rename option for ARC gcc" tried to add legacy handling but the new symbol is part of a choice, and Kconfig does not enforce the select of a option from a choice. Update the legacy entry for 2016.11, following the example described in the beginning of the file. Cc: Giulio Benetti Cc: Romain Naour Cc: Thomas Petazzoni Signed-off-by: Ricardo Martincoski --- test config 1: BR2_GCC_VERSION_4_8_ARC=y BR2_arcle=y NOTE that in order to test this other line must be commented out: default BR2_GCC_VERSION_ARC if BR2_GCC_VERSION_ARC --- Config.in.legacy | 3 ++- package/gcc/Config.in.host | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Config.in.legacy b/Config.in.legacy index e489458270..8861b0d704 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -3970,10 +3970,11 @@ config BR2_LINUX_KERNEL_TOOL_SELFTESTS config BR2_GCC_VERSION_4_8_ARC bool "gcc arc option renamed" select BR2_LEGACY - select BR2_GCC_VERSION_ARC help The option that selects the gcc version for the ARC architecture has been renamed to BR2_GCC_VERSION_ARC. +# Note: BR2_GCC_VERSION_4_8_ARC is still referenced from +# package/gcc/Config.in.host config BR2_KERNEL_HEADERS_4_0 bool "kernel headers version 4.0.x are no longer supported" diff --git a/package/gcc/Config.in.host b/package/gcc/Config.in.host index d7fedc9591..cd1b9fa46d 100644 --- a/package/gcc/Config.in.host +++ b/package/gcc/Config.in.host @@ -2,6 +2,7 @@ comment "GCC Options" choice prompt "GCC compiler Version" + default BR2_GCC_VERSION_ARC if BR2_GCC_VERSION_4_8_ARC # legacy default BR2_GCC_VERSION_ARC if BR2_arc default BR2_GCC_VERSION_POWERPC_SPE if BR2_powerpc_SPE default BR2_GCC_VERSION_11_X From patchwork Sun Nov 27 13:07:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709347 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpt40ZgMz23mg for ; Mon, 28 Nov 2022 00:12:28 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id 249EF80FB9; Sun, 27 Nov 2022 13:12:26 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 249EF80FB9 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id utgq4k6LKx38; Sun, 27 Nov 2022 13:12:25 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 4BEEF81B14; Sun, 27 Nov 2022 13:12:24 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 4BEEF81B14 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 695BF1BF42C for ; Sun, 27 Nov 2022 13:08:58 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 44EA4400D0 for ; Sun, 27 Nov 2022 13:08:58 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 44EA4400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dYbAjqVcH98W for ; Sun, 27 Nov 2022 13:08:57 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 9C2F4400B8 Received: from mail-oa1-x2e.google.com (mail-oa1-x2e.google.com [IPv6:2001:4860:4864:20::2e]) by smtp2.osuosl.org (Postfix) with ESMTPS id 9C2F4400B8 for ; Sun, 27 Nov 2022 13:08:57 +0000 (UTC) Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-14263779059so10208120fac.1 for ; Sun, 27 Nov 2022 05:08:57 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=RqxY/3vXH7cJNzBLHrjFzyzCu/nHMFNNHb5V4ieMEzk=; b=2Xa4drOOMGz2tfKvqij1YRkGBnHWtpEqwnwXhIQzCbB9gfKi3RhYRsStCslz+wPkKR j0PuM5mukiwhzk79Sr/q0RkJNsP//qdlh2hHRufUcPd5UpEak3Rgs5aFKuRQlF+/7poU B/JsIGIeXJD6vNObbtBM3PD1PBDhuMRajzSkb5mG9oEZB9/C+a30m75aryhLJnlnsQ/q Tg3C5qWaTB4FqQGELMaWs5L5Gcel7XDlvl8i+kSCkTP9iuuSH9I5fJu0g26tx8jUn8kU va4m1WuY/Pdg1nfc6REvHbOOFMuMWvlBKc3pwz/k4UEjw4CTryhw+SmqmfE1Y1CcjXIa OJyg== X-Gm-Message-State: ANoB5pkLMODN1/+yMu0ibPE5bRgTCp7Xdj+/i16YVDTK2lc/+8tLdsn5 hCpkvzLfFTWgnh2HvsRz7/I4RhqaMF8= X-Google-Smtp-Source: AA0mqf62fgh4IPgS4QUD9/hJUG//erabZpJSqTy1hW0slPv/PKVtYR+BzamI2JGNbRdL+w3HbV71ag== X-Received: by 2002:a05:6871:4607:b0:13b:9bf2:25a8 with SMTP id nf7-20020a056871460700b0013b9bf225a8mr14871203oab.102.1669554536733; Sun, 27 Nov 2022 05:08:56 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:55 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:34 -0300 Message-Id: <20221127130739.1862398-21-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=RqxY/3vXH7cJNzBLHrjFzyzCu/nHMFNNHb5V4ieMEzk=; b=PumtsciG96lOwH8zrCyBWT6ekmq032lDPMqQNry65I4V8w+BrVY38+pJGlPfGrI7wE XS6WWlbh6PKUE5dxliLSKfgr/SMKdoxSqoUnPjoWDVnr2LyHuAJI4E0w8fHV0Cke8Mkg cMCjKA+SvoKvwwM6P5jhipNEb0MWXDj1JhESQ2Ec05bXiLQkuMbl5BGFZVNK8eEcVoaA dwe8TW47xk2tg1WBI8zLcusO9lLQQE1+XZWOLM2BMjJFhrTDV/llwHYe3ZWDyPklnjLC bAC7PovW6Qn5fexpt1xx98FNsIHkk9vBisSAfa/0OXmA6bC66wE9tCw5egGHXnYA0k5w kX2Q== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=PumtsciG Subject: [Buildroot] [next 20/25] package/lua: properly handle legacy for removed version X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "297613f1c7 package/lua: remove 5.2.x version" tried to add legacy handling but the new symbols are part of a choice, and Kconfig does not enforce the select of a option from a choice. Update the legacy entry for 2019.02, following the example described in the beginning of the file. Cc: Francois Perrad Signed-off-by: Ricardo Martincoski --- test config 1: BR2_PACKAGE_LUA_5_2=y BR2_PACKAGE_LUA=y --- Config.in.legacy | 2 +- package/lua/Config.in | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Config.in.legacy b/Config.in.legacy index 8861b0d704..3131c31e68 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -2094,9 +2094,9 @@ config BR2_PACKAGE_FFTW_PRECISION_QUAD config BR2_PACKAGE_LUA_5_2 bool "Lua 5.2.x version removed" select BR2_LEGACY - select BR2_PACKAGE_LUA_5_3 help The Lua 5.2.x version was removed. +# Note: BR2_PACKAGE_LUA_5_2 is still referenced from package/lua/Config.in config BR2_TARGET_GENERIC_PASSWD_MD5 bool "target passwd md5 format support has been removed" diff --git a/package/lua/Config.in b/package/lua/Config.in index 309dd6eec2..8fa9f9b7ab 100644 --- a/package/lua/Config.in +++ b/package/lua/Config.in @@ -14,6 +14,7 @@ config BR2_PACKAGE_PROVIDES_LUAINTERPRETER choice prompt "Lua Version" + default BR2_PACKAGE_LUA_5_3 if BR2_PACKAGE_LUA_5_2 # legacy default BR2_PACKAGE_LUA_5_4 help Select the version of Lua API/ABI you wish to use. From patchwork Sun Nov 27 13:07:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709348 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKptL37Xtz23mg for ; Mon, 28 Nov 2022 00:12:42 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 8B3C3410BE; Sun, 27 Nov 2022 13:12:40 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 8B3C3410BE X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8w6Q19IvGBim; Sun, 27 Nov 2022 13:12:38 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id DDFC2410C2; Sun, 27 Nov 2022 13:12:36 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org DDFC2410C2 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 9B98A1BF42C for ; Sun, 27 Nov 2022 13:09:00 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 77DD6400D0 for ; Sun, 27 Nov 2022 13:09:00 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 77DD6400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id g7qPccUVpe9P for ; Sun, 27 Nov 2022 13:08:59 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org A795B400B8 Received: from mail-oi1-x22e.google.com (mail-oi1-x22e.google.com [IPv6:2607:f8b0:4864:20::22e]) by smtp2.osuosl.org (Postfix) with ESMTPS id A795B400B8 for ; Sun, 27 Nov 2022 13:08:59 +0000 (UTC) Received: by mail-oi1-x22e.google.com with SMTP id n205so9047112oib.1 for ; Sun, 27 Nov 2022 05:08:59 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=4IOsoYGR3VQS/vE/lmnNnZ/IYsnduM0ChrApOk5J3qg=; b=TA0yDsuBtx80M6MCNfwbeQs7M6dOIHlgSrNVLG0+9kVLQ/yHg7y0aQkdRmBSlywobj Y+3VKVEA4tQjWn9YWQk6gXFBP6y0SMO2P7bR+D2I40RQiZ8Dw0gqN47vqksrzYN2RY74 EKpKSmP2fBMvX8mHpWdO5ALOOO8GQ5AmO9G/OAG8IzfwRxwUGVeuHCq2lWv3Ed3rYe+E 3S55zQTYJrPdTFeBx55rbFoduQuviqsH06cZ4bip3rq2c1+/JmoGrObs650Wq4KuJlkj XVRzeSpG08CfJM1vebRCC9S2iP3VTRifNlelY/78eNwQTpQF4dwsARHGGPaoLOtlTJU/ Ae/A== X-Gm-Message-State: ANoB5pn2AKw3+AmAYeyg0gC64KbkZ0u0z+sk7dWi3uLr8Thgfs2VlD7J lrJoeui7mYa7C1M/QSzIqn6sRcOgO74= X-Google-Smtp-Source: AA0mqf5bwhzlem8DQacdsmtvObiKMwPrdJy0qXHXVSEoA2NcOvyf4+1nEdMt5dV6S5LXFqqnl0nbWA== X-Received: by 2002:a05:6808:6d0:b0:35b:72eb:cad3 with SMTP id m16-20020a05680806d000b0035b72ebcad3mr10969693oih.83.1669554539368; Sun, 27 Nov 2022 05:08:59 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:08:58 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:35 -0300 Message-Id: <20221127130739.1862398-22-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=4IOsoYGR3VQS/vE/lmnNnZ/IYsnduM0ChrApOk5J3qg=; b=EerDmekyqkbIEq1/DEUbkSwPWaLCM85cva+Gs7G9SpAiuoqMm5PoZ/fHuyAY9RL94x 4rQPTMGoPrOdK3cNaaymYN2blFd8AplyHnVZ1qp+uWDFIpiwRvnNcZdKbQihUMi12H+T zlvBwTy92WjKbcvtuLSDk3GpKXsxcMJF/DhOyLU7Cu1xC2TJsq0paDkBjXsAN5LZI55B Qm7smeduqBdKOdYO3Bkj/r8IrmehLXhatrjo7ccWnUpI7+jXnCL2KFisQBtV+UiOizzH IBdlE/xnCxWhEHMQk2hqCzyqKdupSbKrbJXg355cM/xhr6NiXMR9r05ehWCjZWKLZAdr yW+Q== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=EerDmeky Subject: [Buildroot] [next 21/25] package/ti-sgx-km: properly handle legacy for removed options X-BeenThere: buildroot@buildroot.org 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: Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "c38b5566fe package/ti-sgx-{km, um, demos}: bump to latest TI version", added in release 2020.02, removed some options that were previously renamed in release 2018.05. Update the legacy entry for 2018.05 and add the corresponding legacy entries for 2020.02. Signed-off-by: Ricardo Martincoski --- test config 1: BR2_PACKAGE_TI_SGX_KM=y BR2_PACKAGE_TI_SGX_AM5430=y BR2_LINUX_KERNEL=y BR2_arm=y test config 2: BR2_PACKAGE_TI_SGX_KM=y BR2_PACKAGE_TI_SGX_KM_AM5430=y BR2_LINUX_KERNEL=y BR2_arm=y test config 3: BR2_PACKAGE_TI_SGX_AM335X=y BR2_LINUX_KERNEL=y BR2_arm=y test config 4: BR2_PACKAGE_TI_SGX_KM_AM335X=y BR2_LINUX_KERNEL=y BR2_arm=y --- Config.in.legacy | 66 ++++++++++++++++++++++++++++++------------------ 1 file changed, 42 insertions(+), 24 deletions(-) diff --git a/Config.in.legacy b/Config.in.legacy index 3131c31e68..5dfbd8b831 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -1629,6 +1629,35 @@ config BR2_PACKAGE_RPI_USERLAND_START_VCFILED help The vcfiled support was removed upstream. +config BR2_PACKAGE_TI_SGX_KM_AM335X + bool "ti-sgx-km AM335X option removed" + select BR2_LEGACY + select BR2_PACKAGE_TI_SGX_KM + help + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. + +config BR2_PACKAGE_TI_SGX_KM_AM437X + bool "ti-sgx-km AM437X option removed" + select BR2_LEGACY + help + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. + +config BR2_PACKAGE_TI_SGX_KM_AM4430 + bool "ti-sgx-km AM4430 option removed" + select BR2_LEGACY + help + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. + +config BR2_PACKAGE_TI_SGX_KM_AM5430 + bool "ti-sgx-km AM5430 option removed" + select BR2_LEGACY + help + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. + comment "Legacy options removed in 2019.11" config BR2_PACKAGE_OPENVMTOOLS_PROCPS @@ -2602,45 +2631,34 @@ config BR2_PACKAGE_MEDIAART_BACKEND_QT BR2_PACKAGE_MEDIAART_BACKEND_QT has been renamed to BR2_PACKAGE_LIBMEDIAART_BACKEND_QT -# Note: BR2_PACKAGE_TI_SGX_AM335X is still referenced from -# package/ti-sgx-km/Config.in config BR2_PACKAGE_TI_SGX_AM335X - bool "ti-sgx-km AM335X option renamed" + bool "ti-sgx-km AM335X option removed" select BR2_LEGACY + select BR2_PACKAGE_TI_SGX_KM help - For consistency reasons, the option - BR2_PACKAGE_TI_SGX_AM335X has been renamed to - BR2_PACKAGE_TI_SGX_KM_AM335X. + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. -# Note: BR2_PACKAGE_TI_SGX_AM437X is still referenced from -# package/ti-sgx-km/Config.in config BR2_PACKAGE_TI_SGX_AM437X - bool "ti-sgx-km AM437X option renamed" + bool "ti-sgx-km AM437X option removed" select BR2_LEGACY help - For consistency reasons, the option - BR2_PACKAGE_TI_SGX_AM437X has been renamed to - BR2_PACKAGE_TI_SGX_KM_AM437X. + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. -# Note: BR2_PACKAGE_TI_SGX_AM4430 is still referenced from -# package/ti-sgx-km/Config.in config BR2_PACKAGE_TI_SGX_AM4430 - bool "ti-sgx-km AM4430 option renamed" + bool "ti-sgx-km AM4430 option removed" select BR2_LEGACY help - For consistency reasons, the option - BR2_PACKAGE_TI_SGX_AM4430 has been renamed to - BR2_PACKAGE_TI_SGX_KM_AM4430. + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. -# Note: BR2_PACKAGE_TI_SGX_AM5430 is still referenced from -# package/ti-sgx-km/Config.in config BR2_PACKAGE_TI_SGX_AM5430 - bool "ti-sgx-km AM5430 option renamed" + bool "ti-sgx-km AM5430 option removed" select BR2_LEGACY help - For consistency reasons, the option - BR2_PACKAGE_TI_SGX_AM5430 has been renamed to - BR2_PACKAGE_TI_SGX_KM_AM5430. + Starting from buildroot release 2020.02, the buildroot package + only supports the target am335x. config BR2_PACKAGE_JANUS_AUDIO_BRIDGE bool "janus-gateway audio-bridge option renamed" From patchwork Sun Nov 27 13:07:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709349 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKptZ6cqcz23mg for ; Mon, 28 Nov 2022 00:12:54 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 10C95410C2; Sun, 27 Nov 2022 13:12:53 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 10C95410C2 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id pbuP8dloMCXQ; Sun, 27 Nov 2022 13:12:52 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id 8A82A410C7; Sun, 27 Nov 2022 13:12:50 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 8A82A410C7 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 22C601BF42C for ; Sun, 27 Nov 2022 13:09:04 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id CF63C410C7 for ; Sun, 27 Nov 2022 13:09:03 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org CF63C410C7 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nfpOmOzKu7SI for ; Sun, 27 Nov 2022 13:09:02 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org C8576410DF Received: from mail-oi1-x22f.google.com (mail-oi1-x22f.google.com [IPv6:2607:f8b0:4864:20::22f]) by smtp4.osuosl.org (Postfix) with ESMTPS id C8576410DF for ; Sun, 27 Nov 2022 13:09:02 +0000 (UTC) Received: by mail-oi1-x22f.google.com with SMTP id e205so8999288oif.11 for ; Sun, 27 Nov 2022 05:09:02 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=c6moIqYaVlSS7/Za+qXaiiuP50JTAGbUOhMdZRwzJXQ=; b=1gKCQ2TPiO2yt8HaLsu2dBk8Qvt46qXHJjQmmsWG4wx6aWx5KtTjOpL5EjD7dGYwFP W1PybIvcWuj5X1F2Gbj3aCiCqJowLn96hvFJU7hTJ4+Y9xwiuWzL8XGNexctpo7RmWjD UE8V5aYQXkTuceKBS4LJGbnbJdIiwo6plVRRTSkVw1M3T9Sw3E80lXiBZS3Qn28MnMUb I+T0vHbbk5MI7iRmQRoLnG1117c0dgS+bV8uphGLCyimncd6U703Y1e42Oyucue6JV0v bW3CFDMDuTn7kbNl3IAtxBcrIfDkIo27oJtRAnZqX09SbCV42NN6LmL4CMY6C62uOZcu qyAA== X-Gm-Message-State: ANoB5pmjd4lTZOxWguLOUp+K/3dZplTw9M987lsqEIrYKh82YiWo6yIr HjcKzekXYeiy21M2BImF4O2bKen3O5w= X-Google-Smtp-Source: AA0mqf5/F5yEfLVA6zmJA/FWBaYZIH66V3T59/8YW3YzunMisf2yC8//DXUa8WkWGztSEs+WwhZBYw== X-Received: by 2002:a05:6808:3187:b0:354:7fd4:f17b with SMTP id cd7-20020a056808318700b003547fd4f17bmr12265206oib.221.1669554542418; Sun, 27 Nov 2022 05:09:02 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.08.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:09:01 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:36 -0300 Message-Id: <20221127130739.1862398-23-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=c6moIqYaVlSS7/Za+qXaiiuP50JTAGbUOhMdZRwzJXQ=; b=UZFKFnVhQ+T2cvYveNyDo2aKQKadYCqqK9/FK/kcaQMie5rVSIyIY0bXYiwVMISdGr sCdESbL1RazeLgpZm+AJBLjc7CsF2Z16476DcEWS/jQ60T/sk1AaVHztehCXncfPHCcD fSHeY2xLMe78vJM/4PkBIQXEA/YyRVzANdeg2b1vz9V9ypYhDjzLX/cZNX+p8dS8YtyS bDa1/Oa131ZzqbnnJyr+zxMKT/yu/2SDXHtAqRL8JQlPbOqVm7AWVrXotfAdPFAyFIJ/ iga4nbVx1MT7WDfA8uVJc1JGcwKyzDJIs6ZbERZlFBrHmrXWz4FW8uoswmJ/RVy3BUcL UmWA== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=UZFKFnVh Subject: [Buildroot] [next 22/25] package/openjdk: properly handle legacy for renamed options X-BeenThere: buildroot@buildroot.org 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: Tudor Holton , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "a610bf9967 package/openjdk{-bin}: bump version to 17.0.1+12" tried to add legacy handling but the new symbols are part of a choice, and Kconfig does not enforce the select of a option from a choice. Update the legacy entry for 2021.11, following the example described in the beginning of the file. Cc: Tudor Holton Signed-off-by: Ricardo Martincoski --- test config 1: BR2_x86_64=y BR2_TOOLCHAIN_EXTERNAL=y BR2_PACKAGE_XORG7=y BR2_PACKAGE_OPENJDK=y BR2_OPENJDK_VERSION_LTS=y --- Config.in.legacy | 6 ++++-- package/openjdk/Config.in | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Config.in.legacy b/Config.in.legacy index 5dfbd8b831..27f5602d19 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -702,18 +702,20 @@ comment "Legacy options removed in 2021.11" config BR2_OPENJDK_VERSION_LTS bool "OpenJDK LTS version was renamed to OpenJDK 11" select BR2_LEGACY - select BR2_PACKAGE_OPENJDK_VERSION_11 help The LTS version option was renamed to OpenJDK 11 to make it clear what LTS version is. +# Note: BR2_OPENJDK_VERSION_LTS is still referenced from +# package/openjdk/Config.in config BR2_OPENJDK_VERSION_LATEST bool "OpenJDK latest version (16.x) was removed" select BR2_LEGACY - select BR2_PACKAGE_OPENJDK_VERSION_17 help OpenJDK 16.x is no longer mainted, so the option has been removed. Use OpenJDK 17.x instead. +# Note: BR2_OPENJDK_VERSION_LATEST is still referenced from +# package/openjdk/Config.in config BR2_PACKAGE_MPD_TIDAL bool "mpd tidal option removed" diff --git a/package/openjdk/Config.in b/package/openjdk/Config.in index 8fbe51a27f..24a56e6b84 100644 --- a/package/openjdk/Config.in +++ b/package/openjdk/Config.in @@ -57,6 +57,8 @@ if BR2_PACKAGE_OPENJDK choice prompt "openjdk version" + default BR2_PACKAGE_OPENJDK_VERSION_11 if BR2_OPENJDK_VERSION_LTS # legacy + default BR2_PACKAGE_OPENJDK_VERSION_17 if BR2_OPENJDK_VERSION_LATEST # legacy default BR2_PACKAGE_OPENJDK_VERSION_17 help Select the version of OpenJDK you wish to use. From patchwork Sun Nov 27 13:07:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709350 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [IPv6:2605:bc80:3010::136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKptr1pGPz23mg for ; Mon, 28 Nov 2022 00:13:08 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 5024560B23; Sun, 27 Nov 2022 13:13:06 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 5024560B23 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tVMMX-LNrmwL; Sun, 27 Nov 2022 13:13:05 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id 72A936061B; Sun, 27 Nov 2022 13:13:04 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 72A936061B X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 1BF741BF42C for ; Sun, 27 Nov 2022 13:09:07 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id EC11C400D0 for ; Sun, 27 Nov 2022 13:09:06 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org EC11C400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 3DF5q79mIWY5 for ; Sun, 27 Nov 2022 13:09:06 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 509FD400B8 Received: from mail-ot1-x332.google.com (mail-ot1-x332.google.com [IPv6:2607:f8b0:4864:20::332]) by smtp2.osuosl.org (Postfix) with ESMTPS id 509FD400B8 for ; Sun, 27 Nov 2022 13:09:06 +0000 (UTC) Received: by mail-ot1-x332.google.com with SMTP id g51-20020a9d12b6000000b0066dbea0d203so5362632otg.6 for ; Sun, 27 Nov 2022 05:09:06 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=DzkzXvbiCGKKCcd1SxjMlIAgDazZWzbQsr8uPvMtudM=; b=ggoO6HF4gPUOWI4/hyTT21mR3QIPitoXs4Y84Ty5TRDYMx9NRNeZfGDRq4WVhxFVq3 wSBS7aG5K4K3441EunFc7fdNziniCJTW75074pKGZONC0xut5Ox2HHlAV6ylcr2CAjhQ oCNmvzfhy8OnN+WrT2446X6NjqNKlQBMZwrbUuR8rKI8kw2khttZQyqishctmfKfCB10 gN3fIw/tuDN8563Xzp6zzkLiBpZ7yJ0e4+R1yo2w77I3PuFOGxGyZjCxHOkd4my67fqu PGITYjAZ7ATzPYePRTZdrEHEpX6Yl8HivwekHTON/b9LmJybcXNbaf0I7HWaXIVQrjh0 ZgAA== X-Gm-Message-State: ANoB5plROoYHH0NjkQr7pTSqPIFX4JLGac99b9YQw8WlUswT7XrtDZRs ur2CV4P2fU0wku73qU1vxVX/Unwj2sQ= X-Google-Smtp-Source: AA0mqf7h3I3JCbIEgr+Phgn/eG/trXf8rweZtvMd1Ha8WxVUImAY0UaFxey+SvTxo5IjfMbUAfHN6Q== X-Received: by 2002:a9d:4e90:0:b0:66c:83a8:c04a with SMTP id v16-20020a9d4e90000000b0066c83a8c04amr23022738otk.219.1669554545387; Sun, 27 Nov 2022 05:09:05 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.09.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:09:04 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:37 -0300 Message-Id: <20221127130739.1862398-24-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=DzkzXvbiCGKKCcd1SxjMlIAgDazZWzbQsr8uPvMtudM=; b=S6BRMIVmY3X13Os13N1V64/Oq4pUgZ28N31PsqlDPllRMU0g3eIOlEpJMRfC/fckE0 3upIG0OR2yDPmD1PwNQX2FCOuu5SewtA77HCiRyDmhoh+gsdvzHxrf7DhFEib9bVZqXw 3JNYf73u778KTzzmt6c4vxqDnya10m/IA35HnqQZOEBvOHtt2WRLpFateBZelaBWXEw8 +jOpHaPkLeJz4tzh0fjP6XavxkYnJtsz9OEPOaLlQgvOfPr+Yv9qaTVkDVi368y/FmE2 KD4mM3MULAt0JDZIjtxjtf0eOsImFHOR3u0qrejddXoZkSk7Gn0WxXh4hBduhw+E3rAy ZN2w== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=S6BRMIVm Subject: [Buildroot] [next 23/25] package/sunxi-mali-utgard: properly handle legacy for renamed options X-BeenThere: buildroot@buildroot.org 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: Giulio Benetti , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "6a7a652b14 package/sunxi-mali-utgard: rename from sunxi-mali-mainline" tried to add legacy handling but the new symbols are part of a choice, and Kconfig does not enforce the select of a option from a choice. Update the legacy entry for 2022.02, following the example described in the beginning of the file. Cc: Giulio Benetti Signed-off-by: Ricardo Martincoski --- test config 1: BR2_aarch64=y BR2_ARM_FPU_VFPV2=y BR2_TOOLCHAIN_EXTERNAL=y BR2_PACKAGE_SUNXI_MALI_MAINLINE=y BR2_PACKAGE_SUNXI_MALI_MAINLINE_R8P1=y --- Config.in.legacy | 6 ++++-- package/sunxi-mali-utgard/Config.in | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Config.in.legacy b/Config.in.legacy index 27f5602d19..ad2598f7a1 100644 --- a/Config.in.legacy +++ b/Config.in.legacy @@ -631,20 +631,22 @@ config BR2_PACKAGE_SUNXI_MALI_MAINLINE config BR2_PACKAGE_SUNXI_MALI_MAINLINE_R6P2 bool "sunxi-mali-mainline-r6p2 was renamed" select BR2_LEGACY - select BR2_PACKAGE_SUNXI_MALI_UTGARD_R6P2 help The sunxi-mali-mainline package has been renamed sunxi-mali-utgard, the suboptions of this package have also been renamed accordingly. +# Note: BR2_PACKAGE_SUNXI_MALI_MAINLINE_R6P2 is still referenced from +# package/sunxi-mali-utgard/Config.in config BR2_PACKAGE_SUNXI_MALI_MAINLINE_R8P1 bool "sunxi-mali-mainline-r8p1 was renamed" select BR2_LEGACY - select BR2_PACKAGE_SUNXI_MALI_UTGARD_R8P1 help The sunxi-mali-mainline package has been renamed sunxi-mali-utgard, the suboptions of this package have also been renamed accordingly. +# Note: BR2_PACKAGE_SUNXI_MALI_MAINLINE_R8P1 is still referenced from +# package/sunxi-mali-utgard/Config.in config BR2_PACKAGE_QT5WEBKIT_EXAMPLES bool "qt5webkit-examples removed" diff --git a/package/sunxi-mali-utgard/Config.in b/package/sunxi-mali-utgard/Config.in index ff49ea03f1..59ac21f5ab 100644 --- a/package/sunxi-mali-utgard/Config.in +++ b/package/sunxi-mali-utgard/Config.in @@ -20,6 +20,8 @@ config BR2_PACKAGE_PROVIDES_LIBGLES choice prompt "Version" + default BR2_PACKAGE_SUNXI_MALI_UTGARD_R6P2 if BR2_PACKAGE_SUNXI_MALI_MAINLINE_R6P2 # legacy + default BR2_PACKAGE_SUNXI_MALI_UTGARD_R8P1 if BR2_PACKAGE_SUNXI_MALI_MAINLINE_R8P1 # legacy default BR2_PACKAGE_SUNXI_MALI_UTGARD_R6P2 help Select the version of the userspace module. From patchwork Sun Nov 27 13:07:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709351 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpv45N9vz23mg for ; Mon, 28 Nov 2022 00:13:20 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id C71144028A; Sun, 27 Nov 2022 13:13:18 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org C71144028A X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7IQKGpxIDaZH; Sun, 27 Nov 2022 13:13:18 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id E72684022E; Sun, 27 Nov 2022 13:13:16 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org E72684022E X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id D0B281BF42C for ; Sun, 27 Nov 2022 13:09:11 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id A9F87400B8 for ; Sun, 27 Nov 2022 13:09:10 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org A9F87400B8 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id VCQYxN2phaZk for ; Sun, 27 Nov 2022 13:09:10 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 0B8A2400D0 Received: from mail-oa1-x31.google.com (mail-oa1-x31.google.com [IPv6:2001:4860:4864:20::31]) by smtp2.osuosl.org (Postfix) with ESMTPS id 0B8A2400D0 for ; Sun, 27 Nov 2022 13:09:09 +0000 (UTC) Received: by mail-oa1-x31.google.com with SMTP id 586e51a60fabf-13bd2aea61bso10250708fac.0 for ; Sun, 27 Nov 2022 05:09:09 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hatOqevhADjMPoJFfBO82aoeqRqk4G7aj8w0TlB9M7g=; b=bg28uZA6A/2beluZnU6GKbXEcr1f+2/oppGJLM8HhwKPz8hCVLZQy0PnJ9nRDm7VeZ DKzfMe6MhfX0CYHODhTbvRDEt/Wt/Ia9aIMtEYlWqE9IaGzHelXbwxp6oen0VOS5bd8L bW2dpbxQ0GSrpZZR5upAl1zY0Ht0ALUS0EsQyxP8QFCcxG37N4JP1c0iXSzVZKoCU01R R7kO2zHbgcXVcvqyJkRJjijnFja3kIx+7E5I5gug2HySvjiJs/ZOd3nFQWcctZUk4H5G 1DGdypOtMOXTBgVHhh2ZAOVgpmiUbojPvYMlEL/4QPrEl7Vmc3vdgbahttFGjnHkcXOg sdwQ== X-Gm-Message-State: ANoB5pkGRhhGsDmiMgFn8aPOIu680BRm5MuistX8IQFun2Hre+xI58Fo GaufK148APA6a7U0OqSJcnOw04BYLrg= X-Google-Smtp-Source: AA0mqf6RShA2jJq7Az3UCcTeE3OlfVx1xIYKDXAv5I0sXW5iZdEXJXvF0QtJJVwPTI4aX1W1IJbFDg== X-Received: by 2002:a05:6870:23a4:b0:13b:fc40:604 with SMTP id e36-20020a05687023a400b0013bfc400604mr25848872oap.120.1669554549120; Sun, 27 Nov 2022 05:09:09 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.09.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:09:07 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:38 -0300 Message-Id: <20221127130739.1862398-25-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=hatOqevhADjMPoJFfBO82aoeqRqk4G7aj8w0TlB9M7g=; b=m1bRKpkSq+WtvLks3H9AL8d32/9OBD56KYEZ/sx0gxnrAhe/utFmnFTVkuNXoa/LaN toaDLW839HzwkWyMQccHflofUF0ZfRnZjt4G04rDhGLWwCiCeSBllYXVV5P2NMjdfiF1 QSI95tyy92DbsMd0TEiFuUXdlCZr1M5AQH07+F68ABgcSWHHAaTlnjt+NnWPPoCN5bmJ UOsUS1o+UIMYcdTKYscW9sH46CsT7esAOv9M3tKY9GVD1sURfBw7GXwR2AE0AootUaSf AlLwgAA3RddHMD5047rIkbsKbrT3khfXQS2CJtWxxBtYzJuvtG2QYmODrYYWVADJI7ZI sezA== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=m1bRKpkS Subject: [Buildroot] [next 24/25] package/rpi-userland: fix typo for BR2_aarch64 X-BeenThere: buildroot@buildroot.org 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: Thomas Petazzoni , Tim Gover , Mahyar Koshkouei , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" Commit "59adb53c4c package/rpi-userland: add support for aarch64" introduced a typo in the condition that shows a comment in menuconfig. Fix the typo: BR2_arch64 -> BR2_aarch64 Cc: Mahyar Koshkouei Cc: Tim Gover Cc: Thomas Petazzoni Signed-off-by: Ricardo Martincoski --- package/rpi-userland/Config.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/rpi-userland/Config.in b/package/rpi-userland/Config.in index cfb472808b..4219bdb9c4 100644 --- a/package/rpi-userland/Config.in +++ b/package/rpi-userland/Config.in @@ -40,6 +40,6 @@ config BR2_PACKAGE_RPI_USERLAND_HELLO endif comment "rpi-userland needs a toolchain w/ C++, threads, dynamic library" - depends on BR2_arm || BR2_arch64 + depends on BR2_arm || BR2_aarch64 depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \ BR2_STATIC_LIBS From patchwork Sun Nov 27 13:07:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricardo Martincoski X-Patchwork-Id: 1709352 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=buildroot.org (client-ip=140.211.166.133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver=) Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NKpvM5kRzz23mg for ; Mon, 28 Nov 2022 00:13:35 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id F2D6A400B8; Sun, 27 Nov 2022 13:13:33 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org F2D6A400B8 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8VBGttkyfyV0; Sun, 27 Nov 2022 13:13:31 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id 5D7F6400D0; Sun, 27 Nov 2022 13:13:30 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org 5D7F6400D0 X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id E81201BF42C for ; Sun, 27 Nov 2022 13:09:16 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id D05D3400D0 for ; Sun, 27 Nov 2022 13:09:16 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org D05D3400D0 X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id yh0SsAPVwZ7Y for ; Sun, 27 Nov 2022 13:09:14 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp2.osuosl.org BB3F0400B8 Received: from mail-oa1-x2e.google.com (mail-oa1-x2e.google.com [IPv6:2001:4860:4864:20::2e]) by smtp2.osuosl.org (Postfix) with ESMTPS id BB3F0400B8 for ; Sun, 27 Nov 2022 13:09:13 +0000 (UTC) Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-14263779059so10208551fac.1 for ; Sun, 27 Nov 2022 05:09:13 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=pHBmzdBRrQF2F57Gy0ajzPBFownLm6QJoa/qSSQ87fI=; b=t3iBIDCR1mvqkysGwrg8rWgDFEjxsBQJbOZaP5hqRmcR+tlVCrpL+03XHy2QKvI6Ih NcZiM0JdV4wj8oKkhmpaPeofjpQw0eaFOT1eInz3gRo/7/O25b6OzswV6PkPvAb3fTZE Gt+Nt9KnqHTNlpNvD6fDz4aRxq0S1wahFBBWw3urpZCuVWIaZ9sB4SHBWUgD9+3E83hw pAkojp4ihD9iHqRCbR9i4FIOoLpTSKwxrpLnzHe6frORVu/PVz9C+nnRY4yGoBX1ljSc xwta5R19/1KqFWOLpJBD1mSwxxOz+nxKZIT4hb9Uikcg/x2RnXfsew4gTEYjR96/Cl// ES6w== X-Gm-Message-State: ANoB5plPKzGVzRISHg3wFoufZMaR8CtMEonQrVYowsDAOoX2zIIYuOUN djlKPqWo2JT52yuhxZyk7E+l5lhyt78= X-Google-Smtp-Source: AA0mqf6K31TrGeG1dROxo1fZTS3ax3Q5IWu3OrRmEJqWfv2bYLLtDQvK+x6/9fNwpgtNHsiVftDYcw== X-Received: by 2002:a05:6870:4b4b:b0:131:be7a:3415 with SMTP id ls11-20020a0568704b4b00b00131be7a3415mr14427276oab.269.1669554552804; Sun, 27 Nov 2022 05:09:12 -0800 (PST) Received: from localhost.localdomain ([2804:14c:7980:988a:9b54:d73e:4d8c:458c]) by smtp.gmail.com with ESMTPSA id i25-20020a9d6519000000b0066a9ba5094fsm3655102otl.1.2022.11.27.05.09.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Nov 2022 05:09:11 -0800 (PST) From: Ricardo Martincoski To: buildroot@buildroot.org Date: Sun, 27 Nov 2022 10:07:39 -0300 Message-Id: <20221127130739.1862398-26-ricardo.martincoski@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> References: <20221127130739.1862398-1-ricardo.martincoski@gmail.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=pHBmzdBRrQF2F57Gy0ajzPBFownLm6QJoa/qSSQ87fI=; b=MPuBNC8hJ4f5UR1si/ud91VB7xzNeovDyFznswDkSWplOQg4Y5OOzTTGltM8Pj95HB VeWfn0tlRiM3ojD7/oPJEtvTnywNrWolagy1bjOdDpEkbhfdeFs+ngfs+WlJPSptUU4a fFgNMB5l0GpuVPOSCMME0IP764wSRcqpphPh2zRZmE7nVCaiTuPMYdZRMSbvjklWK3LD IaiQo7wE2L8zymACixi9aLXiCGFvi+0Vf/bqsST4QUgCTSXTGm4KsGfoH2fjXVFN3Hoe he9T6kLRq11AWSCMbxhW5KGfnOQFhDDL90DD4F47KUsVlmKJiyLhMJCGEH3AbkHIglxM rL0Q== X-Mailman-Original-Authentication-Results: smtp2.osuosl.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=MPuBNC8h Subject: [Buildroot] [next 25/25] utils/check-symbols: new script X-BeenThere: buildroot@buildroot.org 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: Thomas Petazzoni , Ricardo Martincoski Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" This script checks for inconsistencies on symbols declared in Config.in and used in .mk files. Currently it checks only symbols following the pattern BR2_\w+ . The script first gets the list of all files in the repository (using git ls-files like 'make check-flake8' already do). Then it parses all relevant files, searching for symbol definitions and usages, and add entries into a database. At the end, the database is searched for inconsistencies: - symbol that is part of "choice" and is referenced with "select"; - legacy symbol being referenced in packages; - legacy symbol being redefined in packages; - symbol referenced but not defined; - symbol defined but not referenced; - legacy symbol that has a Note stating it is referenced by a package (for legacy handling) but is referenced in the package without a comment "# legacy"; - legacy symbol that has a Note stating it is referenced by a package but it is not actually referenced. There is also a debug parameter --search that dumps any filename or symbol entries from the database that matches a regexp. Sample usages: $ utils/check-symbols $ utils/docker-run utils/check-symbols $ utils/check-symbols --search 'GETTEXT\b|\/openssl' At same time the script is created: - add unit tests for it, they can be run using: utils/docker-run python3 -m pytest -v utils/checksymbolslib/ - add two more GitLab CI jobs: check-symbols (to check current tree using the script) and check-check-symbols (to check the script against its unit tests) Cc: Thomas Petazzoni Signed-off-by: Ricardo Martincoski --- This is actually v2 of the script. v1: http://patchwork.ozlabs.org/project/buildroot/patch/20220814233845.2247022-34-ricardo.martincoski@gmail.com/ But v1 was only a prototype/WIP. There was so many changes from v1 that I honestly gave up keeping track of them. Because of that, no changelog on this patch. All other patches in the series are new, found while developing this script. Because of that, no changelog in all previous patches. NOTE 1: Example usage with only this patch applied to next: $ time utils/docker-run utils/check-symbols Config.in.legacy:634: BR2_PACKAGE_SUNXI_MALI_UTGARD_R6P2 is part of a "choice" and should not be "select"ed Config.in.legacy:643: BR2_PACKAGE_SUNXI_MALI_UTGARD_R8P1 is part of a "choice" and should not be "select"ed Config.in.legacy:705: BR2_PACKAGE_OPENJDK_VERSION_11 is part of a "choice" and should not be "select"ed Config.in.legacy:713: BR2_PACKAGE_OPENJDK_VERSION_17 is part of a "choice" and should not be "select"ed Config.in.legacy:2097: BR2_PACKAGE_LUA_5_3 is part of a "choice" and should not be "select"ed Config.in.legacy:2605: BR2_PACKAGE_TI_SGX_AM335X not referenced but has a comment stating it is Config.in.legacy:2615: BR2_PACKAGE_TI_SGX_AM437X not referenced but has a comment stating it is Config.in.legacy:2625: BR2_PACKAGE_TI_SGX_AM4430 not referenced but has a comment stating it is Config.in.legacy:2635: BR2_PACKAGE_TI_SGX_AM5430 not referenced but has a comment stating it is Config.in.legacy:3973: BR2_GCC_VERSION_ARC is part of a "choice" and should not be "select"ed Config.in.legacy:4316: BR2_PACKAGE_OPENPOWERLINK_STACK_KERNEL_STACK_LIB is part of a "choice" and should not be "select"ed Config.in.legacy:4324: BR2_PACKAGE_OPENPOWERLINK_STACK_USERSPACE_DAEMON_LIB is part of a "choice" and should not be "select"ed boot/uboot/Config.in:445: BR2_TARGET_XLOADER is a legacy symbol and should not be referenced package/fwts/Config.in:31: BR2_PACKAGE_FWTS_EFI_RUNTIME_MODULE defined but not referenced package/gitlab-runner/Config.in:14: BR2_PACKAGE_LIBCURL_OPENSSL is part of a "choice" and should not be "select"ed package/rpi-userland/Config.in:43: BR2_arch64 referenced but not defined system/Config.in:81: BR2_TARGET_GENERIC_PASSWD_MD5 is a legacy symbol and should not be referenced real 0m4,703s user 0m0,057s sys 0m0,020s NOTE 2: Example usage with the whole series applied to next: $ time utils/check-symbols --search 'GETTEXT\b|\/openssl' ========== filenames found with pattern "GETTEXT\b|\/openssl": 2 package/openssl/Config.in package/openssl/openssl.mk ========== ignored filenames with pattern "GETTEXT\b|\/openssl": 0 ========== symbols with pattern "GETTEXT\b|\/openssl": 8 BR2_PACKAGE_GETTEXT {'normal usage': {'package/ecryptfs-utils/Config.in' : [13], 'package/gettext/gettext.mk': [9], 'system/Config.in': [478]}, ' selected': {'package/ecryptfs-utils/Config.in': [13], 'system/Config.in' : [478]}, 'definition': {'package/gettext/Config.in': [1]}, 'possible co nfig helper': {'package/gettext/Config.in': [1]}, 'virtual': {'package/g ettext/gettext.mk': [9]}} BR2_PACKAGE_HAS_GETTEXT {'normal usage': {'package/gettext-gnu/Config.in ': [4], 'package/gettext-tiny/Config.in': [3], 'package/gettext/gettext. mk': [9]}, 'selected': {'package/gettext-gnu/Config.in': [4], 'package/g ettext-tiny/Config.in': [3]}, 'definition': {'package/gettext/Config.in' : [11]}} BR2_PACKAGE_PROVIDES_GETTEXT {'definition': {'package/gettext-gnu/Config .in': [18], 'package/gettext-tiny/Config.in': [12], 'package/gettext/Con fig.in': [14]}, 'normal usage': {'package/gettext/gettext.mk': [9]}} BR2_PACKAGE_PROVIDES_HOST_GETTEXT {'definition': {'package/gettext-gnu/C onfig.in': [23], 'package/gettext-tiny/Config.in': [17], 'package/gettex t/Config.in': [17]}, 'normal usage': {'package/gettext/gettext.mk': [10] }} BR2_TOOLCHAIN_HAS_FULL_GETTEXT {'normal usage': {'package/gettext/Config .in': [9], 'system/Config.in': [478], 'toolchain/Config.in': [14]}, 'sel ected': {'toolchain/Config.in': [14]}, 'definition': {'toolchain/Config. in': [313]}} BR2_PACKAGE_HOST_GETTEXT {'normal usage': {'package/gettext/gettext.mk': [10]}} BR2_PACKAGE_HAS_HOST_GETTEXT {'normal usage': {'package/gettext/gettext. mk': [10]}} BR2_PACKAGE_PHP_EXT_GETTEXT {'definition': {'package/php/Config.ext': [2 11]}, 'normal usage': {'package/php/php.mk': [164]}} ========== warnings: real 0m1,337s user 0m1,270s sys 0m0,068s NOTE 3: The new GitLab CI jobs can be seen here: https://gitlab.com/RicardoMartincoski/buildroot/-/pipelines/706073924 --- DEVELOPERS | 2 + support/misc/gitlab-ci.yml.in | 8 + support/scripts/generate-gitlab-ci-yml | 2 +- utils/check-symbols | 78 +++++ utils/checksymbolslib/__init__.py | 0 utils/checksymbolslib/br.py | 140 ++++++++ utils/checksymbolslib/db.py | 205 ++++++++++++ utils/checksymbolslib/file.py | 83 +++++ utils/checksymbolslib/kconfig.py | 139 ++++++++ utils/checksymbolslib/makefile.py | 100 ++++++ utils/checksymbolslib/test_db.py | 286 ++++++++++++++++ utils/checksymbolslib/test_file.py | 152 +++++++++ utils/checksymbolslib/test_kconfig.py | 438 +++++++++++++++++++++++++ utils/checksymbolslib/test_makefile.py | 304 +++++++++++++++++ utils/checksymbolslib/test_util.py | 15 + 15 files changed, 1951 insertions(+), 1 deletion(-) create mode 100755 utils/check-symbols create mode 100644 utils/checksymbolslib/__init__.py create mode 100644 utils/checksymbolslib/br.py create mode 100644 utils/checksymbolslib/db.py create mode 100644 utils/checksymbolslib/file.py create mode 100644 utils/checksymbolslib/kconfig.py create mode 100644 utils/checksymbolslib/makefile.py create mode 100644 utils/checksymbolslib/test_db.py create mode 100644 utils/checksymbolslib/test_file.py create mode 100644 utils/checksymbolslib/test_kconfig.py create mode 100644 utils/checksymbolslib/test_makefile.py create mode 100644 utils/checksymbolslib/test_util.py diff --git a/DEVELOPERS b/DEVELOPERS index ab9cfe5ee9..889d622cdb 100644 --- a/DEVELOPERS +++ b/DEVELOPERS @@ -2522,7 +2522,9 @@ F: support/testing/run-tests F: support/testing/tests/package/test_atop.py F: support/testing/tests/utils/test_check_package.py F: utils/check-package +F: utils/check-symbols F: utils/checkpackagelib/ +F: utils/checksymbolslib/ F: utils/docker-run N: Richard Braun diff --git a/support/misc/gitlab-ci.yml.in b/support/misc/gitlab-ci.yml.in index 3ac988a519..0ccf36665e 100644 --- a/support/misc/gitlab-ci.yml.in +++ b/support/misc/gitlab-ci.yml.in @@ -2,6 +2,10 @@ script: - python3 -m pytest -v utils/checkpackagelib/ +.check-check-symbol_base: + script: + - python3 -m pytest -v utils/checksymbolslib/ + .check-DEVELOPERS_base: script: - utils/get-developers -v @@ -14,6 +18,10 @@ script: - make check-package +.check-symbol_base: + script: + - utils/check-symbols + .defconfig_check: before_script: - DEFCONFIG_NAME=$(echo ${CI_JOB_NAME} | sed -e 's,_check$,,g') diff --git a/support/scripts/generate-gitlab-ci-yml b/support/scripts/generate-gitlab-ci-yml index 27f586f1b6..e2fb2228b3 100755 --- a/support/scripts/generate-gitlab-ci-yml +++ b/support/scripts/generate-gitlab-ci-yml @@ -26,7 +26,7 @@ gen_tests() { local do_basics do_defconfigs do_runtime do_testpkg local defconfigs_ext cfg tst - basics=( check-package DEVELOPERS flake8 package ) + basics=( check-package check-symbol DEVELOPERS flake8 package symbol ) defconfigs=( $(cd configs; LC_ALL=C ls -1 *_defconfig) ) diff --git a/utils/check-symbols b/utils/check-symbols new file mode 100755 index 0000000000..ba2e760b59 --- /dev/null +++ b/utils/check-symbols @@ -0,0 +1,78 @@ +#!/usr/bin/env python3 + +import argparse +import os +import sys + +import checksymbolslib.file as file +from checksymbolslib.db import DB + + +def parse_args(): + parser = argparse.ArgumentParser() + parser.add_argument('--search', action='store', default=None, + help='print all symbols matching a given regular expression') + return parser.parse_args() + + +def change_current_dir(): + base_dir = os.path.dirname(os.path.dirname(os.path.realpath(__file__))) + os.chdir(base_dir) + + +def get_full_db(files_to_process): + db = DB() + for f in files_to_process: + file.populate_db_from_file(db, f) + return db + + +def print_filenames_with_pattern(all_files, files_to_process, pattern): + ignored_filenames = file.get_list_of_filenames_with_pattern(all_files, files_to_process, pattern) + processed_filenames = file.get_list_of_filenames_with_pattern(files_to_process, [], pattern) + print('========== filenames found with pattern "{}": {}'.format(pattern, len(processed_filenames))) + for f in processed_filenames: + print(f) + print('========== ignored filenames with pattern "{}": {}'.format(pattern, len(ignored_filenames))) + for f in ignored_filenames: + print(f) + + +def print_symbols_with_pattern(db, pattern): + symbols = db.get_symbols_with_pattern(pattern) + print('========== symbols with pattern "{}": {}'.format(pattern, len(symbols))) + for s in symbols: + print(s, str(symbols[s])) + + +def __main__(): + flags = parse_args() + + change_current_dir() + all_files = file.get_list_of_files_in_the_repo() + files_to_process = file.get_list_of_files_to_process(all_files) + db = get_full_db(files_to_process) + + if flags.search: + print_filenames_with_pattern(all_files, files_to_process, flags.search) + print_symbols_with_pattern(db, flags.search) + print('========== warnings:') + + warnings = [] + warnings += db.get_warnings_for_choices_selected() + warnings += db.get_warnings_for_legacy_symbols_being_defined() + warnings += db.get_warnings_for_legacy_symbols_being_used() + warnings += db.get_warnings_for_symbols_with_legacy_note_and_no_comment_on_usage() + warnings += db.get_warnings_for_symbols_with_legacy_note_and_no_usage() + warnings += db.get_warnings_for_symbols_without_definition() + warnings += db.get_warnings_for_symbols_without_usage() + + for filename, lineno, msg in sorted(warnings): + print('{}:{}: {}'.format(filename, lineno, msg)) + + if len(warnings) > 0: + sys.exit(1) + + +if __name__ == '__main__': + __main__() diff --git a/utils/checksymbolslib/__init__.py b/utils/checksymbolslib/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/utils/checksymbolslib/br.py b/utils/checksymbolslib/br.py new file mode 100644 index 0000000000..846a609829 --- /dev/null +++ b/utils/checksymbolslib/br.py @@ -0,0 +1,140 @@ +import os +import re + + +ignored_directories = [ + 'support/testing/', +] +# Makefile +symbols_used_only_in_source_code = [ + 'BR2_USE_CCACHE', +] +# package/skeleton/Config.in +symbols_used_only_for_host_variant = [ + 'BR2_PACKAGE_SKELETON', +] +# Makefile +# package/pkg-generic.mk +symbols_defined_only_at_command_line = [ + 'BR2_GRAPH_ALT', + 'BR2_GRAPH_DEPS_OPTS', + 'BR2_GRAPH_DOT_OPTS', + 'BR2_GRAPH_OUT', + 'BR2_GRAPH_SIZE_OPTS', + 'BR2_INSTRUMENTATION_SCRIPTS', +] +# Makefile +symbols_defined_only_when_using_br2_external = [ + 'BR2_EXTERNAL', + 'BR2_EXTERNAL_DIRS', + 'BR2_EXTERNAL_MKS', + 'BR2_EXTERNAL_NAMES', +] +# boot/barebox/barebox.mk +symbols_defined_only_for_barebox_variant = [ + 'BR2_TARGET_BAREBOX_AUX_BAREBOXENV', +] +# toolchain/toolchain/toolchain.mk +# toolchain/toolchain-buildroot/toolchain-buildroot.mk +symbols_not_defined_for_fake_virtual_packages = [ + 'BR2_PACKAGE_HAS_TOOLCHAIN', + 'BR2_PACKAGE_HAS_TOOLCHAIN_BUILDROOT', + 'BR2_PACKAGE_PROVIDES_TOOLCHAIN', + 'BR2_PACKAGE_PROVIDES_TOOLCHAIN_BUILDROOT', +] +# fs/common.mk +suffixes_not_defined_for_all_rootfs_types = [ + '_BZIP2', + '_GZIP', + '_LZ4', + '_LZMA', + '_LZO', + '_XZ', + '_ZSTD', +] +# fs/common.mk +rootfs_prefix = 'BR2_TARGET_ROOTFS_' +# package/pkg-generic.mk +package_prefix = 'BR2_PACKAGE_' +# package/pkg-generic.mk +boot_prefix = 'BR2_TARGET_' +# package/pkg-generic.mk +toolchain_prefix = 'BR2_' +# boot/barebox/barebox.mk +barebox_infra_suffixes = [ + '', + '_BAREBOXENV', + '_BOARD_DEFCONFIG', + '_CONFIG_FRAGMENT_FILES', + '_CUSTOM_CONFIG_FILE', + '_CUSTOM_EMBEDDED_ENV_PATH', + '_CUSTOM_ENV', + '_CUSTOM_ENV_PATH', + '_IMAGE_FILE', + '_USE_CUSTOM_CONFIG', + '_USE_DEFCONFIG', +] +re_kconfig_symbol = re.compile(r'\b(BR2_\w+)\b') +# Example lines to be handled: +# config BR2_TOOLCHAIN_EXTERNAL_PREFIX +# menuconfig BR2_PACKAGE_GST1_PLUGINS_BASE +re_kconfig_config = re.compile(r'^\s*(menu|)config\s+(BR2_\w+)') +# Example lines to be handled: +# default "uclibc" if BR2_TOOLCHAIN_BUILDROOT_UCLIBC +# default BR2_TARGET_GRUB2_BUILTIN_MODULES if BR2_TARGET_GRUB2_BUILTIN_MODULES != "" +# default y if BR2_HOSTARCH = "powerpc" +re_kconfig_default = re.compile(r'^\s*default\s') +re_kconfig_default_before_conditional = re.compile(r'^.*\bif\b') +re_kconfig_default_legacy_comment = re.compile(r'#\s*legacy') +# Example lines to be handled: +# depends on !(BR2_TOOLCHAIN_USES_GLIBC && BR2_TOOLCHAIN_USES_MUSL) +# depends on BR2_HOSTARCH = "x86_64" || BR2_HOSTARCH = "x86" +re_kconfig_depends = re.compile(r'^\s*depends on\s') +# Example lines to be handled: +# select BR2_PACKAGE_HOST_NODEJS if BR2_PACKAGE_NODEJS_MODULES_ADDITIONAL != "" +# select BR2_PACKAGE_LIBDRM if !(BR2_arm && BR2_PACKAGE_IMX_GPU_VIV_OUTPUT_FB) +# select BR2_PACKAGE_OPENSSL if !(BR2_PACKAGE_GNUTLS || BR2_PACKAGE_MBEDTLS) +re_kconfig_select = re.compile(r'^\s*select\s') +re_kconfig_select_conditional = re.compile(r'\bif\s.*') +# Example lines to be handled: +# if !BR2_SKIP_LEGACY +# if (BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX51 || BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX53) +# if BR2_PACKAGE_HAS_LUAINTERPRETER && !BR2_STATIC_LIBS +# if BR2_PACKAGE_QEMU_CUSTOM_TARGETS = "" +re_kconfig_if = re.compile(r'^\s*if\s') +# Example lines to be handled: +# source "$BR2_BASE_DIR/.br2-external.in.jpeg" +re_kconfig_source = re.compile(r'^\s*source\b') + +re_kconfig_choice = re.compile(r'^\s*choice\b') +re_kconfig_endchoice = re.compile(r'^\s*endchoice\b') +re_makefile_eval = re.compile(r'^\s*\$\(eval\b') +re_menu = re.compile(r'^\s*menu\b') +re_endmenu = re.compile(r'^\s*endmenu\b') +re_comments = re.compile(r'#.*$') +re_legacy_special_comment = re.compile(r'#.*(BR2_\w+)\s.*still referenced') +re_host_symbol = re.compile(r'(BR2_PACKAGE_HOST_\w+|BR2_PACKAGE_HAS_HOST_\w+)') +re_makefile_symbol_usage = re.compile(r'\$\((BR2_\w+)\)') +re_makefile_symbol_export = re.compile(r'export\s*(BR2_\w+)') +re_makefile_symbol_attribution = re.compile(r'^\s*(BR2_\w+)\s*[?:=]') + + +def get_package_from_filename(filename): + package = os.path.basename(filename)[:-3].upper().replace('-', '_') + return package + + +def is_an_optional_symbol_for_a_roofts(symbol): + if not symbol.startswith(rootfs_prefix): + return False + for sufix in suffixes_not_defined_for_all_rootfs_types: + if symbol.endswith(sufix): + return True + return False + + +def file_belongs_to_an_ignored_diretory(filename): + for d in ignored_directories: + if filename.startswith(d): + return True + return False diff --git a/utils/checksymbolslib/db.py b/utils/checksymbolslib/db.py new file mode 100644 index 0000000000..71b1e9e816 --- /dev/null +++ b/utils/checksymbolslib/db.py @@ -0,0 +1,205 @@ +import re + +import checksymbolslib.br as br + + +choice = 'part of a choice' +definition = 'definition' +helper = 'possible config helper' +legacy_definition = 'legacy definition' +legacy_note = 'legacy note' +legacy_usage = 'legacy usage' +select = 'selected' +usage = 'normal usage' +usage_in_legacy = 'usage inside legacy' +virtual = 'virtual' + + +class DB: + def __init__(self): + self.all_symbols = {} + + def __str__(self): + return str(self.all_symbols) + + def add_symbol_entry(self, symbol, filename, lineno, entry_type): + if symbol not in self.all_symbols: + self.all_symbols[symbol] = {} + if entry_type not in self.all_symbols[symbol]: + self.all_symbols[symbol][entry_type] = {} + if filename not in self.all_symbols[symbol][entry_type]: + self.all_symbols[symbol][entry_type][filename] = [] + self.all_symbols[symbol][entry_type][filename].append(lineno) + + def add_symbol_choice(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, choice) + + def add_symbol_definition(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, definition) + + def add_symbol_helper(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, helper) + + def add_symbol_legacy_definition(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, legacy_definition) + + def add_symbol_legacy_note(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, legacy_note) + + def add_symbol_legacy_usage(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, legacy_usage) + + def add_symbol_select(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, select) + + def add_symbol_usage(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, usage) + + def add_symbol_usage_in_legacy(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, usage_in_legacy) + + def add_symbol_virtual(self, symbol, filename, lineno): + self.add_symbol_entry(symbol, filename, lineno, virtual) + + def get_symbols_with_pattern(self, pattern): + re_pattern = re.compile(r'{}'.format(pattern)) + found_symbols = {} + for symbol, entries in self.all_symbols.items(): + if not re_pattern.search(symbol): + continue + found_symbols[symbol] = entries + return found_symbols + + def get_warnings_for_choices_selected(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if choice not in entries: + continue + if select not in entries: + continue + all_items = [] + all_items += entries.get(select, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} is part of a "choice" and should not be "select"ed'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings + + def get_warnings_for_legacy_symbols_being_used(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if legacy_definition not in entries: + continue + if usage not in entries: + continue + all_items = [] + all_items += entries.get(usage, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} is a legacy symbol and should not be referenced'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings + + def get_warnings_for_legacy_symbols_being_defined(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if legacy_definition not in entries: + continue + if definition not in entries: + continue + all_items = [] + all_items += entries.get(definition, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} is a legacy symbol and should not be redefined'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings + + def get_warnings_for_symbols_without_definition(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if definition in entries: + continue + if legacy_definition in entries: + continue + if br.re_host_symbol.search(symbol): + continue + if br.is_an_optional_symbol_for_a_roofts(symbol): + continue + if symbol in br.symbols_defined_only_at_command_line: + continue + if symbol in br.symbols_defined_only_when_using_br2_external: + continue + if symbol in br.symbols_defined_only_for_barebox_variant: + continue + if symbol in br.symbols_not_defined_for_fake_virtual_packages: + continue + if virtual in entries: + continue + all_items = [] + all_items += entries.get(usage, {}).items() + all_items += entries.get(legacy_usage, {}).items() + all_items += entries.get(usage_in_legacy, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} referenced but not defined'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings + + def get_warnings_for_symbols_without_usage(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if usage in entries: + continue + if usage_in_legacy in entries: + continue + if legacy_usage in entries: + continue + if symbol in br.symbols_used_only_in_source_code: + continue + if symbol in br.symbols_used_only_for_host_variant: + continue + if helper in entries: + continue + if choice in entries: + continue + all_items = [] + all_items += entries.get(definition, {}).items() + all_items += entries.get(legacy_definition, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} defined but not referenced'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings + + def get_warnings_for_symbols_with_legacy_note_and_no_comment_on_usage(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if legacy_note not in entries: + continue + if legacy_usage in entries: + continue + all_items = [] + all_items += entries.get(usage, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} missing "# legacy"'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings + + def get_warnings_for_symbols_with_legacy_note_and_no_usage(self): + warnings = [] + for symbol, entries in self.all_symbols.items(): + if legacy_note not in entries: + continue + if legacy_usage in entries: + continue + if usage in entries: + continue + all_items = [] + all_items += entries.get(legacy_note, {}).items() + for filename, linenos in all_items: + for lineno in linenos: + msg = '{} not referenced but has a comment stating it is'.format(symbol) + warnings.append((filename, lineno, msg)) + return warnings diff --git a/utils/checksymbolslib/file.py b/utils/checksymbolslib/file.py new file mode 100644 index 0000000000..0d3315bdc7 --- /dev/null +++ b/utils/checksymbolslib/file.py @@ -0,0 +1,83 @@ +import re +import subprocess + +import checksymbolslib.br as br +import checksymbolslib.kconfig as kconfig +import checksymbolslib.makefile as makefile + + +file_types = [ + kconfig, + makefile, +] + + +def get_list_of_files_in_the_repo(): + cmd = ['git', 'ls-files'] + p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) + stdout = p.communicate()[0] + processed_output = [str(line.decode().rstrip()) for line in stdout.splitlines() if line] + return processed_output + + +def get_list_of_files_to_process(all_files): + files_to_process = [] + for f in all_files: + if br.file_belongs_to_an_ignored_diretory(f): + continue + for t in file_types: + if t.check_filename(f): + files_to_process.append(f) + break + return files_to_process + + +def get_list_of_filenames_with_pattern(all_files, exclude_list, pattern): + re_pattern = re.compile(r'{}'.format(pattern)) + matching_filenames = [] + for filename in all_files: + if re_pattern.search(filename): + if filename not in exclude_list: + matching_filenames.append(filename) + return matching_filenames + + +def read_file(filename): + file_content_raw = [] + with open(filename, 'r', errors='surrogateescape') as f: + for lineno, text in enumerate(f.readlines()): + file_content_raw.append([lineno + 1, text]) + return file_content_raw + + +def cleanup_file_content(file_content_raw): + cleaned_up_content = [] + continuation = False + last_line = None + first_lineno = None + for cur_lineno, cur_line in file_content_raw: + if continuation: + line = last_line + cur_line + lineno = first_lineno + else: + line = cur_line + lineno = cur_lineno + continuation = False + last_line = None + first_lineno = None + clean_line = line.rstrip('\n') + if clean_line.endswith('\\'): + continuation = True + last_line = clean_line.rstrip('\\') + first_lineno = lineno + continue + cleaned_up_content.append([lineno, clean_line]) + return cleaned_up_content + + +def populate_db_from_file(db, filename): + file_content_raw = read_file(filename) + file_content_to_process = cleanup_file_content(file_content_raw) + for t in file_types: + if t.check_filename(filename): + t.populate_db(db, filename, file_content_to_process) diff --git a/utils/checksymbolslib/kconfig.py b/utils/checksymbolslib/kconfig.py new file mode 100644 index 0000000000..9ad6030305 --- /dev/null +++ b/utils/checksymbolslib/kconfig.py @@ -0,0 +1,139 @@ +import os + +import checksymbolslib.br as br + + +def all_symbols_from(line): + clean_line = br.re_comments.sub('', line) + symbols = br.re_kconfig_symbol.findall(clean_line) + return symbols + + +def handle_definition(db, filename, lineno, line, legacy): + for symbol in all_symbols_from(line): + if legacy: + db.add_symbol_legacy_definition(symbol, filename, lineno) + else: + db.add_symbol_definition(symbol, filename, lineno) + + +def handle_usage(db, filename, lineno, line, legacy): + for symbol in all_symbols_from(line): + if legacy: + db.add_symbol_usage_in_legacy(symbol, filename, lineno) + else: + db.add_symbol_usage(symbol, filename, lineno) + + +def handle_default(db, filename, lineno, line, legacy): + if legacy: + handle_usage(db, filename, lineno, line, legacy) + return + if not br.re_kconfig_default_legacy_comment.search(line): + handle_usage(db, filename, lineno, line, legacy) + return + after = br.re_kconfig_default_before_conditional.sub('', line) + for symbol in all_symbols_from(after): + db.add_symbol_legacy_usage(symbol, filename, lineno) + + +def handle_select(db, filename, lineno, line, legacy): + handle_usage(db, filename, lineno, line, legacy) + before = br.re_kconfig_select_conditional.sub('', line) + for symbol in all_symbols_from(before): + db.add_symbol_select(symbol, filename, lineno) + + +line_type_handlers = { + br.re_kconfig_config: handle_definition, + br.re_kconfig_default: handle_default, + br.re_kconfig_depends: handle_usage, + br.re_kconfig_if: handle_usage, + br.re_kconfig_select: handle_select, + br.re_kconfig_source: handle_usage, +} + + +def handle_line(db, filename, lineno, line, legacy): + if not br.re_kconfig_symbol.search(line): + return + + for regexp, line_type_handler in line_type_handlers.items(): + if regexp.search(line): + line_type_handler(db, filename, lineno, line, legacy) + + +def handle_config_helper(db, filename, file_content): + symbol = None + lineno = None + state = 'none' + for cur_lineno, line in file_content: + if state == 'none': + m = br.re_kconfig_config.search(line) + if m is not None: + symbol = m.group(2) + lineno = cur_lineno + state = 'config' + continue + if state == 'config': + if br.re_kconfig_select.search(line): + db.add_symbol_helper(symbol, filename, lineno) + state = 'none' + continue + m = br.re_kconfig_config.search(line) + if m is not None: + symbol = m.group(2) + lineno = cur_lineno + continue + + +def handle_config_choice(db, filename, file_content): + state = 'none' + for lineno, line in file_content: + if state == 'none': + if br.re_kconfig_choice.search(line): + state = 'choice' + continue + if state == 'choice': + if br.re_kconfig_endchoice.search(line): + state = 'none' + continue + m = br.re_kconfig_config.search(line) + if m is not None: + symbol = m.group(2) + db.add_symbol_choice(symbol, filename, lineno) + continue + + +def handle_note(db, filename, file_content): + state = 'none' + for lineno, line in file_content: + if state == 'none': + if br.re_menu.search(line): + state = 'menu' + continue + if state == 'menu': + if br.re_endmenu.search(line): + state = 'none' + continue + m = br.re_legacy_special_comment.search(line) + if m is not None: + symbol = m.group(1) + db.add_symbol_legacy_note(symbol, filename, lineno) + continue + + +def populate_db(db, filename, file_content): + legacy = filename.endswith('.legacy') + for lineno, line in file_content: + handle_line(db, filename, lineno, line, legacy) + handle_config_helper(db, filename, file_content) + handle_config_choice(db, filename, file_content) + if legacy: + handle_note(db, filename, file_content) + + +def check_filename(filename): + if os.path.basename(filename).startswith('Config.'): + return True + return False diff --git a/utils/checksymbolslib/makefile.py b/utils/checksymbolslib/makefile.py new file mode 100644 index 0000000000..e3894dd1f9 --- /dev/null +++ b/utils/checksymbolslib/makefile.py @@ -0,0 +1,100 @@ +import checksymbolslib.br as br + + +def handle_eval(db, filename, lineno, line): + def add_multiple_symbol_usages(package, prefixes=None, suffixes=None): + for prefix in prefixes or ['']: + for sufix in suffixes or ['']: + symbol = prefix + package + sufix + db.add_symbol_usage(symbol, filename, lineno) + + package = br.get_package_from_filename(filename) + if '$(rootfs)' in line: + suffixes = [''] + br.suffixes_not_defined_for_all_rootfs_types + add_multiple_symbol_usages(package, prefixes=[br.rootfs_prefix], suffixes=suffixes) + return + if '$(kernel-module)' in line: + add_multiple_symbol_usages(package, prefixes=[br.package_prefix]) + return + if '$(barebox-package)' in line: + add_multiple_symbol_usages(package, prefixes=[br.boot_prefix], suffixes=br.barebox_infra_suffixes) + return + + if '-package)' not in line: + return + if package == 'LINUX': + # very special case at package/pkg-generic.mk + add_multiple_symbol_usages('BR2_LINUX_KERNEL') + return + + # mimic package/pkg-generic.mk and package/pkg-virtual.mk + if '$(virtual-' in line: + prefixes = ['BR2_PACKAGE_PROVIDES_', 'BR2_PACKAGE_HAS_'] + if filename.startswith('toolchain/'): + prefix = br.toolchain_prefix + else: + prefix = br.package_prefix + symbol = prefix + package + db.add_symbol_virtual(symbol, filename, lineno) + prefixes.append(prefix) + elif '$(host-virtual-' in line: + prefixes = ['BR2_PACKAGE_HOST_', 'BR2_PACKAGE_PROVIDES_HOST_', 'BR2_PACKAGE_HAS_HOST_'] + elif '$(host-' in line: + prefixes = ['BR2_PACKAGE_HOST_'] + elif filename.startswith('boot/'): + prefixes = [br.boot_prefix] + elif filename.startswith('toolchain/'): + prefixes = [br.toolchain_prefix] + elif '$(toolchain-' in line: + prefixes = [br.toolchain_prefix] + else: + prefixes = [br.package_prefix] + + add_multiple_symbol_usages(package, prefixes=prefixes) + + +def handle_definition(db, filename, lineno, line, legacy): + symbols = br.re_makefile_symbol_attribution.findall(line) + symbols += br.re_makefile_symbol_export.findall(line) + for symbol in symbols: + if legacy: + db.add_symbol_legacy_definition(symbol, filename, lineno) + else: + db.add_symbol_definition(symbol, filename, lineno) + + +def handle_usage(db, filename, lineno, line, legacy): + if br.re_makefile_eval.search(line): + handle_eval(db, filename, lineno, line) + return + + symbols = br.re_makefile_symbol_usage.findall(line) + for symbol in symbols: + if legacy: + db.add_symbol_usage_in_legacy(symbol, filename, lineno) + else: + db.add_symbol_usage(symbol, filename, lineno) + + +def populate_db(db, filename, file_content): + legacy = filename.endswith('.legacy') + for lineno, raw_line in file_content: + line = br.re_comments.sub('', raw_line) + handle_definition(db, filename, lineno, line, legacy) + handle_usage(db, filename, lineno, line, legacy) + + +def check_filename(filename): + if filename.endswith('.mk'): + return True + if filename.endswith('.mk.in'): + return True + if filename.startswith('arch/arch.mk.'): + return True + if filename in [ + 'Makefile', + 'Makefile.legacy', + 'package/Makefile.in' + ]: + return True + return False diff --git a/utils/checksymbolslib/test_db.py b/utils/checksymbolslib/test_db.py new file mode 100644 index 0000000000..15576fa897 --- /dev/null +++ b/utils/checksymbolslib/test_db.py @@ -0,0 +1,286 @@ +import checksymbolslib.db as m + + +def test_empty_db(): + db = m.DB() + assert str(db) == '{}' + + +def test_one_definition(): + db = m.DB() + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + assert str(db) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}}, + }) + + +def test_three_definitions(): + db = m.DB() + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 9) + db.add_symbol_definition('BR2_bar', 'bar/Config.in', 5) + assert str(db) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7, 9]}}, + 'BR2_bar': {'definition': {'bar/Config.in': [5]}}, + }) + + +def test_definition_and_usage(): + db = m.DB() + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_usage('BR2_foo', 'foo/Config.in', 9) + assert str(db) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}, 'normal usage': {'foo/Config.in': [9]}}, + }) + + +def test_all_entry_types(): + db = m.DB() + db.add_symbol_choice('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_definition('BR2_bar', 'bar/Config.in', 700) + db.add_symbol_helper('BR2_bar', 'bar/Config.in', 700) + db.add_symbol_legacy_definition('BR2_baz', 'Config.in.legacy', 7000) + db.add_symbol_legacy_note('BR2_baz', 'Config.in.legacy', 7001) + db.add_symbol_legacy_usage('BR2_bar', 'Config.in.legacy', 7001) + db.add_symbol_select('BR2_bar', 'Config.in.legacy', 7001) + db.add_symbol_usage('BR2_foo', 'foo/Config.in', 9) + db.add_symbol_usage_in_legacy('BR2_bar', 'Config.in.legacy', 9) + db.add_symbol_virtual('BR2_foo', 'foo/Config.in', 7) + assert str(db) == str({ + 'BR2_foo': { + 'part of a choice': {'foo/Config.in': [7]}, + 'definition': {'foo/Config.in': [7]}, + 'normal usage': {'foo/Config.in': [9]}, + 'virtual': {'foo/Config.in': [7]}}, + 'BR2_bar': { + 'definition': {'bar/Config.in': [700]}, + 'possible config helper': {'bar/Config.in': [700]}, + 'legacy usage': {'Config.in.legacy': [7001]}, + 'selected': {'Config.in.legacy': [7001]}, + 'usage inside legacy': {'Config.in.legacy': [9]}}, + 'BR2_baz': { + 'legacy definition': {'Config.in.legacy': [7000]}, + 'legacy note': {'Config.in.legacy': [7001]}}, + }) + + +def test_get_symbols_with_pattern(): + db = m.DB() + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_usage('BR2_foo', 'foo/Config.in', 9) + db.add_symbol_definition('BR2_bar', 'bar/Config.in', 5) + assert str(db) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}, 'normal usage': {'foo/Config.in': [9]}}, + 'BR2_bar': {'definition': {'bar/Config.in': [5]}}, + }) + symbols = db.get_symbols_with_pattern('foo') + assert str(symbols) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}, 'normal usage': {'foo/Config.in': [9]}}, + }) + symbols = db.get_symbols_with_pattern('FOO') + assert str(symbols) == str({ + }) + symbols = db.get_symbols_with_pattern('foo|FOO') + assert str(symbols) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}, 'normal usage': {'foo/Config.in': [9]}}, + }) + symbols = db.get_symbols_with_pattern('^foo') + assert str(symbols) == str({ + }) + symbols = db.get_symbols_with_pattern('foo|bar') + assert str(symbols) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}, 'normal usage': {'foo/Config.in': [9]}}, + 'BR2_bar': {'definition': {'bar/Config.in': [5]}}, + }) + + +def test_get_warnings_for_choices_selected(): + db = m.DB() + db.add_symbol_choice('BR2_foo', 'foo/Config.in', 1) + db.add_symbol_choice('BR2_bar', 'bar/Config.in', 1) + db.add_symbol_select('BR2_foo', 'bar/Config.in', 2) + assert str(db) == str({ + 'BR2_foo': {'part of a choice': {'foo/Config.in': [1]}, 'selected': {'bar/Config.in': [2]}}, + 'BR2_bar': {'part of a choice': {'bar/Config.in': [1]}}, + }) + warnings = db.get_warnings_for_choices_selected() + assert warnings == [ + ('bar/Config.in', 2, 'BR2_foo is part of a "choice" and should not be "select"ed'), + ] + + +def test_get_warnings_for_legacy_symbols_being_used(): + db = m.DB() + db.add_symbol_legacy_definition('BR2_foo', 'Config.in.legacy', 1) + db.add_symbol_usage('BR2_foo', 'bar/Config.in', 2) + db.add_symbol_legacy_definition('BR2_bar', 'Config.in.legacy', 10) + db.add_symbol_usage_in_legacy('BR2_bar', 'Config.in.legacy', 11) + assert str(db) == str({ + 'BR2_foo': {'legacy definition': {'Config.in.legacy': [1]}, 'normal usage': {'bar/Config.in': [2]}}, + 'BR2_bar': {'legacy definition': {'Config.in.legacy': [10]}, 'usage inside legacy': {'Config.in.legacy': [11]}}, + }) + warnings = db.get_warnings_for_legacy_symbols_being_used() + assert warnings == [ + ('bar/Config.in', 2, 'BR2_foo is a legacy symbol and should not be referenced'), + ] + + +def test_get_warnings_for_legacy_symbols_being_defined(): + db = m.DB() + db.add_symbol_legacy_definition('BR2_foo', 'Config.in.legacy', 1) + db.add_symbol_legacy_definition('BR2_bar', 'Config.in.legacy', 10) + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 8) + assert str(db) == str({ + 'BR2_foo': {'legacy definition': {'Config.in.legacy': [1]}, 'definition': {'foo/Config.in': [7, 8]}}, + 'BR2_bar': {'legacy definition': {'Config.in.legacy': [10]}}, + }) + warnings = db.get_warnings_for_legacy_symbols_being_defined() + assert warnings == [ + ('foo/Config.in', 7, 'BR2_foo is a legacy symbol and should not be redefined'), + ('foo/Config.in', 8, 'BR2_foo is a legacy symbol and should not be redefined'), + ] + + +def test_get_warnings_for_symbols_without_definition(): + db = m.DB() + db.add_symbol_definition('BR2_foo', 'foo/Config.in', 7) + db.add_symbol_legacy_definition('BR2_bar', 'Config.in.legacy', 10) + db.add_symbol_virtual('BR2_baz', 'baz/Config.in', 7) + db.add_symbol_usage('BR2_foo', 'file', 1) + db.add_symbol_usage('BR2_bar', 'file', 1) + db.add_symbol_usage('BR2_baz', 'file', 1) + db.add_symbol_usage('BR2_undef1', 'file', 1) + db.add_symbol_legacy_usage('BR2_undef2', 'file', 2) + db.add_symbol_usage_in_legacy('BR2_undef3', 'file', 3) + db.add_symbol_usage('BR2_undef3', 'another', 1) + db.add_symbol_legacy_usage('BR2_undef3', 'another', 2) + db.add_symbol_usage('BR2_PACKAGE_HOST_undef', 'file', 1) + db.add_symbol_usage('BR2_PACKAGE_HAS_HOST_undef', 'file', 1) + db.add_symbol_usage('BR2_TARGET_ROOTFS_undef_XZ', 'file', 1) + db.add_symbol_usage('BR2_GRAPH_ALT', 'file', 1) + db.add_symbol_usage('BR2_EXTERNAL', 'file', 1) + db.add_symbol_usage('BR2_TARGET_BAREBOX_AUX_BAREBOXENV', 'file', 1) + db.add_symbol_usage('BR2_PACKAGE_HAS_TOOLCHAIN_BUILDROOT', 'file', 1) + assert str(db) == str({ + 'BR2_foo': {'definition': {'foo/Config.in': [7]}, 'normal usage': {'file': [1]}}, + 'BR2_bar': {'legacy definition': {'Config.in.legacy': [10]}, 'normal usage': {'file': [1]}}, + 'BR2_baz': {'virtual': {'baz/Config.in': [7]}, 'normal usage': {'file': [1]}}, + 'BR2_undef1': {'normal usage': {'file': [1]}}, + 'BR2_undef2': {'legacy usage': {'file': [2]}}, + 'BR2_undef3': {'usage inside legacy': {'file': [3]}, 'normal usage': {'another': [1]}, 'legacy usage': {'another': [2]}}, + 'BR2_PACKAGE_HOST_undef': {'normal usage': {'file': [1]}}, + 'BR2_PACKAGE_HAS_HOST_undef': {'normal usage': {'file': [1]}}, + 'BR2_TARGET_ROOTFS_undef_XZ': {'normal usage': {'file': [1]}}, + 'BR2_GRAPH_ALT': {'normal usage': {'file': [1]}}, + 'BR2_EXTERNAL': {'normal usage': {'file': [1]}}, + 'BR2_TARGET_BAREBOX_AUX_BAREBOXENV': {'normal usage': {'file': [1]}}, + 'BR2_PACKAGE_HAS_TOOLCHAIN_BUILDROOT': {'normal usage': {'file': [1]}}, + }) + warnings = db.get_warnings_for_symbols_without_definition() + assert warnings == [ + ('file', 1, 'BR2_undef1 referenced but not defined'), + ('file', 2, 'BR2_undef2 referenced but not defined'), + ('another', 1, 'BR2_undef3 referenced but not defined'), + ('another', 2, 'BR2_undef3 referenced but not defined'), + ('file', 3, 'BR2_undef3 referenced but not defined'), + ] + + +def test_get_warnings_for_symbols_without_usage(): + db = m.DB() + db.add_symbol_definition('BR2_a', 'a/Config.in', 1) + db.add_symbol_definition('BR2_a', 'a/Config.in', 2) + db.add_symbol_usage('BR2_a', 'file', 1) + db.add_symbol_usage('BR2_a', 'file', 2) + db.add_symbol_definition('BR2_b', 'b/Config.in', 2) + db.add_symbol_usage_in_legacy('BR2_b', 'file', 1) + db.add_symbol_definition('BR2_c', 'c/Config.in', 2) + db.add_symbol_legacy_usage('BR2_c', 'file', 1) + db.add_symbol_definition('BR2_USE_CCACHE', 'file', 1) + db.add_symbol_definition('BR2_PACKAGE_SKELETON', 'file', 1) + db.add_symbol_definition('BR2_d', 'd/Config.in', 2) + db.add_symbol_helper('BR2_d', 'd/Config.in', 2) + db.add_symbol_definition('BR2_e', 'e/Config.in', 2) + db.add_symbol_choice('BR2_e', 'e/Config.in', 2) + db.add_symbol_definition('BR2_f', 'f/Config.in', 2) + db.add_symbol_definition('BR2_g', 'g/Config.in', 2) + db.add_symbol_definition('BR2_g', 'g/Config.in', 3) + db.add_symbol_legacy_definition('BR2_h', 'Config.in.legacy', 1) + db.add_symbol_usage('BR2_h', 'file', 2) + db.add_symbol_usage('BR2_h', 'file', 3) + db.add_symbol_legacy_definition('BR2_i', 'Config.in.legacy', 2) + db.add_symbol_usage_in_legacy('BR2_i', 'file', 2) + db.add_symbol_legacy_definition('BR2_j', 'Config.in.legacy', 2) + db.add_symbol_legacy_usage('BR2_j', 'file', 2) + db.add_symbol_legacy_definition('BR2_k', 'Config.in.legacy', 2) + db.add_symbol_usage('BR2_k', 'file', 5) + db.add_symbol_usage_in_legacy('BR2_k', 'file', 6) + db.add_symbol_legacy_usage('BR2_k', 'file', 7) + db.add_symbol_legacy_definition('BR2_l', 'Config.in.legacy', 2) + assert str(db) == str({ + 'BR2_a': {'definition': {'a/Config.in': [1, 2]}, 'normal usage': {'file': [1, 2]}}, + 'BR2_b': {'definition': {'b/Config.in': [2]}, 'usage inside legacy': {'file': [1]}}, + 'BR2_c': {'definition': {'c/Config.in': [2]}, 'legacy usage': {'file': [1]}}, + 'BR2_USE_CCACHE': {'definition': {'file': [1]}}, + 'BR2_PACKAGE_SKELETON': {'definition': {'file': [1]}}, + 'BR2_d': {'definition': {'d/Config.in': [2]}, 'possible config helper': {'d/Config.in': [2]}}, + 'BR2_e': {'definition': {'e/Config.in': [2]}, 'part of a choice': {'e/Config.in': [2]}}, + 'BR2_f': {'definition': {'f/Config.in': [2]}}, + 'BR2_g': {'definition': {'g/Config.in': [2, 3]}}, + 'BR2_h': {'legacy definition': {'Config.in.legacy': [1]}, 'normal usage': {'file': [2, 3]}}, + 'BR2_i': {'legacy definition': {'Config.in.legacy': [2]}, 'usage inside legacy': {'file': [2]}}, + 'BR2_j': {'legacy definition': {'Config.in.legacy': [2]}, 'legacy usage': {'file': [2]}}, + 'BR2_k': { + 'legacy definition': {'Config.in.legacy': [2]}, + 'normal usage': {'file': [5]}, + 'usage inside legacy': {'file': [6]}, + 'legacy usage': {'file': [7]}}, + 'BR2_l': {'legacy definition': {'Config.in.legacy': [2]}}, + }) + warnings = db.get_warnings_for_symbols_without_usage() + assert warnings == [ + ('f/Config.in', 2, 'BR2_f defined but not referenced'), + ('g/Config.in', 2, 'BR2_g defined but not referenced'), + ('g/Config.in', 3, 'BR2_g defined but not referenced'), + ('Config.in.legacy', 2, 'BR2_l defined but not referenced'), + ] + + +def test_get_warnings_for_symbols_with_legacy_note_and_no_comment_on_usage(): + db = m.DB() + db.add_symbol_legacy_note('BR2_foo', 'Config.in.legacy', 1) + db.add_symbol_legacy_usage('BR2_foo', 'package/bar/Config.in', 2) + db.add_symbol_legacy_note('BR2_baz', 'Config.in.legacy', 7001) + db.add_symbol_usage('BR2_baz', 'package/foo/Config.in', 1) + assert str(db) == str({ + 'BR2_foo': {'legacy note': {'Config.in.legacy': [1]}, 'legacy usage': {'package/bar/Config.in': [2]}}, + 'BR2_baz': {'legacy note': {'Config.in.legacy': [7001]}, 'normal usage': {'package/foo/Config.in': [1]}}, + }) + warnings = db.get_warnings_for_symbols_with_legacy_note_and_no_comment_on_usage() + assert warnings == [ + ('package/foo/Config.in', 1, 'BR2_baz missing "# legacy"'), + ] + + +def test_get_warnings_for_symbols_with_legacy_note_and_no_usage(): + db = m.DB() + db.add_symbol_legacy_note('BR2_foo', 'Config.in.legacy', 1) + db.add_symbol_legacy_usage('BR2_foo', 'package/bar/Config.in', 2) + db.add_symbol_legacy_note('BR2_bar', 'Config.in.legacy', 1) + db.add_symbol_usage_in_legacy('BR2_bar', 'Config.in.legacy', 7001) + db.add_symbol_legacy_note('BR2_baz', 'Config.in.legacy', 7001) + db.add_symbol_legacy_note('BR2_no_comment', 'Config.in.legacy', 1) + db.add_symbol_usage('BR2_no_comment', 'package/bar/Config.in', 2) + assert str(db) == str({ + 'BR2_foo': {'legacy note': {'Config.in.legacy': [1]}, 'legacy usage': {'package/bar/Config.in': [2]}}, + 'BR2_bar': {'legacy note': {'Config.in.legacy': [1]}, 'usage inside legacy': {'Config.in.legacy': [7001]}}, + 'BR2_baz': {'legacy note': {'Config.in.legacy': [7001]}}, + 'BR2_no_comment': {'legacy note': {'Config.in.legacy': [1]}, 'normal usage': {'package/bar/Config.in': [2]}}, + }) + warnings = db.get_warnings_for_symbols_with_legacy_note_and_no_usage() + assert warnings == [ + ('Config.in.legacy', 1, 'BR2_bar not referenced but has a comment stating it is'), + ('Config.in.legacy', 7001, 'BR2_baz not referenced but has a comment stating it is'), + ] diff --git a/utils/checksymbolslib/test_file.py b/utils/checksymbolslib/test_file.py new file mode 100644 index 0000000000..3b4ee108d1 --- /dev/null +++ b/utils/checksymbolslib/test_file.py @@ -0,0 +1,152 @@ +import os +import pytest +import tempfile +import checksymbolslib.file as m + + +def test_get_list_of_files_in_the_repo(): + all_files = m.get_list_of_files_in_the_repo() + assert 'Makefile' in all_files + assert 'package/Config.in' in all_files + assert len(all_files) > 1000 + + +get_list_of_files_to_process = [ + ('unknown file type', + ['a/file/Config.in', + 'another/file.mk', + 'unknown/file/type'], + ['a/file/Config.in', + 'another/file.mk']), + ('runtime test infra fixtures', + ['a/file/Config.in', + 'support/testing/a/broken/Config.in', + 'another/file.mk'], + ['a/file/Config.in', + 'another/file.mk']), + ] + + +@pytest.mark.parametrize('testname,all_files,expected', get_list_of_files_to_process) +def test_get_list_of_files_to_process(testname, all_files, expected): + files_to_process = m.get_list_of_files_to_process(all_files) + assert files_to_process == expected + + +get_list_of_filenames_with_pattern = [ + ('ignored directories', + ['a/file/Config.in', + 'support/testing/a/broken/file/Config.in', + 'not/found.mk', + 'another/file.mk'], + ['a/file/Config.in', + 'not/found.mk', + 'another/file.mk'], + 'file', + ['support/testing/a/broken/file/Config.in']), + ('processed files', + ['a/file/Config.in', + 'not/found.mk', + 'another/file.mk'], + [], + 'file', + ['a/file/Config.in', + 'another/file.mk']), + ('case sensitive', + ['a/file/Config.in', + 'not/found.mk', + 'another/file.mk'], + [], + 'FILE', + []), + ('or', + ['a/file/Config.in', + 'not/found.mk', + 'another/file.mk'], + [], + 'file|FILE', + ['a/file/Config.in', + 'another/file.mk']), + ('complex regexp', + ['a/file/Config.in', + 'not/found.mk', + 'another/file.mk'], + [], + '^n[oO]+t.*mk$', + ['not/found.mk']), + ] + + +@pytest.mark.parametrize('testname,all_files,files_to_process,pattern,expected', get_list_of_filenames_with_pattern) +def test_get_list_of_filenames_with_pattern(testname, all_files, files_to_process, pattern, expected): + files_to_process = m.get_list_of_filenames_with_pattern(all_files, files_to_process, pattern) + assert files_to_process == expected + + +read_file = [ + ('indent', + 'file1', + ' content1\n' + '\t# comment1', + [[1, ' content1\n'], + [2, '\t# comment1']]), + ('trailing space', + 'file2', + 'content2 \n' + '# comment2\t\n', + [[1, 'content2 \n'], + [2, '# comment2\t\n']]), + ('empty line', + 'file3', + '\n' + '\n', + [[1, '\n'], + [2, '\n']]), + ('missing newline at EOF', + 'file4', + '\n' + ' text\t', + [[1, '\n'], + [2, ' text\t']]), + ] + + +@pytest.mark.parametrize('testname,filename,content,,expected', read_file) +def test_read_file(testname, filename, content, expected): + with tempfile.TemporaryDirectory(suffix='-checksymbolslib-test-file') as workdir: + full_filename = os.path.join(workdir, filename) + with open(full_filename, 'wb') as f: + f.write(content.encode()) + read_file_content = m.read_file(full_filename) + assert read_file_content == expected + + +cleanup_file_content = [ + ('empty file', + [], + []), + ('empty line', + [[5, '\n']], + [[5, '']]), + ('trailing space', + [[3, ' \n']], + [[3, ' ']]), + ('trailing tab', + [[3, '\t\n']], + [[3, '\t']]), + ('1 continuation', + [[1, 'foo \\\n'], + [2, 'bar\n']], + [[1, 'foo bar']]), + ('2 continuations', + [[1, 'foo \\\n'], + [2, 'bar \\\n'], + [3, 'baz\n']], + [[1, 'foo bar baz']]), + ] + + +@pytest.mark.parametrize('testname,file_content_raw,expected', cleanup_file_content) +def test_cleanup_file_content(testname, file_content_raw, expected): + cleaned_up_content = m.cleanup_file_content(file_content_raw) + assert cleaned_up_content == expected diff --git a/utils/checksymbolslib/test_kconfig.py b/utils/checksymbolslib/test_kconfig.py new file mode 100644 index 0000000000..ab2008df6c --- /dev/null +++ b/utils/checksymbolslib/test_kconfig.py @@ -0,0 +1,438 @@ +import pytest +from unittest.mock import Mock +from unittest.mock import call +from checksymbolslib.test_util import assert_db_calls +import checksymbolslib.kconfig as m + + +all_symbols_from = [ + ('no prefix', + 'config PACKAGE_FOO', + []), + ('simple', + 'config BR2_PACKAGE_FOO', + ['BR2_PACKAGE_FOO']), + ('ignore comment', + 'config BR2_PACKAGE_FOO # BR2_PACKAGE_BAR', + ['BR2_PACKAGE_FOO']), + ('ignore whitespace', + '\tconfig BR2_PACKAGE_FOO\t # BR2_PACKAGE_BAR', + ['BR2_PACKAGE_FOO']), + ('2 occurrences', + '\tdefault BR2_PACKAGE_FOO_BAR if BR2_PACKAGE_FOO_BAR != ""', + ['BR2_PACKAGE_FOO_BAR', 'BR2_PACKAGE_FOO_BAR']), + ] + + +@pytest.mark.parametrize('testname,line,expected', all_symbols_from) +def test_all_symbols_from(testname, line, expected): + symbols = m.all_symbols_from(line) + assert symbols == expected + + +handle_definition = [ + ('config', + 'package/foo/Config.in', + 5, + 'config BR2_PACKAGE_FOO', + False, + {'add_symbol_definition': [call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5)]}), + ('ignore comment', + 'package/foo/Config.in', + 5, + 'config BR2_PACKAGE_FOO # BR2_PACKAGE_BAR', + False, + {'add_symbol_definition': [call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5)]}), + ('ignore whitespace', + 'package/foo/Config.in', + 5, + '\tconfig BR2_PACKAGE_FOO\t # BR2_PACKAGE_BAR', + False, + {'add_symbol_definition': [call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5)]}), + ('menuconfig', + 'package/gd/Config.in', + 1, + 'menuconfig BR2_PACKAGE_GD', + False, + {'add_symbol_definition': [call('BR2_PACKAGE_GD', 'package/gd/Config.in', 1)]}), + ('menu', + 'package/Config.in', + 100, + 'menu "Database"', + False, + {}), + ('legacy config', + 'Config.in.legacy', + 50, + 'config BR2_PACKAGE_FOO', + True, + {'add_symbol_legacy_definition': [call('BR2_PACKAGE_FOO', 'Config.in.legacy', 50)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_definition) +def test_handle_definition(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_definition(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +handle_usage = [ + ('default with comparison', + 'package/openblas/Config.in', + 60, + '\tdefault y if BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET != ""', + False, + {'add_symbol_usage': [call('BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET', 'package/openblas/Config.in', 60)]}), + ('default with logical operators', + 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', + 47, + '\tdefault y if BR2_i386 && !BR2_x86_i486 && !BR2_x86_i586 && !BR2_x86_x1000 && !BR2_x86_pentium_mmx && !BR2_x86_geode ' + '&& !BR2_x86_c3 && !BR2_x86_winchip_c6 && !BR2_x86_winchip2', + False, + {'add_symbol_usage': [ + call('BR2_i386', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_c3', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_geode', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_i486', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_i586', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_pentium_mmx', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_winchip2', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_winchip_c6', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_x1000', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47)]}), + ('legacy depends on', + 'Config.in.legacy', + 3000, + '\tdepends on BR2_LINUX_KERNEL', + True, + {'add_symbol_usage_in_legacy': [call('BR2_LINUX_KERNEL', 'Config.in.legacy', 3000)]}), + ('legacy if', + 'Config.in.legacy', + 97, + 'if !BR2_SKIP_LEGACY', + True, + {'add_symbol_usage_in_legacy': [call('BR2_SKIP_LEGACY', 'Config.in.legacy', 97)]}), + ('source', + 'system/Config.in', + 152, + 'source "$BR2_BASE_DIR/.br2-external.in.init"', + False, + {'add_symbol_usage': [call('BR2_BASE_DIR', 'system/Config.in', 152)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_usage) +def test_handle_usage(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_usage(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +handle_default = [ + ('default with comparison', + 'package/openblas/Config.in', + 60, + '\tdefault y if BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET != ""', + False, + {'add_symbol_usage': [call('BR2_PACKAGE_OPENBLAS_DEFAULT_TARGET', 'package/openblas/Config.in', 60)]}), + ('default with logical operators', + 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', + 47, + '\tdefault y if BR2_i386 && !BR2_x86_i486 && !BR2_x86_i586 && !BR2_x86_x1000 && !BR2_x86_pentium_mmx && !BR2_x86_geode ' + '&& !BR2_x86_c3 && !BR2_x86_winchip_c6 && !BR2_x86_winchip2', + False, + {'add_symbol_usage': [ + call('BR2_i386', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_c3', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_geode', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_i486', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_i586', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_pentium_mmx', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_winchip2', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_winchip_c6', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47), + call('BR2_x86_x1000', 'toolchain/toolchain-external/toolchain-external-bootlin/Config.in.options', 47)]}), + ('legacy default', + 'Config.in.legacy', + 3000, + 'default y if BR2_PACKAGE_REFPOLICY_POLICY_VERSION != ""', + True, + {'add_symbol_usage_in_legacy': [call('BR2_PACKAGE_REFPOLICY_POLICY_VERSION', 'Config.in.legacy', 3000)]}), + ('legacy handling on package', + 'package/uboot-tools/Config.in.host', + 105, + '\tdefault BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE if BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE != "" # legacy', + False, + {'add_symbol_legacy_usage': [call('BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE', 'package/uboot-tools/Config.in.host', 105)]}), + ('default on package', + 'package/uboot-tools/Config.in.host', + 105, + '\tdefault BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE if BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE != ""', + False, + {'add_symbol_usage': [ + call('BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE', 'package/uboot-tools/Config.in.host', 105), + call('BR2_TARGET_UBOOT_BOOT_SCRIPT_SOURCE', 'package/uboot-tools/Config.in.host', 105)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_default) +def test_handle_default(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_default(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +handle_select = [ + ('select with comparison', + 'package/bcusdk/Config.in', + 6, + '\tselect BR2_PACKAGE_ARGP_STANDALONE if BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_MUSL', + False, + {'add_symbol_select': [call('BR2_PACKAGE_ARGP_STANDALONE', 'package/bcusdk/Config.in', 6)], + 'add_symbol_usage': [ + call('BR2_PACKAGE_ARGP_STANDALONE', 'package/bcusdk/Config.in', 6), + call('BR2_TOOLCHAIN_USES_UCLIBC', 'package/bcusdk/Config.in', 6), + call('BR2_TOOLCHAIN_USES_MUSL', 'package/bcusdk/Config.in', 6)]}), + ('legacy select', + 'Config.in.legacy', + 100, + '\tselect BR2_PACKAGE_WPA_SUPPLICANT_DBUS if BR2_TOOLCHAIN_HAS_THREADS', + True, + {'add_symbol_select': [call('BR2_PACKAGE_WPA_SUPPLICANT_DBUS', 'Config.in.legacy', 100)], + 'add_symbol_usage_in_legacy': [ + call('BR2_PACKAGE_WPA_SUPPLICANT_DBUS', 'Config.in.legacy', 100), + call('BR2_TOOLCHAIN_HAS_THREADS', 'Config.in.legacy', 100)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_select) +def test_handle_select(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_select(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +handle_line = [ + ('select with comparison', + 'package/bcusdk/Config.in', + 6, + '\tselect BR2_PACKAGE_ARGP_STANDALONE if BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_MUSL', + False, + {'add_symbol_select': [call('BR2_PACKAGE_ARGP_STANDALONE', 'package/bcusdk/Config.in', 6)], + 'add_symbol_usage': [ + call('BR2_PACKAGE_ARGP_STANDALONE', 'package/bcusdk/Config.in', 6), + call('BR2_TOOLCHAIN_USES_UCLIBC', 'package/bcusdk/Config.in', 6), + call('BR2_TOOLCHAIN_USES_MUSL', 'package/bcusdk/Config.in', 6)]}), + ('legacy select', + 'Config.in.legacy', + 100, + '\tselect BR2_PACKAGE_WPA_SUPPLICANT_DBUS if BR2_TOOLCHAIN_HAS_THREADS', + True, + {'add_symbol_select': [call('BR2_PACKAGE_WPA_SUPPLICANT_DBUS', 'Config.in.legacy', 100)], + 'add_symbol_usage_in_legacy': [ + call('BR2_PACKAGE_WPA_SUPPLICANT_DBUS', 'Config.in.legacy', 100), + call('BR2_TOOLCHAIN_HAS_THREADS', 'Config.in.legacy', 100)]}), + ('comment with symbol', + 'Config.in', + 6, + '\tselect # BR2_PACKAGE_ARGP_STANDALONE if BR2_TOOLCHAIN_USES_UCLIBC || BR2_TOOLCHAIN_USES_MUSL', + False, + {}), + ('comment', + 'Config.in', + 6, + '# just a comment', + False, + {}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_line) +def test_handle_line(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_line(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +handle_config_helper = [ + ('no select', + 'package/foo/Config.in', + [[5, 'config BR2_PACKAGE_FOO']], + {}), + ('select', + 'package/foo/Config.in', + [[5, 'config BR2_PACKAGE_FOO'], + [6, '\tselect BR2_PACKAGE_BAR']], + {'add_symbol_helper': [call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5)]}), + ('ignore comment', + 'package/foo/Config.in', + [[5, 'config BR2_PACKAGE_FOO # BR2_PACKAGE_BAR'], + [6, '\tselect BR2_PACKAGE_BAR # BR2_PACKAGE_FOO']], + {'add_symbol_helper': [call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5)]}), + ('correct symbol', + 'package/foo/Config.in', + [[5, 'config BR2_PACKAGE_FOO'], + [6, 'config BR2_PACKAGE_BAR'], + [7, '\tselect BR2_PACKAGE_BAZ']], + {'add_symbol_helper': [call('BR2_PACKAGE_BAR', 'package/foo/Config.in', 6)]}), + ('2 selects', + 'package/foo/Config.in', + [[5, 'config BR2_PACKAGE_FOO'], + [6, '\tselect BR2_PACKAGE_BAR'], + [7, ' select BR2_PACKAGE_BAR']], + {'add_symbol_helper': [call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5)]}), + ] + + +@pytest.mark.parametrize('testname,filename,file_content,expected_calls', handle_config_helper) +def test_handle_config_helper(testname, filename, file_content, expected_calls): + db = Mock() + m.handle_config_helper(db, filename, file_content) + assert_db_calls(db, expected_calls) + + +handle_config_choice = [ + ('no choice', + 'package/foo/Config.in', + [[5, 'config BR2_PACKAGE_FOO']], + {}), + ('after', + 'package/foo/Config.in', + [[3, 'choice'], + [4, '\tprompt "your choice"'], + [5, 'config BR2_PACKAGE_FOO'], + [6, 'config BR2_PACKAGE_BAR'], + [10, 'endchoice'], + [19, 'config BR2_PACKAGE_BAZ']], + {'add_symbol_choice': [ + call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5), + call('BR2_PACKAGE_BAR', 'package/foo/Config.in', 6)]}), + ('before', + 'package/foo/Config.in', + [[1, 'config BR2_PACKAGE_BAZ'], + [3, 'choice'], + [4, '\tprompt "your choice"'], + [5, 'config BR2_PACKAGE_FOO'], + [6, 'config BR2_PACKAGE_BAR'], + [10, 'endchoice']], + {'add_symbol_choice': [ + call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5), + call('BR2_PACKAGE_BAR', 'package/foo/Config.in', 6)]}), + ] + + +@pytest.mark.parametrize('testname,filename,file_content,expected_calls', handle_config_choice) +def test_handle_config_choice(testname, filename, file_content, expected_calls): + db = Mock() + m.handle_config_choice(db, filename, file_content) + assert_db_calls(db, expected_calls) + + +handle_note = [ + ('example', + 'Config.in.legacy', + [[51, '# # Note: BR2_FOO_1 is still referenced from package/foo/Config.in']], + {}), + ('ok', + 'Config.in.legacy', + [[112, 'menu "Legacy config options"'], + [2132, '# Note: BR2_PACKAGE_FOO is still referenced from package/foo/Config.in'], + [4958, 'endmenu']], + {'add_symbol_legacy_note': [call('BR2_PACKAGE_FOO', 'Config.in.legacy', 2132)]}), + ('before and after', + 'Config.in.legacy', + [[100, '# Note: BR2_PACKAGE_BAR is still referenced from package/foo/Config.in'], + [112, 'menu "Legacy config options"'], + [2132, '# Note: BR2_PACKAGE_FOO is still referenced from package/foo/Config.in'], + [4958, 'endmenu'], + [5000, '# Note: BR2_PACKAGE_BAR is still referenced from package/foo/Config.in']], + {'add_symbol_legacy_note': [call('BR2_PACKAGE_FOO', 'Config.in.legacy', 2132)]}), + ] + + +@pytest.mark.parametrize('testname,filename,file_content,expected_calls', handle_note) +def test_handle_note(testname, filename, file_content, expected_calls): + db = Mock() + m.handle_note(db, filename, file_content) + assert_db_calls(db, expected_calls) + + +populate_db = [ + ('legacy', + 'Config.in.legacy', + [[112, 'menu "Legacy config options"'], + [2100, 'config BR2_PACKAGE_FOO'], + [2101, '\tselect BR2_PACKAGE_BAR'], + [2132, '# Note: BR2_PACKAGE_FOO is still referenced from package/foo/Config.in'], + [4958, 'endmenu']], + {'add_symbol_legacy_note': [call('BR2_PACKAGE_FOO', 'Config.in.legacy', 2132)], + 'add_symbol_helper': [call('BR2_PACKAGE_FOO', 'Config.in.legacy', 2100)], + 'add_symbol_legacy_definition': [call('BR2_PACKAGE_FOO', 'Config.in.legacy', 2100)], + 'add_symbol_usage_in_legacy': [call('BR2_PACKAGE_BAR', 'Config.in.legacy', 2101)], + 'add_symbol_select': [call('BR2_PACKAGE_BAR', 'Config.in.legacy', 2101)]}), + ('normal', + 'package/foo/Config.in', + [[1, 'config BR2_PACKAGE_BAZ'], + [3, 'choice'], + [4, '\tprompt "your choice"'], + [5, 'config BR2_PACKAGE_FOO'], + [6, 'config BR2_PACKAGE_BAR'], + [7, '\t select BR2_PACKAGE_FOO_BAR'], + [10, 'endchoice']], + {'add_symbol_choice': [ + call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5), + call('BR2_PACKAGE_BAR', 'package/foo/Config.in', 6)], + 'add_symbol_usage': [ + call('BR2_PACKAGE_FOO_BAR', 'package/foo/Config.in', 7)], + 'add_symbol_select': [ + call('BR2_PACKAGE_FOO_BAR', 'package/foo/Config.in', 7)], + 'add_symbol_definition': [ + call('BR2_PACKAGE_BAZ', 'package/foo/Config.in', 1), + call('BR2_PACKAGE_FOO', 'package/foo/Config.in', 5), + call('BR2_PACKAGE_BAR', 'package/foo/Config.in', 6)], + 'add_symbol_helper': [ + call('BR2_PACKAGE_BAR', 'package/foo/Config.in', 6)]}), + ] + + +@pytest.mark.parametrize('testname,filename,file_content,expected_calls', populate_db) +def test_populate_db(testname, filename, file_content, expected_calls): + db = Mock() + m.populate_db(db, filename, file_content) + assert_db_calls(db, expected_calls) + + +check_filename = [ + ('Config.in', + 'Config.in', + True), + ('Config.in.legacy', + 'Config.in.legacy', + True), + ('arch/Config.in.microblaze', + 'arch/Config.in.microblaze', + True), + ('package/php/Config.ext', + 'package/php/Config.ext', + True), + ('package/pru-software-support/Config.in.host', + 'package/pru-software-support/Config.in.host', + True), + ('toolchain/toolchain-external/toolchain-external-custom/Config.in.options', + 'toolchain/toolchain-external/toolchain-external-custom/Config.in.options', + True), + ('package/foo/0001-Config.patch', + 'package/foo/0001-Config.patch', + False), + ('package/pkg-generic.mk', + 'package/pkg-generic.mk', + False), + ('Makefile', + 'Makefile', + False), + ] + + +@pytest.mark.parametrize('testname,filename,expected', check_filename) +def test_check_filename(testname, filename, expected): + symbols = m.check_filename(filename) + assert symbols == expected diff --git a/utils/checksymbolslib/test_makefile.py b/utils/checksymbolslib/test_makefile.py new file mode 100644 index 0000000000..14d07eaa45 --- /dev/null +++ b/utils/checksymbolslib/test_makefile.py @@ -0,0 +1,304 @@ +import pytest +from unittest.mock import Mock +from unittest.mock import call +from checksymbolslib.test_util import assert_db_calls +import checksymbolslib.makefile as m + + +handle_eval = [ + ('generic', + 'package/foo/foo.mk', + 5, + '$(eval $(generic-package))', + {'add_symbol_usage': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 5)]}), + ('ignore trailing whitespace', + 'package/foo/foo.mk', + 5, + '$(eval $(generic-package)) ', + {'add_symbol_usage': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 5)]}), + ('ignore indent', + 'package/foo/foo.mk', + 5, + '\t$(eval $(generic-package))', + {'add_symbol_usage': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 5)]}), + ('rootfs', + 'fs/foo/foo.mk', + 5, + '$(eval $(rootfs))', + {'add_symbol_usage': [ + call('BR2_TARGET_ROOTFS_FOO', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_BZIP2', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_GZIP', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_LZ4', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_LZMA', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_LZO', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_XZ', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_ZSTD', 'fs/foo/foo.mk', 5)]}), + ('kernel module', + 'package/foo/foo.mk', + 6, + '$(eval $(kernel-module))', + {'add_symbol_usage': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 6)]}), + ('not an eval for package infra', + 'docs/manual/manual.mk', + 10, + '$(eval $(call asciidoc-document))', + {}), + ('linux', + 'linux/linux.mk', + 617, + '$(eval $(kconfig-package))', + {'add_symbol_usage': [call('BR2_LINUX_KERNEL', 'linux/linux.mk', 617)]}), + ('virtual toolchain', + 'toolchain/toolchain-external/toolchain-external.mk', + 18, + '$(eval $(virtual-package))', + {'add_symbol_usage': [ + call('BR2_PACKAGE_PROVIDES_TOOLCHAIN_EXTERNAL', 'toolchain/toolchain-external/toolchain-external.mk', 18), + call('BR2_PACKAGE_HAS_TOOLCHAIN_EXTERNAL', 'toolchain/toolchain-external/toolchain-external.mk', 18), + call('BR2_TOOLCHAIN_EXTERNAL', 'toolchain/toolchain-external/toolchain-external.mk', 18)], + 'add_symbol_virtual': [call('BR2_TOOLCHAIN_EXTERNAL', 'toolchain/toolchain-external/toolchain-external.mk', 18)]}), + ('virtual package', + 'package/foo/foo.mk', + 18, + '$(eval $(virtual-package))', + {'add_symbol_usage': [ + call('BR2_PACKAGE_PROVIDES_FOO', 'package/foo/foo.mk', 18), + call('BR2_PACKAGE_HAS_FOO', 'package/foo/foo.mk', 18), + call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 18)], + 'add_symbol_virtual': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 18)]}), + ('host virtual package', + 'package/foo/foo.mk', + 18, + '$(eval $(host-virtual-package))', + {'add_symbol_usage': [ + call('BR2_PACKAGE_PROVIDES_HOST_FOO', 'package/foo/foo.mk', 18), + call('BR2_PACKAGE_HAS_HOST_FOO', 'package/foo/foo.mk', 18), + call('BR2_PACKAGE_HOST_FOO', 'package/foo/foo.mk', 18)]}), + ('host generic package', + 'package/foo/foo.mk', + 18, + '$(eval $(host-package))', + {'add_symbol_usage': [call('BR2_PACKAGE_HOST_FOO', 'package/foo/foo.mk', 18)]}), + ('boot package', + 'boot/foo/foo.mk', + 18, + '$(eval $(generic-package))', + {'add_symbol_usage': [call('BR2_TARGET_FOO', 'boot/foo/foo.mk', 18)]}), + ('toolchain package', + 'toolchain/foo/foo.mk', + 18, + '$(eval $(generic-package))', + {'add_symbol_usage': [call('BR2_FOO', 'toolchain/foo/foo.mk', 18)]}), + ('generic package', + 'package/foo/foo.mk', + 18, + '$(eval $(generic-package))', + {'add_symbol_usage': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 18)]}), + ('cmake package', + 'package/foo/foo.mk', + 18, + '$(eval $(cmake-package))', + {'add_symbol_usage': [call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 18)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,expected_calls', handle_eval) +def test_handle_eval(testname, filename, lineno, line, expected_calls): + db = Mock() + m.handle_eval(db, filename, lineno, line) + assert_db_calls(db, expected_calls) + + +handle_definition = [ + ('legacy attribution', + 'Makefile.legacy', + 9, + 'BR2_LEGACY_FOO := foo', + True, + {'add_symbol_legacy_definition': [call('BR2_LEGACY_FOO', 'Makefile.legacy', 9)]}), + ('attribution 1', + 'Makefile', + 9, + 'BR2_FOO ?= foo', + False, + {'add_symbol_definition': [call('BR2_FOO', 'Makefile', 9)]}), + ('attribution 2', + 'Makefile', + 9, + 'BR2_FOO = $(BR2_BAR)', + False, + {'add_symbol_definition': [call('BR2_FOO', 'Makefile', 9)]}), + ('attribution 3', + 'Makefile', + 9, + 'BR2_FOO := foo', + False, + {'add_symbol_definition': [call('BR2_FOO', 'Makefile', 9)]}), + ('normal export', + 'Makefile', + 90, + 'export BR2_FOO', + False, + {'add_symbol_definition': [call('BR2_FOO', 'Makefile', 90)]}), + ('legacy export', + 'Makefile.legacy', + 90, + 'export BR2_FOO', + True, + {'add_symbol_legacy_definition': [call('BR2_FOO', 'Makefile.legacy', 90)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_definition) +def test_handle_definition(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_definition(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +handle_usage = [ + ('legacy', + 'Makefile.legacy', + 8, + 'ifeq ($(BR2_LEGACY),y)', + True, + {'add_symbol_usage_in_legacy': [call('BR2_LEGACY', 'Makefile.legacy', 8)]}), + ('attribution', + 'Makefile', + 9, + 'BR2_FOO = $(BR2_BAR)', + False, + {'add_symbol_usage': [call('BR2_BAR', 'Makefile', 9)]}), + ('host virtual package', + 'package/foo/foo.mk', + 18, + '$(eval $(host-virtual-package))', + False, + {'add_symbol_usage': [ + call('BR2_PACKAGE_PROVIDES_HOST_FOO', 'package/foo/foo.mk', 18), + call('BR2_PACKAGE_HAS_HOST_FOO', 'package/foo/foo.mk', 18), + call('BR2_PACKAGE_HOST_FOO', 'package/foo/foo.mk', 18)]}), + ] + + +@pytest.mark.parametrize('testname,filename,lineno,line,legacy,expected_calls', handle_usage) +def test_handle_usage(testname, filename, lineno, line, legacy, expected_calls): + db = Mock() + m.handle_usage(db, filename, lineno, line, legacy) + assert_db_calls(db, expected_calls) + + +populate_db = [ + ('legacy', + 'Makefile.legacy', + [[8, 'ifeq ($(BR2_LEGACY),y)'], + [9, 'BR2_LEGACY_FOO := foo'], + [34, 'ifneq ($(BUILDROOT_CONFIG),$(BR2_CONFIG))']], + {'add_symbol_usage_in_legacy': [ + call('BR2_LEGACY', 'Makefile.legacy', 8), + call('BR2_CONFIG', 'Makefile.legacy', 34)], + 'add_symbol_legacy_definition': [call('BR2_LEGACY_FOO', 'Makefile.legacy', 9)]}), + ('attribution', + 'Makefile', + [[9, 'BR2_FOO = $(BR2_BAR)']], + {'add_symbol_definition': [call('BR2_FOO', 'Makefile', 9)], + 'add_symbol_usage': [call('BR2_BAR', 'Makefile', 9)]}), + ('legacy attribution', + 'Makefile.legacy', + [[9, 'BR2_FOO = $(BR2_BAR)']], + {'add_symbol_legacy_definition': [call('BR2_FOO', 'Makefile.legacy', 9)], + 'add_symbol_usage_in_legacy': [call('BR2_BAR', 'Makefile.legacy', 9)]}), + ('generic', + 'package/foo/foo.mk', + [[3, 'ifeq ($(BR2_PACKAGE_FOO_BAR):$(BR2_BAR),y:)'], + [4, 'export BR2_PACKAGE_FOO_BAZ'], + [5, '$(eval $(generic-package))']], + {'add_symbol_usage': [ + call('BR2_PACKAGE_FOO_BAR', 'package/foo/foo.mk', 3), + call('BR2_BAR', 'package/foo/foo.mk', 3), + call('BR2_PACKAGE_FOO', 'package/foo/foo.mk', 5)], + 'add_symbol_definition': [call('BR2_PACKAGE_FOO_BAZ', 'package/foo/foo.mk', 4)]}), + ('rootfs', + 'fs/foo/foo.mk', + [[4, 'ifeq ($(BR2_TARGET_ROOTFS_FOO_LZ4),y)'], + [5, '$(eval $(rootfs))']], + {'add_symbol_usage': [ + call('BR2_TARGET_ROOTFS_FOO', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_BZIP2', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_GZIP', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_LZ4', 'fs/foo/foo.mk', 4), + call('BR2_TARGET_ROOTFS_FOO_LZ4', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_LZMA', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_LZO', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_XZ', 'fs/foo/foo.mk', 5), + call('BR2_TARGET_ROOTFS_FOO_ZSTD', 'fs/foo/foo.mk', 5)]}), + ] + + +@pytest.mark.parametrize('testname,filename,file_content,expected_calls', populate_db) +def test_populate_db(testname, filename, file_content, expected_calls): + db = Mock() + m.populate_db(db, filename, file_content) + assert_db_calls(db, expected_calls) + + +check_filename = [ + ('arch/arch.mk.riscv', + 'arch/arch.mk.riscv', + True), + ('boot/lpc32xxcdl/lpc32xxcdl.mk', + 'boot/lpc32xxcdl/lpc32xxcdl.mk', + True), + ('fs/cramfs/cramfs.mk', + 'fs/cramfs/cramfs.mk', + True), + ('linux/linux-ext-fbtft.mk', + 'linux/linux-ext-fbtft.mk', + True), + ('package/ace/ace.mk', + 'package/ace/ace.mk', + True), + ('package/linux-tools/linux-tool-hv.mk.in', + 'package/linux-tools/linux-tool-hv.mk.in', + True), + ('package/pkg-generic.mk', + 'package/pkg-generic.mk', + True), + ('package/x11r7/xlib_libXt/xlib_libXt.mk', + 'package/x11r7/xlib_libXt/xlib_libXt.mk', + True), + ('support/dependencies/check-host-make.mk', + 'support/dependencies/check-host-make.mk', + True), + ('toolchain/toolchain-external/toolchain-external-arm-aarch64-be/toolchain-external-arm-aarch64-be.mk', + 'toolchain/toolchain-external/toolchain-external-arm-aarch64-be/toolchain-external-arm-aarch64-be.mk', + True), + ('Makefile.legacy', + 'Makefile.legacy', + True), + ('boot/common.mk', + 'boot/common.mk', + True), + ('fs/common.mk', + 'fs/common.mk', + True), + ('Makefile', + 'Makefile', + True), + ('package/Makefile.in', + 'package/Makefile.in', + True), + ('Config.in', + 'Config.in', + False), + ('package/foo/0001-Makefile.patch', + 'package/foo/0001-Makefile.patch', + False), + ] + + +@pytest.mark.parametrize('testname,filename,expected', check_filename) +def test_check_filename(testname, filename, expected): + symbols = m.check_filename(filename) + assert symbols == expected diff --git a/utils/checksymbolslib/test_util.py b/utils/checksymbolslib/test_util.py new file mode 100644 index 0000000000..166785ba1d --- /dev/null +++ b/utils/checksymbolslib/test_util.py @@ -0,0 +1,15 @@ +def assert_calls(method, expected_calls): + method.assert_has_calls(expected_calls, any_order=True) + assert method.call_count == len(expected_calls) + + +def assert_db_calls(db, expected_calls): + assert_calls(db.add_symbol_legacy_definition, expected_calls.get('add_symbol_legacy_definition', [])) + assert_calls(db.add_symbol_definition, expected_calls.get('add_symbol_definition', [])) + assert_calls(db.add_symbol_usage_in_legacy, expected_calls.get('add_symbol_usage_in_legacy', [])) + assert_calls(db.add_symbol_usage, expected_calls.get('add_symbol_usage', [])) + assert_calls(db.add_symbol_legacy_usage, expected_calls.get('add_symbol_legacy_usage', [])) + assert_calls(db.add_symbol_select, expected_calls.get('add_symbol_select', [])) + assert_calls(db.add_symbol_helper, expected_calls.get('add_symbol_helper', [])) + assert_calls(db.add_symbol_legacy_note, expected_calls.get('add_symbol_legacy_note', [])) + assert_calls(db.add_symbol_virtual, expected_calls.get('add_symbol_virtual', []))