All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support
@ 2023-12-20 20:55 Alex Kiernan
  2023-12-21  0:35 ` [oe] " Khem Raj
  2023-12-27  8:21 ` Khem Raj
  0 siblings, 2 replies; 4+ messages in thread
From: Alex Kiernan @ 2023-12-20 20:55 UTC (permalink / raw)
  To: openembedded-devel; +Cc: Alex Kiernan

Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
---

Changes in v2:
- Use relative path to arestest

 .../recipes-support/c-ares/c-ares/run-ptest   |  7 +++++++
 .../recipes-support/c-ares/c-ares_1.24.0.bb   | 19 ++++++++++++++-----
 2 files changed, 21 insertions(+), 5 deletions(-)
 create mode 100644 meta-oe/recipes-support/c-ares/c-ares/run-ptest

diff --git a/meta-oe/recipes-support/c-ares/c-ares/run-ptest b/meta-oe/recipes-support/c-ares/c-ares/run-ptest
new file mode 100644
index 000000000000..15971dec058c
--- /dev/null
+++ b/meta-oe/recipes-support/c-ares/c-ares/run-ptest
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+if ./arestest; then
+	echo "PASS: c-ares"
+else
+	echo "FAIL: c-ares"
+fi
diff --git a/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb b/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
index 2171002aa95e..3b3b2b83febc 100644
--- a/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
+++ b/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
@@ -5,14 +5,23 @@ SECTION = "libs"
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://LICENSE.md;md5=fdbc58a6da11a9f68aa73c453818decc"
 
-SRC_URI = "git://github.com/c-ares/c-ares.git;branch=main;protocol=https"
-SRCREV = "972f456f2808b4e4b1730c90ab506f6af5f4c725"
+SRC_URI = "https://c-ares.org/download/c-ares-1.24.0.tar.gz \
+           file://run-ptest"
+SRC_URI[sha256sum] = "c517de6d5ac9cd55a9b72c1541c3e25b84588421817b5f092850ac09a8df5103"
 
-UPSTREAM_CHECK_GITTAGREGEX = "cares-(?P<pver>\d+_(\d_?)+)"
+PACKAGECONFIG ?= "${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)}"
+PACKAGECONFIG[manpages] = ""
+PACKAGECONFIG[tests] = "-DCARES_BUILD_TESTS=ON,-DCARES_BUILD_TESTS=OFF,googletest"
 
-S = "${WORKDIR}/git"
+inherit cmake manpages pkgconfig ptest
 
-inherit cmake pkgconfig
+EXTRA_OECMAKE = "-DCARES_STATIC=${@ 'ON' if d.getVar('DISABLE_STATIC') == '' else 'OFF' }"
+
+do_install_ptest () {
+	install -d ${D}${PTEST_PATH}
+	install -m 0755 ${B}/bin/arestest ${D}${PTEST_PATH}
+	install -m 0755 ${WORKDIR}/run-ptest ${D}${PTEST_PATH}
+}
 
 PACKAGE_BEFORE_PN = "${PN}-utils"
 
-- 
2.39.0



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [oe] [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support
  2023-12-20 20:55 [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support Alex Kiernan
@ 2023-12-21  0:35 ` Khem Raj
  2023-12-21  9:02   ` Alex Kiernan
  2023-12-27  8:21 ` Khem Raj
  1 sibling, 1 reply; 4+ messages in thread
From: Khem Raj @ 2023-12-21  0:35 UTC (permalink / raw)
  To: Alex Kiernan, openembedded-devel


[-- Attachment #1.1.1: Type: text/plain, Size: 2946 bytes --]

On 12/20/23 12:55 PM, Alex Kiernan wrote:
> Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
> ---
> 
> Changes in v2:
> - Use relative path to arestest
> 
>   .../recipes-support/c-ares/c-ares/run-ptest   |  7 +++++++
>   .../recipes-support/c-ares/c-ares_1.24.0.bb   | 19 ++++++++++++++-----
>   2 files changed, 21 insertions(+), 5 deletions(-)
>   create mode 100644 meta-oe/recipes-support/c-ares/c-ares/run-ptest
> 
> diff --git a/meta-oe/recipes-support/c-ares/c-ares/run-ptest b/meta-oe/recipes-support/c-ares/c-ares/run-ptest
> new file mode 100644
> index 000000000000..15971dec058c
> --- /dev/null
> +++ b/meta-oe/recipes-support/c-ares/c-ares/run-ptest
> @@ -0,0 +1,7 @@
> +#!/bin/sh
> +
> +if ./arestest; then
> +	echo "PASS: c-ares"
> +else
> +	echo "FAIL: c-ares"
> +fi

I wonder if it could be added to regular runs with ptest images and 
therefore added to PTESTS_FAST_META_OE ( if it runs with in 30s ) or 
PTESTS_SLOW_META_OE in meta-oe/conf/include/ptest-packagelists-meta-oe.inc

> diff --git a/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb b/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
> index 2171002aa95e..3b3b2b83febc 100644
> --- a/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
> +++ b/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
> @@ -5,14 +5,23 @@ SECTION = "libs"
>   LICENSE = "MIT"
>   LIC_FILES_CHKSUM = "file://LICENSE.md;md5=fdbc58a6da11a9f68aa73c453818decc"
>   
> -SRC_URI = "git://github.com/c-ares/c-ares.git;branch=main;protocol=https"
> -SRCREV = "972f456f2808b4e4b1730c90ab506f6af5f4c725"
> +SRC_URI = "https://c-ares.org/download/c-ares-1.24.0.tar.gz \
> +           file://run-ptest"
> +SRC_URI[sha256sum] = "c517de6d5ac9cd55a9b72c1541c3e25b84588421817b5f092850ac09a8df5103"
>   
> -UPSTREAM_CHECK_GITTAGREGEX = "cares-(?P<pver>\d+_(\d_?)+)"
> +PACKAGECONFIG ?= "${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)}"
> +PACKAGECONFIG[manpages] = ""
> +PACKAGECONFIG[tests] = "-DCARES_BUILD_TESTS=ON,-DCARES_BUILD_TESTS=OFF,googletest"
>   
> -S = "${WORKDIR}/git"
> +inherit cmake manpages pkgconfig ptest
>   
> -inherit cmake pkgconfig
> +EXTRA_OECMAKE = "-DCARES_STATIC=${@ 'ON' if d.getVar('DISABLE_STATIC') == '' else 'OFF' }"
> +
> +do_install_ptest () {
> +	install -d ${D}${PTEST_PATH}
> +	install -m 0755 ${B}/bin/arestest ${D}${PTEST_PATH}
> +	install -m 0755 ${WORKDIR}/run-ptest ${D}${PTEST_PATH}
> +}
>   
>   PACKAGE_BEFORE_PN = "${PN}-utils"
>   
> 
> 
> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#107672): https://lists.openembedded.org/g/openembedded-devel/message/107672
> Mute This Topic: https://lists.openembedded.org/mt/103288852/1997914
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
> 

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 2613 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 203 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [oe] [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support
  2023-12-21  0:35 ` [oe] " Khem Raj
@ 2023-12-21  9:02   ` Alex Kiernan
  0 siblings, 0 replies; 4+ messages in thread
From: Alex Kiernan @ 2023-12-21  9:02 UTC (permalink / raw)
  To: Khem Raj; +Cc: openembedded-devel

On Thu, Dec 21, 2023 at 12:35 AM Khem Raj <raj.khem@gmail.com> wrote:
>
> On 12/20/23 12:55 PM, Alex Kiernan wrote:
> > Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
> > ---
> >
> > Changes in v2:
> > - Use relative path to arestest
> >
> >   .../recipes-support/c-ares/c-ares/run-ptest   |  7 +++++++
> >   .../recipes-support/c-ares/c-ares_1.24.0.bb   | 19 ++++++++++++++-----
> >   2 files changed, 21 insertions(+), 5 deletions(-)
> >   create mode 100644 meta-oe/recipes-support/c-ares/c-ares/run-ptest
> >
> > diff --git a/meta-oe/recipes-support/c-ares/c-ares/run-ptest b/meta-oe/recipes-support/c-ares/c-ares/run-ptest
> > new file mode 100644
> > index 000000000000..15971dec058c
> > --- /dev/null
> > +++ b/meta-oe/recipes-support/c-ares/c-ares/run-ptest
> > @@ -0,0 +1,7 @@
> > +#!/bin/sh
> > +
> > +if ./arestest; then
> > +     echo "PASS: c-ares"
> > +else
> > +     echo "FAIL: c-ares"
> > +fi
>
> I wonder if it could be added to regular runs with ptest images and
> therefore added to PTESTS_FAST_META_OE ( if it runs with in 30s ) or
> PTESTS_SLOW_META_OE in meta-oe/conf/include/ptest-packagelists-meta-oe.inc
>

Probably PTESTS_SLOW_META_OE - it's about a minute (I suspect mostly
because there are timeout tests in there). Also the "live" tests fail
if you just do it inside a default runqemu because we have no default
resolv.conf there.

That said it'd be nice to get this tested - I'll have a look at it
(possibly a nice Christmas project!)

> > diff --git a/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb b/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
> > index 2171002aa95e..3b3b2b83febc 100644
> > --- a/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
> > +++ b/meta-oe/recipes-support/c-ares/c-ares_1.24.0.bb
> > @@ -5,14 +5,23 @@ SECTION = "libs"
> >   LICENSE = "MIT"
> >   LIC_FILES_CHKSUM = "file://LICENSE.md;md5=fdbc58a6da11a9f68aa73c453818decc"
> >
> > -SRC_URI = "git://github.com/c-ares/c-ares.git;branch=main;protocol=https"
> > -SRCREV = "972f456f2808b4e4b1730c90ab506f6af5f4c725"
> > +SRC_URI = "https://c-ares.org/download/c-ares-1.24.0.tar.gz \
> > +           file://run-ptest"
> > +SRC_URI[sha256sum] = "c517de6d5ac9cd55a9b72c1541c3e25b84588421817b5f092850ac09a8df5103"
> >
> > -UPSTREAM_CHECK_GITTAGREGEX = "cares-(?P<pver>\d+_(\d_?)+)"
> > +PACKAGECONFIG ?= "${@bb.utils.contains('PTEST_ENABLED', '1', 'tests', '', d)}"
> > +PACKAGECONFIG[manpages] = ""
> > +PACKAGECONFIG[tests] = "-DCARES_BUILD_TESTS=ON,-DCARES_BUILD_TESTS=OFF,googletest"
> >
> > -S = "${WORKDIR}/git"
> > +inherit cmake manpages pkgconfig ptest
> >
> > -inherit cmake pkgconfig
> > +EXTRA_OECMAKE = "-DCARES_STATIC=${@ 'ON' if d.getVar('DISABLE_STATIC') == '' else 'OFF' }"
> > +
> > +do_install_ptest () {
> > +     install -d ${D}${PTEST_PATH}
> > +     install -m 0755 ${B}/bin/arestest ${D}${PTEST_PATH}
> > +     install -m 0755 ${WORKDIR}/run-ptest ${D}${PTEST_PATH}
> > +}
> >
> >   PACKAGE_BEFORE_PN = "${PN}-utils"
> >
> >
> >
> >
> > -=-=-=-=-=-=-=-=-=-=-=-
> > Links: You receive all messages sent to this group.
> > View/Reply Online (#107672): https://lists.openembedded.org/g/openembedded-devel/message/107672
> > Mute This Topic: https://lists.openembedded.org/mt/103288852/1997914
> > Group Owner: openembedded-devel+owner@lists.openembedded.org
> > Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [raj.khem@gmail.com]
> > -=-=-=-=-=-=-=-=-=-=-=-
> >



-- 
Alex Kiernan


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support
  2023-12-20 20:55 [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support Alex Kiernan
  2023-12-21  0:35 ` [oe] " Khem Raj
@ 2023-12-27  8:21 ` Khem Raj
  1 sibling, 0 replies; 4+ messages in thread
From: Khem Raj @ 2023-12-27  8:21 UTC (permalink / raw)
  To: openembedded-devel, Alex Kiernan


On Wed, 20 Dec 2023 20:55:18 +0000, Alex Kiernan wrote:
> 


Applied, thanks!

[1/1] c-ares: Move to tarballs, add ptest and static support
      commit: 0fbbc0b1cce405ec6e005d8585627b503a140a6a

Best regards,
-- 
Khem Raj <raj.khem@gmail.com>



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-12-27  8:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-12-20 20:55 [meta-oe][PATCH v2] c-ares: Move to tarballs, add ptest and static support Alex Kiernan
2023-12-21  0:35 ` [oe] " Khem Raj
2023-12-21  9:02   ` Alex Kiernan
2023-12-27  8:21 ` Khem Raj

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.