From patchwork Mon Dec 15 10:04:56 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Duskett X-Patchwork-Id: 76516 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 E252FD5B173 for ; Mon, 15 Dec 2025 10:05:13 +0000 (UTC) Received: from mail-ej1-f50.google.com (mail-ej1-f50.google.com [209.85.218.50]) by mx.groups.io with SMTP id smtpd.msgproc01-g2.45212.1765793105012825365 for ; Mon, 15 Dec 2025 02:05:05 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=lxuGk12S; spf=pass (domain: amarulasolutions.com, ip: 209.85.218.50, mailfrom: adam.duskett@amarulasolutions.com) Received: by mail-ej1-f50.google.com with SMTP id a640c23a62f3a-b7a02deecccso56549466b.3 for ; Mon, 15 Dec 2025 02:05:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1765793103; x=1766397903; 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=6zk6gwaQfzuC7Z8mPtylj14JajUNqVWdxX4jr1MbhPI=; b=lxuGk12SDTSXxm6BF3/BbetQgN2f2gXAmDZmsL4TyL/9QIIP4RTZszwwxz43wpEz4V 3POQ6fTPND5c2fVzETWRiRCITHFLQ1oAvOtj6xYnvlA5/Gb2qiXD/W6WvDxaIhuZW4BN +QySOXDafljgivyw9/zl753ZAj68avIoZvTBw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1765793103; x=1766397903; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=6zk6gwaQfzuC7Z8mPtylj14JajUNqVWdxX4jr1MbhPI=; b=KbR1f+0kN69BYPOtfNuIMKN0nbye60e0YhDymVKdDgU2ZEABerPhEfn2B+ndvbjhdK 9cPHPABHGbmG/UE0RvtxmRBRvj8NohvZu8BiK4pq+E2aUA6NWMcmKopBto9vfVG7Toa0 nsH/EbrshLW9SbzzghruvmAXmW0iJGWlSI0vhEPEOXmQ3/bOYE7XE0uLykF0cFmAhRiH AaGOo2eUkZdvKrawh1644ufP4MdKPPpHca0vTkKfFOHOhpgutCRf4gnVv4a5tvM4ULTr wXba7WKZ7q57SLRP3u12nxL4VVuF72lLlY0uxwI+EVWHib9026UAhCZ0EzIPu07YBSht PyMg== X-Gm-Message-State: AOJu0YwTI1SbJb0pTA0Fn4OzhGTIXPGUzExiasyCi/hAuJOK5tEjA5l2 0iY1Zw6UTm4//BoYqRFwtir3MVFKApggAMTJlGrSS2We9ZTNQzZiEpOCFTwNNiztE3EaUtCxK9X eeSTD X-Gm-Gg: AY/fxX43ECNHCIE/1r0J/rJvAc4MP28h22TE7rB+Pq+Iy2wFDThQ/NQpeDS3mTyj0h9 TiVlTdrDQV9VpzJNrtyw6fntJR1HISrQEqCcDVPXc6rj9jwrFqmKsrwfV37N8YeE7kDd1dF2u6T hBPdJKijmiq1SL+USYeZx3w5LR4OuhnK2iyDHSrLKsizPdY8/K2b9rICGcws8pYR7yVL1tNTKYc 7SPAnkN8w5FQAE6Sv7nwVn6PYOuvF+GOCBENwTTJ7Y3IIsKgwIZ6I57UXR4cdO5EgaS0vbO1hiF u2YQrRi88OiYeVwiHu+0qUjDZSR8SwnofKRQm55E/SVOwpMqNwCXeIs1gSLIZ4qmi+9w8ofUcpR ZbRZ1eunby0RQV8DCMGwcWapIBtJI/amaXvHoga+AHHRZxM4D5fMd4P9SdFmG4OkyjziIXccRTZ aP8uM2thFF7svx67KZa56se6cx1eVCeMm3f20ey3fM5OcM2Lsh3CJvcel+Cxf1AhYKHHtPw93FW nLCkOgz9JdwLV+iIJEDCNp6B0EzO359lHze9aY202gtL2WFyN4srDrvqg== X-Google-Smtp-Source: AGHT+IEmlLG27D5SyoIZ/WG4/1tGOkm1G7I5+GUsbXV7169SZmnnBaPwG69S/cRxYLAgJUvZgqSTUg== X-Received: by 2002:a17:907:8693:b0:b76:2667:7736 with SMTP id a640c23a62f3a-b7d23b6fbd5mr635958266b.4.1765793103141; Mon, 15 Dec 2025 02:05:03 -0800 (PST) Received: from adam.amarulasolutions.com (2001-1c00-8101-1200-3ddc-5bb8-0efa-16f1.cable.dynamic.v6.ziggo.nl. [2001:1c00:8101:1200:3ddc:5bb8:efa:16f1]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-b7cfa57192bsm1336898366b.53.2025.12.15.02.05.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Dec 2025 02:05:02 -0800 (PST) From: Adam Duskett To: openembedded-core@lists.openembedded.org Cc: Adam Duskett Subject: [PATCH v3 2/6] libtoml: new recipe Date: Mon, 15 Dec 2025 11:04:56 +0100 Message-ID: <20251215100500.1626964-2-adam.duskett@amarulasolutions.com> X-Mailer: git-send-email 2.52.0 In-Reply-To: <20251215100500.1626964-1-adam.duskett@amarulasolutions.com> References: <20251215100500.1626964-1-adam.duskett@amarulasolutions.com> MIME-Version: 1.0 List-Id: X-Webhook-Received: from 45-33-107-173.ip.linodeusercontent.com [45.33.107.173] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Mon, 15 Dec 2025 10:05:13 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/227707 DNF5 requires libtoml. As such, copy libtoml verbatim from meta-openembedded to openembedded-core. Signed-off-by: Adam Duskett --- meta/conf/distro/include/maintainers.inc | 1 + .../distro/include/ptest-packagelists.inc | 1 + .../0001-Remove-whitespace-in-operator.patch | 46 +++++++++++++++++++ .../libtoml11/files/run-ptest | 12 +++++ .../libtoml11/libtoml11_4.4.0.bb | 38 +++++++++++++++ 5 files changed, 98 insertions(+) create mode 100644 meta/recipes-devtools/libtoml11/files/0001-Remove-whitespace-in-operator.patch create mode 100755 meta/recipes-devtools/libtoml11/files/run-ptest create mode 100644 meta/recipes-devtools/libtoml11/libtoml11_4.4.0.bb diff --git a/meta/conf/distro/include/maintainers.inc b/meta/conf/distro/include/maintainers.inc index 8971b9b552..da642ac3c5 100644 --- a/meta/conf/distro/include/maintainers.inc +++ b/meta/conf/distro/include/maintainers.inc @@ -405,6 +405,7 @@ RECIPE_MAINTAINER:pn-libsoup = "Unassigned " RECIPE_MAINTAINER:pn-libssh2 = "Unassigned " RECIPE_MAINTAINER:pn-libssp-nonshared = "Khem Raj " RECIPE_MAINTAINER:pn-libtasn1 = "Unassigned " +RECIPE_MAINTAINER:pn-libtoml11 = "Unassigned " RECIPE_MAINTAINER:pn-libtest-fatal-perl = "Tim Orling " RECIPE_MAINTAINER:pn-libtest-needs-perl = "Tim Orling " RECIPE_MAINTAINER:pn-libtest-warnings-perl = "Tim Orling " diff --git a/meta/conf/distro/include/ptest-packagelists.inc b/meta/conf/distro/include/ptest-packagelists.inc index 09613294d6..ec0e2d1637 100644 --- a/meta/conf/distro/include/ptest-packagelists.inc +++ b/meta/conf/distro/include/ptest-packagelists.inc @@ -40,6 +40,7 @@ PTESTS_FAST = "\ libtest-needs-perl \ libtest-warnings-perl \ libtimedate-perl \ + libtoml11 \ libtry-tiny-perl \ libusb1 \ libxml-namespacesupport-perl \ diff --git a/meta/recipes-devtools/libtoml11/files/0001-Remove-whitespace-in-operator.patch b/meta/recipes-devtools/libtoml11/files/0001-Remove-whitespace-in-operator.patch new file mode 100644 index 0000000000..c8c9922d55 --- /dev/null +++ b/meta/recipes-devtools/libtoml11/files/0001-Remove-whitespace-in-operator.patch @@ -0,0 +1,46 @@ +From dee78f822d8a5b985e565e5c1ef42a59557aa8fc Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Fri, 7 Mar 2025 11:35:46 -0800 +Subject: [PATCH] Remove whitespace in operator"" + +Clang 20+ errors about this whitespace. + +Fixes +include/toml11/impl/../fwd/literal_fwd.hpp:22:26: error: identifier '_toml' preceded by whitespace in a literal operator declaration is deprecated [-Werror,-Wdeprecated-literal-operator] +| 22 | ::toml::value operator"" _toml(const char* str, std::size_t len); +| | ~~~~~~~~~~~^~~~~ +| | operator""_toml + +Upstream-Status: Submitted [https://github.com/ToruNiina/toml11/pull/285] +Signed-off-by: Khem Raj +--- + include/toml11/fwd/literal_fwd.hpp | 2 +- + include/toml11/impl/literal_impl.hpp | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/include/toml11/fwd/literal_fwd.hpp b/include/toml11/fwd/literal_fwd.hpp +index e46612c..82f62b7 100644 +--- a/include/toml11/fwd/literal_fwd.hpp ++++ b/include/toml11/fwd/literal_fwd.hpp +@@ -19,7 +19,7 @@ inline namespace literals + inline namespace toml_literals + { + +-::toml::value operator"" _toml(const char* str, std::size_t len); ++::toml::value operator""_toml(const char* str, std::size_t len); + + #if defined(TOML11_HAS_CHAR8_T) + // value of u8"" literal has been changed from char to char8_t and char8_t is +diff --git a/include/toml11/impl/literal_impl.hpp b/include/toml11/impl/literal_impl.hpp +index e8298c2..067d4ed 100644 +--- a/include/toml11/impl/literal_impl.hpp ++++ b/include/toml11/impl/literal_impl.hpp +@@ -115,7 +115,7 @@ inline namespace toml_literals + { + + TOML11_INLINE ::toml::value +-operator"" _toml(const char* str, std::size_t len) ++operator""_toml(const char* str, std::size_t len) + { + if(len == 0) + { diff --git a/meta/recipes-devtools/libtoml11/files/run-ptest b/meta/recipes-devtools/libtoml11/files/run-ptest new file mode 100755 index 0000000000..9bc480aa7f --- /dev/null +++ b/meta/recipes-devtools/libtoml11/files/run-ptest @@ -0,0 +1,12 @@ +#!/bin/sh + +cd tests +for atest in test_* ; do + rm -rf tests.log + ./${atest} > tests.log 2>&1 + if [ $? = 0 ] ; then + echo "PASS: ${atest}" + else + echo "FAIL: ${atest}" + fi +done diff --git a/meta/recipes-devtools/libtoml11/libtoml11_4.4.0.bb b/meta/recipes-devtools/libtoml11/libtoml11_4.4.0.bb new file mode 100644 index 0000000000..38786b79ed --- /dev/null +++ b/meta/recipes-devtools/libtoml11/libtoml11_4.4.0.bb @@ -0,0 +1,38 @@ +SUMMARY = "TOML for Modern C++" +DESCRIPTION = "toml11 is a feature-rich TOML language library for \ + C++11/14/17/20." + +HOMEPAGE = "https://github.com/ToruNiina/toml11" + +SECTION = "libs" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=44d1fcf70c7aa6991533c38daf7befa3" + +PE = "1" + +SRCREV = "be08ba2be2a964edcdb3d3e3ea8d100abc26f286" +SRCREV_json = "8c391e04fe4195d8be862c97f38cfe10e2a3472e" +SRCREV_doctest = "ae7a13539fb71f270b87eb2e874fbac80bc8dda2" + +SRC_URI = "git://github.com/ToruNiina/toml11;branch=main;protocol=https \ + git://github.com/nlohmann/json;destsuffix=${BB_GIT_DEFAULT_DESTSUFFIX}/tests/extlib/json;name=json;branch=develop;protocol=https \ + git://github.com/doctest/doctest;destsuffix=${BB_GIT_DEFAULT_DESTSUFFIX}/tests/extlib/doctest;name=doctest;branch=master;protocol=https \ + file://0001-Remove-whitespace-in-operator.patch \ + file://run-ptest \ +" +SRCREV_FORMAT = "json_doctest" + + +inherit cmake ptest + +EXTRA_OECMAKE += "-DTOML11_PRECOMPILE=ON \ + -DTOML11_BUILD_TESTS=${@bb.utils.contains("DISTRO_FEATURES", "ptest", "ON", "OFF", d)} \ +" + +ALLOW_EMPTY:${PN} = "1" + +do_install_ptest () { + install -d ${D}${PTEST_PATH}/tests + cp -r ${B}/tests/test_* ${D}${PTEST_PATH}/tests +}