diff mbox series

package/libzenoh-pico: new package

Message ID AS1P250MB0608055A4067BEE19E37EAA4A9D4A@AS1P250MB0608.EURP250.PROD.OUTLOOK.COM
State Accepted
Headers show
Series package/libzenoh-pico: new package | expand

Commit Message

Michel Alex Oct. 19, 2023, 6:08 a.m. UTC
zenoh-pico is the Eclipse zenoh implementation that targets constrained
devices and offers a native C API. It is fully compatible with its main
Rust Zenoh implementation, providing a lightweight implementation of
most functionalities.

https://github.com/eclipse-zenoh/zenoh-pico

Signed-off-by: Alex Michel <alex.michel@wiedemann-group.com>
---
 package/Config.in                        |  1 +
 package/libzenoh-pico/Config.in          |  9 +++++++++
 package/libzenoh-pico/libzenoh-pico.hash |  3 +++
 package/libzenoh-pico/libzenoh-pico.mk   | 19 +++++++++++++++++++
 4 files changed, 32 insertions(+)
 create mode 100644 package/libzenoh-pico/Config.in
 create mode 100644 package/libzenoh-pico/libzenoh-pico.hash
 create mode 100644 package/libzenoh-pico/libzenoh-pico.mk

--
2.34.1

Comments

Thomas Petazzoni Nov. 1, 2023, 5:28 p.m. UTC | #1
Hello Alex,

Thanks a lot! I have applied your patch, after doing a number of
changes to fix issues. See below the details.

On Thu, 19 Oct 2023 06:08:07 +0000
Michel Alex <Alex.Michel@wiedemann-group.com> wrote:

> zenoh-pico is the Eclipse zenoh implementation that targets constrained
> devices and offers a native C API. It is fully compatible with its main
> Rust Zenoh implementation, providing a lightweight implementation of
> most functionalities.
> 
> https://github.com/eclipse-zenoh/zenoh-pico
> 
> Signed-off-by: Alex Michel <alex.michel@wiedemann-group.com>
> ---
>  package/Config.in                        |  1 +
>  package/libzenoh-pico/Config.in          |  9 +++++++++
>  package/libzenoh-pico/libzenoh-pico.hash |  3 +++
>  package/libzenoh-pico/libzenoh-pico.mk   | 19 +++++++++++++++++++
>  4 files changed, 32 insertions(+)

You forgot to add an entry in DEVELOPERS file.

> diff --git a/package/libzenoh-pico/Config.in b/package/libzenoh-pico/Config.in
> new file mode 100644
> index 0000000000..3baa76da3d
> --- /dev/null
> +++ b/package/libzenoh-pico/Config.in
> @@ -0,0 +1,9 @@
> +config BR2_PACKAGE_LIBZENOH_PICO
> +       bool "libzenoh-pico"
> +       help
> +         zenoh-pico is the Eclipse zenoh implementation that targets constrained
> +         devices and offers a native C API. It is fully compatible with its main
> +         Rust Zenoh implementation, providing a lightweight implementation of
> +         most functionalities.
> +
> +         https://github.com/eclipse-zenoh/zenoh-pico

There were some coding style issues in this file (indentation, mostly),
reported by "make check-package".

> diff --git a/package/libzenoh-pico/libzenoh-pico.hash b/package/libzenoh-pico/libzenoh-pico.hash
> new file mode 100644
> index 0000000000..edd4c3df4a
> --- /dev/null
> +++ b/package/libzenoh-pico/libzenoh-pico.hash
> @@ -0,0 +1,3 @@
> +# Locally computed
> +sha256  752acec56236fca41dcc438307f4a76e69900383b06803d47f32c480643dc794  zenoh-pico-0.10.0-rc.tar.gz

This didn't work: the tarball is named libzenoh-pico-0.10.0-rc.tar.gz,
not zenoh-pico-0.10.0-rc.tar.gz.

> +LIBZENOH_PICO_VERSION = 0.10.0-rc
> +LIBZENOH_PICO_SITE = $(call github,eclipse-zenoh,zenoh-pico,$(LIBZENOH_PICO_VERSION))
> +LIBZENOH_PICO_LICENSE = EPL-2.0

The license is actually Apache-2.0 or EPL-2.0

> +LIBZENOH_PICO_LICENSE_FILES = LICENSE
> +LIBZENOH_PICO_SUPPORTS_IN_SOURCE_BUILD = NO
> +LIBZENOH_PICO_INSTALL_STAGING = YES
> +
> +# - disable all examples
> +LIBZENOH_PICO_CONF_OPTS += \
> +       -DBUILD_EXAMPLES=OFF

This is not needed, as -DBUILD_EXAMPLES=OFF is always passed when
configuring CMake packages, by the cmake-package infrastructure in
package/pkg-cmake.mk.

> +
> +$(eval $(cmake-package))
> +

This final empty newline was causing another "make check-package"
complaint.

As said above: I fixed those issues, and applied to master. Thanks for
your contribution!

Best regards,

Thomas
diff mbox series

Patch

diff --git a/package/Config.in b/package/Config.in
index a53b7d29b5..077cf959d8 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1993,6 +1993,7 @@  menu "Networking"
        source "package/libwebsock/Config.in"
        source "package/libwebsockets/Config.in"
        source "package/libyang/Config.in"
+       source "package/libzenoh-pico/Config.in"
        source "package/lksctp-tools/Config.in"
        source "package/mbuffer/Config.in"
        source "package/mdnsd/Config.in"
diff --git a/package/libzenoh-pico/Config.in b/package/libzenoh-pico/Config.in
new file mode 100644
index 0000000000..3baa76da3d
--- /dev/null
+++ b/package/libzenoh-pico/Config.in
@@ -0,0 +1,9 @@ 
+config BR2_PACKAGE_LIBZENOH_PICO
+       bool "libzenoh-pico"
+       help
+         zenoh-pico is the Eclipse zenoh implementation that targets constrained
+         devices and offers a native C API. It is fully compatible with its main
+         Rust Zenoh implementation, providing a lightweight implementation of
+         most functionalities.
+
+         https://github.com/eclipse-zenoh/zenoh-pico
diff --git a/package/libzenoh-pico/libzenoh-pico.hash b/package/libzenoh-pico/libzenoh-pico.hash
new file mode 100644
index 0000000000..edd4c3df4a
--- /dev/null
+++ b/package/libzenoh-pico/libzenoh-pico.hash
@@ -0,0 +1,3 @@ 
+# Locally computed
+sha256  752acec56236fca41dcc438307f4a76e69900383b06803d47f32c480643dc794  zenoh-pico-0.10.0-rc.tar.gz
+sha256  d386df32cf327bbb25abe894277d3d7e0f447bafc59f4ad362615b0136f30db5  LICENSE
diff --git a/package/libzenoh-pico/libzenoh-pico.mk b/package/libzenoh-pico/libzenoh-pico.mk
new file mode 100644
index 0000000000..46d98a0a49
--- /dev/null
+++ b/package/libzenoh-pico/libzenoh-pico.mk
@@ -0,0 +1,19 @@ 
+################################################################################
+#
+# libzenoh-pico
+#
+################################################################################
+
+LIBZENOH_PICO_VERSION = 0.10.0-rc
+LIBZENOH_PICO_SITE = $(call github,eclipse-zenoh,zenoh-pico,$(LIBZENOH_PICO_VERSION))
+LIBZENOH_PICO_LICENSE = EPL-2.0
+LIBZENOH_PICO_LICENSE_FILES = LICENSE
+LIBZENOH_PICO_SUPPORTS_IN_SOURCE_BUILD = NO
+LIBZENOH_PICO_INSTALL_STAGING = YES
+
+# - disable all examples
+LIBZENOH_PICO_CONF_OPTS += \
+       -DBUILD_EXAMPLES=OFF
+
+$(eval $(cmake-package))
+