From patchwork Fri Sep 22 21:05:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 31022 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1D78CCE7A86 for ; Fri, 22 Sep 2023 21:05:17 +0000 (UTC) Received: from mail-pl1-f172.google.com (mail-pl1-f172.google.com [209.85.214.172]) by mx.groups.io with SMTP id smtpd.web10.8585.1695416712301770055 for ; Fri, 22 Sep 2023 14:05:12 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=CaAizWfE; spf=pass (domain: gmail.com, ip: 209.85.214.172, mailfrom: raj.khem@gmail.com) Received: by mail-pl1-f172.google.com with SMTP id d9443c01a7336-1c5c91bec75so24003105ad.3 for ; Fri, 22 Sep 2023 14:05:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695416711; x=1696021511; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=gtGa338KgBMnBXFLU30i0YJXMPGn/aqeZIU9vBHT37g=; b=CaAizWfEU1QgMt94IMOD0Fna48M8VHbTBTthhUJIp1QrV9YmfZsyP4gUNAMTSgcA0t 9OYcAw0pltJE/mr982WAMuqFH8hrHvbSCfgOq/aQvi/yetbtTOqg11V/0QDvv9nujqOg /plSJfhrzh4chHfWciwq+9IaYpjHuss+8nujRMfFz+XMNSnOTuktAcqICbDm7MvCSHxc 6kx+3KwZXBwojG21A7L8QvliBr3JoPoCaUg/wgGhy/kpEaJl4qDYAPpBrE5DVm/YfByN vrACvQD+Bous4D7tnIyNNYiXs9WaCehQWE7A0xXR9LMU+Z17+keNNL2ZL6BICnzP3aeg Dz/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695416711; x=1696021511; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=gtGa338KgBMnBXFLU30i0YJXMPGn/aqeZIU9vBHT37g=; b=Mc75sGy0CHhBxDm7rxWomC923rIfVdv8QkFpwVQi+u8nuhYFHem19l9Bh1AjcabzEE G+2ar03rn6dKQjoDtYrh04cybh2jZteNtRpGkUVZWPwb4t0z9eUWaQs4E2uc6hkMKxKY adQn8d8maWuTJsyjEAB/jt755hQM+/guGZUDuXwCfLlMyrEb5tVcPuO8z2AuVZuxEHUM WS+AIcpLnldWZ5NhP9TMeWLxY+WyatyA4d+fMcfcIKvMTcnszmHWr7RRIS32nd9dCZda ygmrlxORu8b7xYZOlA2GhJUU2xgWtV71cZgPkPsbYZDJcnqBamQECJrQgfT6Cg4T58eL ugmw== X-Gm-Message-State: AOJu0Yz3/c5TTtMZS1hPIZ1VdnHgkumLxOxblhKMO/kfiixgKPwe5T05 nJ+YfTjMJPvSPqBBiqPKJJd8J9F8QZTFGw== X-Google-Smtp-Source: AGHT+IFWwKqhkuEb662t/6FXLgOmhKAHtkwdnl5Dm685Q27z2UO8R7MX5bBd/vWXzg66k2CaqtHMgg== X-Received: by 2002:a17:903:112:b0:1c5:d185:8dba with SMTP id y18-20020a170903011200b001c5d1858dbamr468995plc.66.1695416711397; Fri, 22 Sep 2023 14:05:11 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:9100:2cb0::d373]) by smtp.gmail.com with ESMTPSA id u15-20020a170902e5cf00b001a5fccab02dsm3943623plf.177.2023.09.22.14.05.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 14:05:10 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Cc: Khem Raj Subject: [PATCH v3 1/5] musl: Update to latest Date: Fri, 22 Sep 2023 14:05:04 -0700 Message-ID: <20230922210508.24087-1-raj.khem@gmail.com> X-Mailer: git-send-email 2.42.0 MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 22 Sep 2023 21:05:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/188133 Brings following bug fixes * 79bdacff glob: fix wrong return code when aborting before any matches * 7291c6c6 statvfs: allocate spare for f_type * 39e43f08 math: fix ld80 powl(x,huge) and powl(LDBL_MAX,small) * 6d101027 math: fix ld80 acoshl(x) for x < 0 Drop MIRRORS and switch to etalabs.net for git fetch URI original repo is not working correcting with git Fetcher Signed-off-by: Khem Raj --- v3: Update SRC_URI to fetchable location meta/recipes-core/musl/musl_git.bb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/meta/recipes-core/musl/musl_git.bb b/meta/recipes-core/musl/musl_git.bb index 4a4fe978f93..7dd949ffafd 100644 --- a/meta/recipes-core/musl/musl_git.bb +++ b/meta/recipes-core/musl/musl_git.bb @@ -4,21 +4,17 @@ require musl.inc inherit linuxloader -SRCREV = "83b858f83b658bd34eca5d8ad4d145f673ae7e5e" +SRCREV = "79bdacff83a6bd5b70ff5ae5eb8b6de82c2f7c30" BASEVER = "1.2.4" PV = "${BASEVER}+git" -# mirror is at git://github.com/kraj/musl.git - -SRC_URI = "git://git.musl-libc.org/git/musl.git;branch=master;protocol=https \ +SRC_URI = "git://git.etalabs.net/git/musl;branch=master;protocol=https \ file://0001-Make-dynamic-linker-a-relative-symlink-to-libc.patch \ file://0002-ldso-Use-syslibdir-and-libdir-as-default-pathes-to-l.patch \ " -MIRRORS += "git://git.musl-libc.org/git/musl.git git://github.com/kraj/musl.git" - S = "${WORKDIR}/git" PROVIDES += "virtual/libc virtual/libiconv virtual/libintl virtual/crypt" From patchwork Fri Sep 22 21:05:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 31020 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2261ACE7A89 for ; Fri, 22 Sep 2023 21:05:17 +0000 (UTC) Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) by mx.groups.io with SMTP id smtpd.web10.8586.1695416713970602985 for ; Fri, 22 Sep 2023 14:05:14 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=CwLXnly9; spf=pass (domain: gmail.com, ip: 209.85.214.171, mailfrom: raj.khem@gmail.com) Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-1c47309a8ccso31029985ad.1 for ; Fri, 22 Sep 2023 14:05:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695416713; x=1696021513; darn=lists.openembedded.org; 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=zuK4yWURiWAd4/sBkwNpLdwd3Sm1EmOB7jDVqEOkTGg=; b=CwLXnly91D518qqVwvjgqno6c7Q3bID5fB97UnVTZmSxhFG+MpoV2f7kN4c+pP4yfz jzFPjgRw5kthZRNWouZr8Grg6Is9cZEGvjMcRkt1FYbwKsXPGJEAkuzOJpv5c51kEzCu jOarmqgzyacqEQzLBsruqYLKRr43IRLf7alNU1FFsBFHNiFUvmBcZubsqwqtIefAB5jH foMKQm99rvrwY/xjKwvqDg3/NtptOcMBrLlSm2ZxOXDVp/IQ9F2cwM34hbeI0G41wBZZ mRKM9HUHwXJ4R8WxPLBsuhnJnPTHAJvffkcbUDMyYNXqgJjyRhX7mJ/1GzT44BSmj+NW 57nA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695416713; x=1696021513; 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=zuK4yWURiWAd4/sBkwNpLdwd3Sm1EmOB7jDVqEOkTGg=; b=kKN9s/n/t73ib7Nd5I4/44lzAhHOFAQteSG3w7PCjUJpKiP8X9ImgY8MNNrTCP4++V dpxk4pfbbP25KbAVc91dp/hXFpoUaNQOUmOdug8nkl0kdIf/6K5/6SRQcpZTc1Hq/K7L +5Y6XLulsEk75Iw0+MagFLFwIAeJAv5LYbJvXZAfoyz8B56hK6QxEmwW2p6qbG1UeLHc zsACicwTL5n1SNJ2+/dCpfRKkQwBf7xcvBDmrjYakIRhWKDzw+GRn+ENbxfvbBrCvZ+P H3c+fN/OKfZun5PxjajMsx7XGBQvPQP63GZt8BgeVGvYrX1BcIGRQxtdqA4hPv6zR8Sy 2moQ== X-Gm-Message-State: AOJu0YxOV2IiTL5ENP4xGBFFeKDUN9Q7MrZGTyGF3fixSHeTwHtoFgIm AKEImgufCRSRHxGY+xg9rYafGj8fMNhJIQ== X-Google-Smtp-Source: AGHT+IFmrGKkNfQcJ3kQstrmwiTrPgAVYK98jlEAyBow1n5ZUNsywL9duEpxLKPa7oR/FMYdZXcFDg== X-Received: by 2002:a17:902:d2c6:b0:1c5:6f43:9502 with SMTP id n6-20020a170902d2c600b001c56f439502mr1024233plc.14.1695416713026; Fri, 22 Sep 2023 14:05:13 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:9100:2cb0::d373]) by smtp.gmail.com with ESMTPSA id u15-20020a170902e5cf00b001a5fccab02dsm3943623plf.177.2023.09.22.14.05.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 14:05:11 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Cc: Khem Raj Subject: [PATCH v3 2/5] bsd-headers: Define __CONCAT and __STRING Date: Fri, 22 Sep 2023 14:05:05 -0700 Message-ID: <20230922210508.24087-2-raj.khem@gmail.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20230922210508.24087-1-raj.khem@gmail.com> References: <20230922210508.24087-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 22 Sep 2023 21:05:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/188134 Sync with other musl distros Signed-off-by: Khem Raj --- v3: Rebased meta/recipes-core/musl/bsd-headers/sys-cdefs.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/meta/recipes-core/musl/bsd-headers/sys-cdefs.h b/meta/recipes-core/musl/bsd-headers/sys-cdefs.h index 209a623c0f0..841a5da8ba4 100644 --- a/meta/recipes-core/musl/bsd-headers/sys-cdefs.h +++ b/meta/recipes-core/musl/bsd-headers/sys-cdefs.h @@ -1,3 +1,6 @@ +#ifndef _SYS_CDEFS_H_ +#define _SYS_CDEFS_H_ + #warning usage of non-standard #include is deprecated #undef __P @@ -24,3 +27,8 @@ # define __THROW # define __NTH(fct) fct #endif + +#define __CONCAT(x,y) x ## y +#define __STRING(x) #x + +#endif /* _SYS_CDEFS_H_ */ From patchwork Fri Sep 22 21:05:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 31021 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1E8B2CE7A81 for ; Fri, 22 Sep 2023 21:05:17 +0000 (UTC) Received: from mail-pf1-f179.google.com (mail-pf1-f179.google.com [209.85.210.179]) by mx.groups.io with SMTP id smtpd.web10.8587.1695416715451812986 for ; Fri, 22 Sep 2023 14:05:15 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=SWnwFMvd; spf=pass (domain: gmail.com, ip: 209.85.210.179, mailfrom: raj.khem@gmail.com) Received: by mail-pf1-f179.google.com with SMTP id d2e1a72fcca58-690d2e13074so2571891b3a.1 for ; Fri, 22 Sep 2023 14:05:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695416715; x=1696021515; darn=lists.openembedded.org; 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=duVE5ww/fJzXBiO/obhwyd3U4Ii+9k7V2DW3/+1YIyU=; b=SWnwFMvd1JJu47oqk7+NbLIP3og6tnn+BTZW7N9N/pg9XOpJR0wo4eOHSZnisC8M8r jr6om8WkmaKY4LdDnoAaVbe2ajwrs1k9yPuSo4//pB/uHxsxmkJsgX1v6Mcw1aTRC2eN l6ZgTic16y6GRhqlejebtZzYiPPH8FSpEiJbBjcRSexlMF195lhAAyh2TjVlnGk9VCLS 8mJMvex5nBauN0PB4x/Oi3x0uUGWEw2DKXj/UPnSVZRZwXgIuUCE6qWEHl2q6FxB5aYh f3sIfSrady+ptu05gF7frXXWdLyXa/AtXKGcJfA0tcgq5RT2N2U02SWJyo8dQ+hjqjix NmVA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695416715; x=1696021515; 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=duVE5ww/fJzXBiO/obhwyd3U4Ii+9k7V2DW3/+1YIyU=; b=T3aKktQAWRezSG9aBLwmqWKslhsxCz6RVy7rcXjootJ5TcVLJDnWbS58zwC+kPrAkp nz7TE9LI7eDtUPBhhI00kcvQxjBkPBrXgASW5IORE+R5kjadhekwNGHT+4GukymysvI6 ns7DOmzCFtHFuMpa1mGfLFTOAxyyxqrzXoswAu6oFS8lqt8pVcIDPLfbCx+oxz1e7j6G EYjhNQtwy9/LivkadS1HSFwHXIx9+QHszXHmnXbHbMFEXLCpgbrm7yJUMMssqYfn6+of WBN/G9bfUunWdSCQDVFGWxSJvlytBy3RBxkcoRHTOB7wRhicCr5e75NnxKbZqJe+wfj9 DCgQ== X-Gm-Message-State: AOJu0YxlnFghKL8tSgB+e9EEDkYF2E0s+H3BAFHfc5vju0VJEE2y4sB+ m4wJK8znr6b2hd6o/ads4C3CSCK0V33L1w== X-Google-Smtp-Source: AGHT+IGJV2stIS4LcYrjLjTcDmL4vNM20l0f11UcGDe5lo4VABbagkO0FL12QI88gyoq+JvpIPLqew== X-Received: by 2002:a05:6a20:b29e:b0:14e:3ba7:2933 with SMTP id ei30-20020a056a20b29e00b0014e3ba72933mr545358pzb.54.1695416714609; Fri, 22 Sep 2023 14:05:14 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:9100:2cb0::d373]) by smtp.gmail.com with ESMTPSA id u15-20020a170902e5cf00b001a5fccab02dsm3943623plf.177.2023.09.22.14.05.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 14:05:13 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Cc: Khem Raj Subject: [PATCH v3 3/5] musl-legacy-error: Add recipe Date: Fri, 22 Sep 2023 14:05:06 -0700 Message-ID: <20230922210508.24087-3-raj.khem@gmail.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20230922210508.24087-1-raj.khem@gmail.com> References: <20230922210508.24087-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 22 Sep 2023 21:05:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/188135 This adds glibc error() API implementation which is needed by few packages still. Signed-off-by: Khem Raj --- v3: Added new meta/conf/distro/include/maintainers.inc | 1 + meta/recipes-core/musl/musl-legacy-error.bb | 26 ++++++++ .../musl/musl-legacy-error/error.h | 60 +++++++++++++++++++ 3 files changed, 87 insertions(+) create mode 100644 meta/recipes-core/musl/musl-legacy-error.bb create mode 100644 meta/recipes-core/musl/musl-legacy-error/error.h diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc index e977c84fc82..f69f229fc85 100644 --- a/meta/conf/distro/include/maintainers.inc +++ b/meta/conf/distro/include/maintainers.inc @@ -531,6 +531,7 @@ RECIPE_MAINTAINER:pn-mtd-utils = "Denys Dmytriyenko " RECIPE_MAINTAINER:pn-mtdev = "Anuj Mittal " RECIPE_MAINTAINER:pn-mtools = "Anuj Mittal " RECIPE_MAINTAINER:pn-musl = "Khem Raj " +RECIPE_MAINTAINER:pn-musl-legacy-error = "Khem Raj " RECIPE_MAINTAINER:pn-musl-locales = "Khem Raj " RECIPE_MAINTAINER:pn-musl-obstack = "Khem Raj " RECIPE_MAINTAINER:pn-musl-utils = "Khem Raj " diff --git a/meta/recipes-core/musl/musl-legacy-error.bb b/meta/recipes-core/musl/musl-legacy-error.bb new file mode 100644 index 00000000000..5ce5a233ab1 --- /dev/null +++ b/meta/recipes-core/musl/musl-legacy-error.bb @@ -0,0 +1,26 @@ +# Copyright (C) 2023 Khem Raj +# Released under the MIT license (see COPYING.MIT for the terms) + +SUMMARY = "error API GNU extention implementation" +LICENSE = "BSD-2-Clause" +LIC_FILES_CHKSUM = "file://error.h;beginline=1;md5=2ee396b23e8507fbf8f98af0471a77c6" +SECTION = "devel" + +SRC_URI = "file://error.h" + +do_configure[noexec] = "1" +do_compile[noexec] = "1" + +INHIBIT_DEFAULT_DEPS = "1" + +S = "${WORKDIR}" + +do_install() { + install -Dm 0644 ${S}/error.h -t ${D}${includedir} +} +# +# We will skip parsing for non-musl systems +# +COMPATIBLE_HOST = ".*-musl.*" +DEV_PKG_DEPENDENCY = "" +RRECOMMENDS:${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})" diff --git a/meta/recipes-core/musl/musl-legacy-error/error.h b/meta/recipes-core/musl/musl-legacy-error/error.h new file mode 100644 index 00000000000..9a4e1f8d006 --- /dev/null +++ b/meta/recipes-core/musl/musl-legacy-error/error.h @@ -0,0 +1,60 @@ +#ifndef _ERROR_H_ +#define _ERROR_H_ + +#include +#include +#include +#include +#include + +#warning usage of non-standard #include is deprecated + +static unsigned int error_message_count = 0; + +static inline void error(int status, int errnum, const char* format, ...) +{ + /* should be fflush(stdout), but that's unspecified if stdout has been closed; + * stick with fflush(NULL) for simplicity (glibc checks if the fd is still valid) */ + fflush(NULL); + + va_list ap; + fprintf(stderr, "%s: ", program_invocation_name); + va_start(ap, format); + vfprintf(stderr, format, ap); + va_end(ap); + if (errnum) + fprintf(stderr, ": %s", strerror(errnum)); + fprintf(stderr, "\n"); + error_message_count++; + if (status) + exit(status); +} + +static int error_one_per_line = 0; + +static inline void error_at_line(int status, int errnum, const char *filename, + unsigned int linenum, const char *format, ...) +{ + va_list ap; + if (error_one_per_line) { + static const char *old_filename; + static int old_linenum; + if (linenum == old_linenum && filename == old_filename) + return; + old_filename = filename; + old_linenum = linenum; + } + fprintf(stderr, "%s: %s:%u: ", program_invocation_name, filename, linenum); + va_start(ap, format); + vfprintf(stderr, format, ap); + va_end(ap); + if (errnum) + fprintf(stderr, ": %s", strerror(errnum)); + fprintf(stderr, "\n"); + error_message_count++; + if (status) + exit(status); +} + + +#endif /* _ERROR_H_ */ From patchwork Fri Sep 22 21:05:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 31023 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4103FCE7A8A for ; Fri, 22 Sep 2023 21:05:17 +0000 (UTC) Received: from mail-pf1-f177.google.com (mail-pf1-f177.google.com [209.85.210.177]) by mx.groups.io with SMTP id smtpd.web11.8652.1695416716628236798 for ; Fri, 22 Sep 2023 14:05:16 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=LFot0YTv; spf=pass (domain: gmail.com, ip: 209.85.210.177, mailfrom: raj.khem@gmail.com) Received: by mail-pf1-f177.google.com with SMTP id d2e1a72fcca58-692a885f129so1249815b3a.0 for ; Fri, 22 Sep 2023 14:05:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695416716; x=1696021516; darn=lists.openembedded.org; 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=6XGlLwqyZoq79Z/pbkTp2ov2XmH5lfeBLVaP/JxN9vY=; b=LFot0YTvO6Jph9NyuIH2IGi6OEiPV16/JfUGZPTZ5VbsDGVgMNcZd32RVaVl5lRGa7 tOKZ/EDZN4S+Aje8k4J097TEHM0UzcXjkTCuz5X8gkTz6yvJCd1EhjEtvPvOYwPdXLPi vPaUS/k8Mj4kYWrZwtKIm3IDD6AaGJ09B27sDGX8lAZgkoWofGg/QVhzr4kumFE6B8QC 82W6XiS1tZmBnqxWmTyemiczTpFgGBgpGoJ82t8Fz58M8F11UesNWmu9QDmsqJCOr2fk 5lLTg9tMYZ/l9b1h5yH65crmayUj7RDNXQtNB/VJVdkRFaweWAVGVkWaYI2dpoxNm4br Lo5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695416716; x=1696021516; 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=6XGlLwqyZoq79Z/pbkTp2ov2XmH5lfeBLVaP/JxN9vY=; b=Q32hJR+O1R1nTfeW8d68MKD1B0IR7qtmX5ietK8c08rbHjd+Zkpa2K+sAAeaumULjR 8wwNG5RKx2lrHSQ7PE4j4BTPS3nWwpUVJjLSUddRkbeEJTLEaxzbGVJOE1eqJ+Ls/MgI PpKL5i9vcuAe7giFiaer12dn+oggTa0RZcre36howidMBMFiYUQlcesGwAxrRzltH9Ie q5bbtXbI3T+XQWf4RYDQk2bSaOn8ytV1mVRxLG/4nB90U7iEnsKWCWjtV1Sb1ua8Mpe5 eapIqs0qQUd5JyH2gBw8RDzuphlCGTvZ1bMfLUjkV6v28AvspVgxrTWoKY4XQIk7QsZ1 yMKg== X-Gm-Message-State: AOJu0YzLTelg28o/QWcgR8kQoj3GxcJM7uuESg+bVk+q7iTz2l9dGc5I 6yB1P7Xelo/n1+GMxVsNae9jZiBoebspSg== X-Google-Smtp-Source: AGHT+IEjU7Wg4bI+YqkYSwLblwdzTT1/S2Lv/r5y3LXJA10l/H/sFHpe/IRhhFjFqJdr7Wj10qt5Yg== X-Received: by 2002:a05:6a20:3d8f:b0:159:b4ba:a5bf with SMTP id s15-20020a056a203d8f00b00159b4baa5bfmr921037pzi.13.1695416715703; Fri, 22 Sep 2023 14:05:15 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:9100:2cb0::d373]) by smtp.gmail.com with ESMTPSA id u15-20020a170902e5cf00b001a5fccab02dsm3943623plf.177.2023.09.22.14.05.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 14:05:15 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Cc: Khem Raj Subject: [PATCH 4/5] elfutils: Depend on musl-legacy-error for musl targets Date: Fri, 22 Sep 2023 14:05:07 -0700 Message-ID: <20230922210508.24087-4-raj.khem@gmail.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20230922210508.24087-1-raj.khem@gmail.com> References: <20230922210508.24087-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 22 Sep 2023 21:05:17 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/188136 this ensures a gnu compatible error APIs are made available, the patch to workaround this is no longer needed. Signed-off-by: Khem Raj --- v3: Added .../elfutils/elfutils_0.189.bb | 3 +- .../0015-config-eu.am-do-not-use-Werror.patch | 37 ------------------- 2 files changed, 1 insertion(+), 39 deletions(-) delete mode 100644 meta/recipes-devtools/elfutils/files/0015-config-eu.am-do-not-use-Werror.patch diff --git a/meta/recipes-devtools/elfutils/elfutils_0.189.bb b/meta/recipes-devtools/elfutils/elfutils_0.189.bb index d6352de5cf5..d8bf82b0229 100644 --- a/meta/recipes-devtools/elfutils/elfutils_0.189.bb +++ b/meta/recipes-devtools/elfutils/elfutils_0.189.bb @@ -7,7 +7,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \ file://debuginfod/debuginfod-client.c;endline=28;md5=f0a7c3170776866ee94e8f9225a6ad79 \ " DEPENDS = "zlib virtual/libintl" -DEPENDS:append:libc-musl = " argp-standalone fts musl-obstack " +DEPENDS:append:libc-musl = " argp-standalone fts musl-legacy-error musl-obstack" # The Debian patches below are from: # http://ftp.de.debian.org/debian/pool/main/e/elfutils/elfutils_0.176-1.debian.tar.xz SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \ @@ -24,7 +24,6 @@ SRC_URI = "https://sourceware.org/elfutils/ftp/${PV}/${BP}.tar.bz2 \ " SRC_URI:append:libc-musl = " \ file://0003-musl-utils.patch \ - file://0015-config-eu.am-do-not-use-Werror.patch \ " SRC_URI[sha256sum] = "39bd8f1a338e2b7cd4abc3ff11a0eddc6e690f69578a57478d8179b4148708c8" diff --git a/meta/recipes-devtools/elfutils/files/0015-config-eu.am-do-not-use-Werror.patch b/meta/recipes-devtools/elfutils/files/0015-config-eu.am-do-not-use-Werror.patch deleted file mode 100644 index 9ee5801c561..00000000000 --- a/meta/recipes-devtools/elfutils/files/0015-config-eu.am-do-not-use-Werror.patch +++ /dev/null @@ -1,37 +0,0 @@ -From c209233857a73970d7a7dd8da664903570efc7ea Mon Sep 17 00:00:00 2001 -From: Alexander Kanavin -Date: Mon, 22 Jun 2020 21:35:16 +0000 -Subject: [PATCH] config/eu.am: do not use -Werror - -Due to re-definition of error() on musl, gcc starts throwing -errors where none happen with glibc. Since upstream is not -likely to be interested in musl builds, lets just disable -Werror. - -Upstream-Status: Inappropriate [oe core specific] -Signed-off-by: Alexander Kanavin - ---- - config/eu.am | 2 -- - 1 file changed, 2 deletions(-) -diff --git a/config/eu.am b/config/eu.am -index e6c241f..4136e7c 100644 ---- a/config/eu.am -+++ b/config/eu.am -@@ -99,7 +99,6 @@ AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ - $(LOGICAL_OP_WARNING) $(DUPLICATED_COND_WARNING) \ - $(NULL_DEREFERENCE_WARNING) $(IMPLICIT_FALLTHROUGH_WARNING) \ - $(USE_AFTER_FREE3_WARNING) \ -- $(if $($(*F)_no_Werror),,-Werror) \ - $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ - $(if $($(*F)_no_Wstack_usage),,$(STACK_USAGE_WARNING)) \ - $(if $($(*F)_no_Wpacked_not_aligned),$(NO_PACKED_NOT_ALIGNED_WARNING),) \ -@@ -109,7 +108,6 @@ AM_CXXFLAGS = -std=c++11 -Wall -Wshadow \ - $(TRAMPOLINES_WARNING) \ - $(LOGICAL_OP_WARNING) $(DUPLICATED_COND_WARNING) \ - $(NULL_DEREFERENCE_WARNING) $(IMPLICIT_FALLTHROUGH_WARNING) \ -- $(if $($(*F)_no_Werror),,-Werror) \ - $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ - $(if $($(*F)_no_Wstack_usage),,$(STACK_USAGE_WARNING)) \ - $(if $($(*F)_no_Wpacked_not_aligned),$(NO_PACKED_NOT_ALIGNED_WARNING),) \ --- From patchwork Fri Sep 22 21:05:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 31024 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 353E6CE7A86 for ; Fri, 22 Sep 2023 21:05:27 +0000 (UTC) Received: from mail-pl1-f175.google.com (mail-pl1-f175.google.com [209.85.214.175]) by mx.groups.io with SMTP id smtpd.web10.8589.1695416718105804978 for ; Fri, 22 Sep 2023 14:05:18 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=kuIYgMkq; spf=pass (domain: gmail.com, ip: 209.85.214.175, mailfrom: raj.khem@gmail.com) Received: by mail-pl1-f175.google.com with SMTP id d9443c01a7336-1c3d6d88231so24269405ad.0 for ; Fri, 22 Sep 2023 14:05:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1695416717; x=1696021517; darn=lists.openembedded.org; 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=ggZjUOFBkgx3k/JWtcFIOSKxtSEEbPg+uxk7eusTDaE=; b=kuIYgMkq7NrlHCNCsNlDUdkRAaiksV3rmeDlZUJ8ILeCPadfDiUJjQpZNjTgPm2gYI 0hPCqMB79UcmSSpe/KxA6kFkdD4ZhAcn7Aadp44zLE4+M6u53NAj4QoLJPsPFKjhYnis PaRHhDsw1AM+r7PmVtRR3O+UxDN3ZP791WERzYkjcl1pG3u9SVrbsIPSsXRZwWtwjRuG AexXuQbOVYAGQy2JzeMttTEgQxTOZ+qJid/cgGIHh/IlecZT27rqyJ2HdtFljMIBnu9l fKzB0JdwtgS10x8wURRZI5Z4OkYU8CzOfys7vEEglh4CIRL6f0WbBKK35yQvHT/P0nEO Xsbg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695416717; x=1696021517; 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=ggZjUOFBkgx3k/JWtcFIOSKxtSEEbPg+uxk7eusTDaE=; b=JUdmlFXHvkf1MAV4eg1AfgwFdYL/HzBL26TRH5Ihy8Q55H0wuMI6fRQjN9gpmx1YP7 V/qNTQOKO/PVLaAt/06M9n/fXJPvaz17pf0UPq4qxtMN3aRW7O5tnZKRVjyN6RFRbgic tha0Qt9EXxNcsBVu+8sGQJPIo6zHvdCurfoApdhhXmaYJJLnVNapsRPf+IlH+wkg3GI8 /x5/QyWzKE3HNxeGdlbySCIZFUEFs87K0dRj/LoVScjoI85A6KFWuXyGebcU1LvngSPP yZUFJEQCYaJs2bZra+Gv1YFYUE0SSG4Rt9IuRX2dkihE64+VXVKVfO4tELQVOlO6Rzgl TA9Q== X-Gm-Message-State: AOJu0YwTalalB1kEmiHONd7L6bgB7fQ+GlCPeZyHcdQE5WNoxOUxdBJA Kq9PNzCFHUbP47zYtWwcI97eEl4mlc2QVQ== X-Google-Smtp-Source: AGHT+IEe0sOc0nLze+Y5oQ9fLUI37KmnHuZPz0U2PHMJb6dfu9SptB/TkgzYpxNMZDjqK567gIxbaA== X-Received: by 2002:a17:902:d4cb:b0:1b9:e9b2:124b with SMTP id o11-20020a170902d4cb00b001b9e9b2124bmr608729plg.64.1695416717303; Fri, 22 Sep 2023 14:05:17 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:9100:2cb0::d373]) by smtp.gmail.com with ESMTPSA id u15-20020a170902e5cf00b001a5fccab02dsm3943623plf.177.2023.09.22.14.05.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 14:05:16 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Cc: Khem Raj Subject: [PATCH 5/5] debugedit: Use musl-legacy-error Date: Fri, 22 Sep 2023 14:05:08 -0700 Message-ID: <20230922210508.24087-5-raj.khem@gmail.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20230922210508.24087-1-raj.khem@gmail.com> References: <20230922210508.24087-1-raj.khem@gmail.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Fri, 22 Sep 2023 21:05:27 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/188137 Use error.h to provide GNU extentions for error API Drop the patch trying to do something about it Signed-off-by: Khem Raj --- v3: Added .../debugedit/debugedit_5.0.bb | 4 +- ...tools-Add-error.h-for-non-glibc-case.patch | 102 ------------------ 2 files changed, 2 insertions(+), 104 deletions(-) delete mode 100644 meta/recipes-devtools/debugedit/files/0001-tools-Add-error.h-for-non-glibc-case.patch diff --git a/meta/recipes-devtools/debugedit/debugedit_5.0.bb b/meta/recipes-devtools/debugedit/debugedit_5.0.bb index 257238fa245..63ad7babd9a 100644 --- a/meta/recipes-devtools/debugedit/debugedit_5.0.bb +++ b/meta/recipes-devtools/debugedit/debugedit_5.0.bb @@ -11,8 +11,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \ SRC_URI = "https://sourceware.org/ftp/debugedit/${PV}/debugedit-${PV}.tar.xz" -SRC_URI:append:libc-musl = " \ - file://0001-tools-Add-error.h-for-non-glibc-case.patch \ +SRC_URI:append:libc-musl = "\ file://0002-sepdebugcrcfix.c-do-not-use-64bit-variants.patch \ file://0003-Makefile.am-do-not-update-manual.patch \ " @@ -20,6 +19,7 @@ SRC_URI:append:libc-musl = " \ SRC_URI[sha256sum] = "e9ecd7d350bebae1f178ce6776ca19a648b6fe8fa22f5b3044b38d7899aa553e" DEPENDS = "elfutils" +DEPENDS:append:libc-musl = " musl-legacy-error" inherit pkgconfig autotools diff --git a/meta/recipes-devtools/debugedit/files/0001-tools-Add-error.h-for-non-glibc-case.patch b/meta/recipes-devtools/debugedit/files/0001-tools-Add-error.h-for-non-glibc-case.patch deleted file mode 100644 index f6d64cb4e7d..00000000000 --- a/meta/recipes-devtools/debugedit/files/0001-tools-Add-error.h-for-non-glibc-case.patch +++ /dev/null @@ -1,102 +0,0 @@ -From 4c797d3b559ba51bd9ccd9a2036245819acce843 Mon Sep 17 00:00:00 2001 -From: Chen Qi -Date: Thu, 23 Mar 2023 10:54:21 +0800 -Subject: [PATCH] tools: Add error.h for non-glibc case - -error is glibc specific API, so this patch will mostly not accepted -upstream given that elfutils has been closely tied to glibc - -This is a OE specific workaround for musl. - -Upstream-Status: Inappropriate [OE Specific] - -Signed-off-by: Chen Qi ---- - tools/debugedit.c | 7 ++++++- - tools/error.h | 27 +++++++++++++++++++++++++++ - tools/sepdebugcrcfix.c | 7 ++++++- - 3 files changed, 39 insertions(+), 2 deletions(-) - create mode 100644 tools/error.h - -diff --git a/tools/debugedit.c b/tools/debugedit.c -index 668777a..a72c3c0 100644 ---- a/tools/debugedit.c -+++ b/tools/debugedit.c -@@ -25,7 +25,6 @@ - #include - #include - #include --#include - #include - #include - #include -@@ -40,6 +39,12 @@ - #include - #include - -+#ifdef __GLIBC__ -+#include -+#else -+#include "error.h" -+#endif -+ - #ifndef MAX - #define MAX(m, n) ((m) < (n) ? (n) : (m)) - #endif -diff --git a/tools/error.h b/tools/error.h -new file mode 100644 -index 0000000..9b24418 ---- /dev/null -+++ b/tools/error.h -@@ -0,0 +1,27 @@ -+#ifndef _ERROR_H_ -+#define _ERROR_H_ -+ -+#include -+#include -+#include -+#include -+#include -+ -+static unsigned int error_message_count = 0; -+ -+static inline void error(int status, int errnum, const char* format, ...) -+{ -+ va_list ap; -+ fprintf(stderr, "%s: ", program_invocation_name); -+ va_start(ap, format); -+ vfprintf(stderr, format, ap); -+ va_end(ap); -+ if (errnum) -+ fprintf(stderr, ": %s", strerror(errnum)); -+ fprintf(stderr, "\n"); -+ error_message_count++; -+ if (status) -+ exit(status); -+} -+ -+#endif /* _ERROR_H_ */ -diff --git a/tools/sepdebugcrcfix.c b/tools/sepdebugcrcfix.c -index da50e6c..c4a9d56 100644 ---- a/tools/sepdebugcrcfix.c -+++ b/tools/sepdebugcrcfix.c -@@ -29,10 +29,15 @@ - #include - #include - #include --#include - #include - #include - -+#ifdef __GLIBC__ -+#include -+#else -+#include "error.h" -+#endif -+ - #ifndef _ - #define _(x) x - #endif --- -2.17.1 -