package/uvw: new package
PATCH v3 1/1 package/uvw: new package
A header-only libuv wrapper in C++.
A patch is added to enable in-tree build, which is checked and prevented by the package and fails the build.
---v2->v3: select libuv, depend on gcc7, and add comment on libuv.mk
--- DEVELOPERS | 1 + package/Config.in | 1 + package/libuv/libuv.mk | 2 ++ ...-CMakeLists.txt-allow-in-place-build.patch | 32 +++++++++++++++++++ package/uvw/Config.in | 19 +++++++++++ package/uvw/uvw.hash | 3 ++ package/uvw/uvw.mk | 15 +++++++++ 7 files changed, 73 insertions(+) create mode 100644 package/uvw/0001-CMakeLists.txt-allow-in-place-build.patch create mode 100644 package/uvw/Config.in create mode 100644 package/uvw/uvw.hash create mode 100644 package/uvw/uvw.mk
DEVELOPERS +1 -0
@@ -239,6 +239,7 @@ F: package/python* F: package/snmpclitools/ F: package/spdlog/ F: package/uftp/ +F: package/uvw/ F: package/zeromq/ N: Ash Charles <[email protected]>
package/Config.in +1 -0
@@ -1805,6 +1805,7 @@ endif source "package/tinycbor/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in" + source "package/uvw/Config.in" source "package/xapian/Config.in" endmenu
package/libuv/libuv.mk +2 -0
@@ -4,6 +4,8 @@ # ################################################################################ +# When bumping libuv, check if a new version of uvw is available +# and bump it too. LIBUV_VERSION = 1.33.1 LIBUV_SITE = $(call github,libuv,libuv,v$(LIBUV_VERSION)) LIBUV_DEPENDENCIES = host-pkgconf
package/uvw/0001-CMakeLists.txt-allow-in-place-build.patch new file +32 -0
@@ -0,0 +1,32 @@ +From 1d784a0067b7123971c834c77f4f137acca56ae6 Mon Sep 17 00:00:00 2001 +From: Asaf Kahlon <[email protected]> +Date: Fri, 25 Oct 2019 19:09:14 +0300 +Subject: [PATCH 1/1] CMakeLists.txt: allow in-tree build + +Signed-off-by: Asaf Kahlon <[email protected]> +--- + CMakeLists.txt | 8 -------- + 1 file changed, 8 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 9fc5538..4aaabf7 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -4,14 +4,6 @@ + + cmake_minimum_required(VERSION 3.2) + +-# +-# Building in-tree is not allowed (we take care of your craziness). +-# +- +-if(CMAKE_SOURCE_DIR STREQUAL CMAKE_BINARY_DIR) +- message(FATAL_ERROR "Prevented in-tree built. Please create a build directory outside of the source code and call cmake from there. Thank you.") +-endif() +- + # + # Project configuration + # +-- +2.20.1 +
package/uvw/Config.in new file +19 -0
@@ -0,0 +1,19 @@ +config BR2_PACKAGE_UVW + bool "uvw" + depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # libuv + depends on BR2_USE_MMU # libuv + depends on !BR2_STATIC_LIBS # libuv + depends on BR2_TOOLCHAIN_HAS_SYNC_4 # libuv + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # C++17 + select BR2_PACKAGE_LIBUV + help + Header-only, event based, tiny and easy to use + libuv wrapper in modern C++. + + https://github.com/skypjack/uvw + +comment "uvw needs a toolchain w/ NPTL, dynamic library, gcc >= 7" + depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || BR2_STATIC_LIBS + depends on BR2_USE_MMU + depends on BR2_TOOLCHAIN_HAS_SYNC_4 + depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_7
package/uvw/uvw.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally calculated +sha256 266a354f0c64a8e85f29b10f20f4d08a35bc1e8caa7cc94a8afecf9ca43f4442 uvw-2.2.0_libuv-v1.33.tar.gz +sha256 ea786619b4d1b2ba0a188e923111122dfefea1d01c86e37f9e8c80bdbc3ea400 LICENSE
package/uvw/uvw.mk new file +15 -0
@@ -0,0 +1,15 @@ +################################################################################ +# +# uvw +# +################################################################################ + +UVW_VERSION = 2.2.0_libuv-v1.33 +UVW_SITE = $(call github,skypjack,uvw,v$(UVW_VERSION)) +UVW_INSTALL_STAGING = YES +UVW_INSTALL_TARGET = NO +UVW_DEPENDENCIES = libuv +UVW_LICENSE = MIT +UVW_LICENSE_FILES = LICENSE + +$(eval $(cmake-package))
Signature · 1 line
2.20.1
PATCH v3 1/1 package/uvw: new package
Hello Asaf,
package/uvw/0001-CMakeLists.txt-allow-in-place-build.patch line 6
Quoted 12 lines · On Sat, 26 Oct 2019 16:38:44 +0300 Asaf Kahlon <[email protected]> wrote:
package/uvw/0001-CMakeLists.txt-allow-in-place-build.patch new file +6
-0@@ -0,0 +1,32 @@ +From 1d784a0067b7123971c834c77f4f137acca56ae6 Mon Sep 17 00:00:00 2001 +From: Asaf Kahlon <[email protected]> +Date: Fri, 25 Oct 2019 19:09:14 +0300 +Subject: [PATCH 1/1] CMakeLists.txt: allow in-tree build + +Signed-off-by: Asaf Kahlon <[email protected]>
Any reason for this instead of:
UVW_SUPPORTS_IN_SOURCE_BUILD = NO
?
Quoted 15 lines
package/uvw/Config.in new file +9
-0@@ -0,0 +1,19 @@ +config BR2_PACKAGE_UVW + bool "uvw" + depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # libuv + depends on BR2_USE_MMU # libuv + depends on !BR2_STATIC_LIBS # libuv + depends on BR2_TOOLCHAIN_HAS_SYNC_4 # libuv + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # C++17 + select BR2_PACKAGE_LIBUV + help
package/uvw/Config.in line 19
Quoted 10 lines
package/uvw/Config.in new file +10
-0+ Header-only, event based, tiny and easy to use + libuv wrapper in modern C++. + + https://github.com/skypjack/uvw + +comment "uvw needs a toolchain w/ NPTL, dynamic library, gcc >= 7" + depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || BR2_STATIC_LIBS + depends on BR2_USE_MMU + depends on BR2_TOOLCHAIN_HAS_SYNC_4 + depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_7
The gcc 7.x conditions should be OR'ed with the NPTL and dynamic library condition.
Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
PATCH v3 1/1 package/uvw: new package
Hello,
Quoted 21 lines · Thomas Petazzoni
Hello Asaf,
package/uvw/0001-CMakeLists.txt-allow-in-place-build.patch line 6
Quoted 12 lines · On Sat, 26 Oct 2019 16:38:44 +0300 Asaf Kahlon <[email protected]> wrote:
package/uvw/0001-CMakeLists.txt-allow-in-place-build.patch new file +6
-0@@ -0,0 +1,32 @@ +From 1d784a0067b7123971c834c77f4f137acca56ae6 Mon Sep 17 00:00:00 2001 +From: Asaf Kahlon <[email protected]> +Date: Fri, 25 Oct 2019 19:09:14 +0300 +Subject: [PATCH 1/1] CMakeLists.txt: allow in-tree build + +Signed-off-by: Asaf Kahlon <[email protected]>Any reason for this instead of:
Quoted 3 lines
UVW_SUPPORTS_IN_SOURCE_BUILD= NO?
Although I looked for something like this in Buildroot, I didn't find it and didn't
know this feature exists. Thanks :)
I sent a v4.
Quoted 31 lines
Quoted 17 lines
package/uvw/Config.in new file +9
-0@@ -0,0 +1,19 @@ +config BR2_PACKAGE_UVW + bool "uvw" + depends on BR2_TOOLCHAIN_HAS_THREADS_NPTL # libuv + depends on BR2_USE_MMU # libuv + depends on !BR2_STATIC_LIBS # libuv + depends on BR2_TOOLCHAIN_HAS_SYNC_4 # libuv + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_7 # C++17 + select BR2_PACKAGE_LIBUV + helppackage/uvw/Config.in line 19
Quoted 10 lines
package/uvw/Config.in new file +10
-0+ Header-only, event based, tiny and easy to use + libuv wrapper in modern C++. + + https://github.com/skypjack/uvw + +comment "uvw needs a toolchain w/ NPTL, dynamic library, gcc >= 7" + depends on !BR2_TOOLCHAIN_HAS_THREADS_NPTL || BR2_STATIC_LIBS + depends on BR2_USE_MMU + depends on BR2_TOOLCHAIN_HAS_SYNC_4 + depends on !BR2_TOOLCHAIN_GCC_AT_LEAST_7The gcc 7.x conditions should be OR'ed with the NPTL and dynamic library condition.
Quoted 7 lines
Thanks!
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
Regards,
Asaf.