libcpprestsdk: new package
PATCH v2 1/1 libcpprestsdk: new package
The C++ REST SDK is a Microsoft project for cloud-based client-server communication in native code using a modern asynchronous C++ API design. This project aims to help C++ developers connect to and interact with services.
This package is licensed under the MIT package and depends on BOOST and OpenSSL (although it is compatible with LibreSSL.)
---
Changes v1 -> v2:
- Add "depends on BR2_USE_WCHAR # boost" to boost.mk (Thomas)
- Remove "depends on BR2_USE_MMU" from boost.mk (Thomas)
- Add "!BR2_USE_WCHAR" to boost.mk (Thomas)
DEVELOPERS | 1 + package/Config.in | 1 + package/libcpprestsdk/Config.in | 23 +++++++++++++++++++++++ package/libcpprestsdk/libcpprestsdk.hash | 3 +++ package/libcpprestsdk/libcpprestsdk.mk | 20 ++++++++++++++++++++ 5 files changed, 48 insertions(+) create mode 100644 package/libcpprestsdk/Config.in create mode 100644 package/libcpprestsdk/libcpprestsdk.hash create mode 100644 package/libcpprestsdk/libcpprestsdk.mk
DEVELOPERS +1 -0
@@ -32,6 +32,7 @@ F: package/gstreamer1/gst1-rtsp-server/ N: Adam Duskett <[email protected]> F: package/audit/ F: package/checkpolicy/ +F: package/cpprestsdk/ F: package/gstreamer1/gst1-vaapi/ F: package/janus-gateway/ F: package/libressl/
package/Config.in +1 -0
@@ -1337,6 +1337,7 @@ menu "Networking" source "package/libcgi/Config.in" source "package/libcgicc/Config.in" source "package/libcoap/Config.in" + source "package/libcpprestsdk/Config.in" source "package/libcurl/Config.in" source "package/libdnet/Config.in" source "package/libeXosip2/Config.in"
package/libcpprestsdk/Config.in new file +23 -0
@@ -0,0 +1,23 @@ +config BR2_PACKAGE_LIBCPPRESTSDK + bool "libcpprestsdk" + depends on BR2_INSTALL_LIBSTDCPP # boost + depends on BR2_TOOLCHAIN_HAS_THREADS + depends on BR2_USE_WCHAR # boost + select BR2_PACKAGE_BOOST + select BR2_PACKAGE_BOOST_RANDOM + select BR2_PACKAGE_BOOST_CHRONO + select BR2_PACKAGE_BOOST_THREAD + select BR2_PACKAGE_BOOST_REGEX + select BR2_PACKAGE_BOOST_FILESYSTEM + select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_LIBRESSL + help + The C++ REST SDK is a Microsoft project for cloud-based + client-server communication in native code using a modern + asynchronous C++ API design. This project aims to help C++ + developers connect to and interact with services. + + https://github.com/Microsoft/cpprestsdk + +comment "libcpprestsdk needs a toolchain w/ C++, wchar, threads" + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS \ + || !BR2_USE_WCHAR
package/libcpprestsdk/libcpprestsdk.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally calculated +sha256 bef46381a036625d12d575d69ce9f3dd78b4317e41d1196b928dff83cc5a9c05 libcpprestsdk-v2.9.0.tar.gz +sha256 5c191789f502ac87df83b57008d2fc3e47fbf31315381b5bc4309f6602d0fe97 license.txt
package/libcpprestsdk/libcpprestsdk.mk new file +20 -0
@@ -0,0 +1,20 @@ +################################################################################ +# +# libcpprestsdk +# +################################################################################ + +LIBCPPRESTSDK_VERSION = v2.9.0 +LIBCPPRESTSDK_SITE = $(call github,Microsoft,cpprestsdk,$(LIBCPPRESTSDK_VERSION)) +LIBCPPRESTSDK_DEPENDENCIES = boost +LIBCPPRESTSDK_LICENSE = MIT +LIBCPPRESTSDK_LICENSE_FILES = license.txt +LIBCPPRESTSDK_SUBDIR = Release + +ifeq ($(BR2_PACKAGE_LIBRESSL),y) +LIBCPPRESTSDK_DEPENDENCIES += libressl +else +LIBCPPRESTSDK_DEPENDENCIES += openssl +endif + +$(eval $(cmake-package))
Signature · 1 line
2.13.6
PATCH v2 1/1 libcpprestsdk: new package
Hello,
package/libcpprestsdk/Config.in line 12
Quoted 1 line · Adam Duskett
package/libcpprestsdk/Config.in new file +1
-0+ select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_LIBRESSL
Meh:
package/openssl/Config.in:1: symbol BR2_PACKAGE_OPENSSL is selected by BR2_PACKAGE_LIBRESSL
package/libressl/Config.in:1: symbol BR2_PACKAGE_LIBRESSL depends on BR2_PACKAGE_OPENSSL
package/openssl/Config.in:1:error: recursive dependency detected!
package/openssl/Config.in:1: symbol BR2_PACKAGE_OPENSSL is selected by BR2_PACKAGE_LIBRESSL
package/libressl/Config.in:1: symbol BR2_PACKAGE_LIBRESSL depends on BR2_PACKAGE_OPENSSL
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com
PATCH v2 1/1 libcpprestsdk: new package
Quoted 8 lines · Thomas Petazzoni
Hello,
package/libcpprestsdk/Config.in line 12
Quoted 1 line · Adam Duskett
package/libcpprestsdk/Config.in new file +1
-0+ select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_LIBRESSLMeh:
Quoted 5 lines
package/openssl/Config.in:1: symbol
BR2_PACKAGE_OPENSSLis selected byBR2_PACKAGE_LIBRESSL
package/libressl/Config.in:1: symbolBR2_PACKAGE_LIBRESSLdepends onBR2_PACKAGE_OPENSSL
package/openssl/Config.in:1:error: recursive dependency detected!
package/openssl/Config.in:1: symbolBR2_PACKAGE_OPENSSLis selected byBR2_PACKAGE_LIBRESSL
package/libressl/Config.in:1: symbolBR2_PACKAGE_LIBRESSLdepends onBR2_PACKAGE_OPENSSL
Solved by inverting the select:
select BR2_PACKAGE_LIBRESSL if !BR2_PACKAGE_OPENSSL
But since we probably want to use openssl by default, not libressl, we should
perhaps instead invert the condition in the openssl/libressl packages. I.e., remove the depends from libressl, and add 'depends on !libressl' to openssl.
Or, of course, introduce the virtual package. So I've added that as a topic for
the developer meeting.
Regards,
Arnout
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH v2 1/1 libcpprestsdk: new package
In reply to Adam DuskettHello,
Quoted 9 lines · Adam Duskett
The C++ REST SDK is a Microsoft project for cloud-based client-server communication in native code using a modern asynchronous C++ API design. This project aims to help C++ developers connect to and interact with services.
This package is licensed under the MIT package and depends on BOOST and OpenSSL (although it is compatible with LibreSSL.)
Signed-off-by Adam Duskett <[email protected]>
It fails to build here, with:
/home/thomas/projets/buildroot/output/build/libcpprestsdk-v2.9.0/Release/include/cpprest/astreambuf.h: In member function ?pplx::task<_InternalReturnType> Concurrency::streams::details::streambuf_state_manager<_CharType>::create_exception_checked_value_task(const _CharType1&) const [with _CharType1 = int; _CharType = unsigned char]?:/home/thomas/projets/buildroot/output/build/libcpprestsdk-v2.9.0/Release/include/cpprest/astreambuf.h:748:9: error: control reaches end of non-void function [-Werror=return-type]
}
^
/home/thomas/projets/buildroot/output/build/libcpprestsdk-v2.9.0/Release/include/cpprest/astreambuf.h: In member function ?pplx::task<_InternalReturnType> Concurrency::streams::details::streambuf_state_manager<_CharType>::create_exception_checked_value_task(const _CharType1&) const [with _CharType1 = unsigned int; _CharType = char]?:
/home/thomas/projets/buildroot/output/build/libcpprestsdk-v2.9.0/Release/include/cpprest/astreambuf.h:748:9: error: control reaches end of non-void function [-Werror=return-type]
}
^[... many more instances of that ...]
Using this defconfig:
BR2_arm=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_CUSTOM=y
BR2_TOOLCHAIN_EXTERNAL_DOWNLOAD=y BR2_TOOLCHAIN_EXTERNAL_URL="http://autobuild.buildroot.org/toolchains/tarballs/br-arm-full-2017.05-1078-g95b1dae.tar.bz2" BR2_TOOLCHAIN_EXTERNAL_GCC_4_9=y
BR2_TOOLCHAIN_EXTERNAL_HEADERS_3_10=y
BR2_TOOLCHAIN_EXTERNAL_LOCALE=y
# BR2_TOOLCHAIN_EXTERNAL_HAS_THREADS_DEBUG is not set
BR2_TOOLCHAIN_EXTERNAL_CXX=y
BR2_INIT_NONE=y
BR2_SYSTEM_BIN_SH_NONE=y
# BR2_PACKAGE_BUSYBOX is not set
BR2_PACKAGE_LIBRESSL=y
BR2_PACKAGE_LIBCPPRESTSDK=y
# BR2_TARGET_ROOTFS_TAR is not set
You can catch such issues by using ./utils/test-pkg.
Note that I slightly adjusted your patch to accommodate the recent openssl changes. Here is the diff that I have:
package/libcpprestsdk/Config.in +3 -3
@@ -9,7 +9,7 @@ config BR2_PACKAGE_LIBCPPRESTSDK select BR2_PACKAGE_BOOST_THREAD select BR2_PACKAGE_BOOST_REGEX select BR2_PACKAGE_BOOST_FILESYSTEM - select BR2_PACKAGE_OPENSSL if !BR2_PACKAGE_LIBRESSL + select BR2_PACKAGE_OPENSSL help The C++ REST SDK is a Microsoft project for cloud-based client-server communication in native code using a modern
@@ -19,5 +19,5 @@ config BR2_PACKAGE_LIBCPPRESTSDK https://github.com/Microsoft/cpprestsdk comment "libcpprestsdk needs a toolchain w/ C++, wchar, threads" - depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS \ - || !BR2_USE_WCHAR + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS || \ + !BR2_USE_WCHAR
package/libcpprestsdk/libcpprestsdk.mk +1 -3
@@ -11,9 +11,7 @@ LIBCPPRESTSDK_LICENSE = MIT LIBCPPRESTSDK_LICENSE_FILES = license.txt LIBCPPRESTSDK_SUBDIR = Release -ifeq ($(BR2_PACKAGE_LIBRESSL),y) -LIBCPPRESTSDK_DEPENDENCIES += libressl -else +ifeq ($(BR2_PACKAGE_OPENSSL),y) LIBCPPRESTSDK_DEPENDENCIES += openssl endif
Could you include it in your next submission ?
Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com