package/open62541: new package
PATCH 1/1 package/open62541: new package
From: Yann CARDAILLAC <[email protected]>
--- package/Config.in | 1 + package/open62541/Config.in | 62 ++++++++++++++++++++++++++++++++ package/open62541/open62541.hash | 3 ++ package/open62541/open62541.mk | 57 +++++++++++++++++++++++++++++ 4 files changed, 123 insertions(+) create mode 100644 package/open62541/Config.in create mode 100644 package/open62541/open62541.hash create mode 100644 package/open62541/open62541.mk
package/Config.in +1 -0
@@ -499,6 +499,7 @@ endmenu source "package/ofono/Config.in" source "package/on2-8170-modules/Config.in" source "package/open2300/Config.in" + source "package/open62541/Config.in" source "package/openipmi/Config.in" source "package/openocd/Config.in" source "package/openpowerlink/Config.in"
package/open62541/Config.in new file +62 -0
62 lines not on this page · raw message
package/open62541/open62541.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally calculated +sha256 766dc30dd7d27578560f7091f70f97d1edcbbdbea6ac0c33c6bc6df5e9daadc9 open62541-v1.0.tar.gz +sha256 fab3dd6bdab226f1c08630b1dd917e11fcb4ec5e1e020e2c16f83a0a13863e85 LICENSE
package/open62541/open62541.mk new file +57 -0
57 lines not on this page · raw message
Signature · 1 line
2.21.1
PATCH 1/1 package/open62541: new package
Hi,
I did a bit of work to simplify our integration of package.
Kubu gave me a bit of advices before posting the work once again.
Any feedback will be deeply appreciated.
However it might take me a bit of time to act on them.
Best regards,
Yann
----- Mail original -----
De: "Yann CARDAILLAC" <[email protected]>
?: "buildroot" <[email protected]>
Cc: "Yann CARDAILLAC" <[email protected]>, "romain naour" <[email protected]> Envoy?: Jeudi 16 Janvier 2020 23:05:39
Objet: [PATCH] package/open62541: new package
From: Yann CARDAILLAC <[email protected]>
--- package/Config.in | 1 + package/open62541/Config.in | 62 ++++++++++++++++++++++++++++++++ package/open62541/open62541.hash | 3 ++ package/open62541/open62541.mk | 57 +++++++++++++++++++++++++++++ 4 files changed, 123 insertions(+) create mode 100644 package/open62541/Config.in create mode 100644 package/open62541/open62541.hash create mode 100644 package/open62541/open62541.mk
package/Config.in +1 -0
@@ -499,6 +499,7 @@ endmenu source "package/ofono/Config.in" source "package/on2-8170-modules/Config.in" source "package/open2300/Config.in" + source "package/open62541/Config.in" source "package/openipmi/Config.in" source "package/openocd/Config.in" source "package/openpowerlink/Config.in"
package/open62541/Config.in new file +62 -0
62 lines not on this page · raw message
package/open62541/open62541.hash new file +3 -0
@@ -0,0 +1,3 @@ +# Locally calculated +sha256 766dc30dd7d27578560f7091f70f97d1edcbbdbea6ac0c33c6bc6df5e9daadc9 open62541-v1.0.tar.gz +sha256 fab3dd6bdab226f1c08630b1dd917e11fcb4ec5e1e020e2c16f83a0a13863e85 LICENSE
package/open62541/open62541.mk new file +57 -0
57 lines not on this page · raw message
Signature · 1 line
2.21.1
PATCH 1/1 package/open62541: new package
In reply to Yann CARDAILLACHi Yann,
Am Do., 16. Jan. 2020 um 23:05 Uhr schrieb Yann CARDAILLAC <[email protected]>:
Quoted 117 lines
From: Yann CARDAILLAC <[email protected]>
Signed-off-by Yann CARDAILLAC <[email protected]>Signed-off-by Romain Naour <[email protected]>--- package/Config.in | 1 + package/open62541/Config.in | 62 ++++++++++++++++++++++++++++++++ package/open62541/open62541.hash | 3 ++ package/open62541/open62541.mk | 57 +++++++++++++++++++++++++++++ 4 files changed, 123 insertions(+) create mode 100644 package/open62541/Config.in create mode 100644 package/open62541/open62541.hash create mode 100644 package/open62541/open62541.mkpackage/Config.in +1
-0@@ -499,6 +499,7 @@ endmenu source "package/ofono/Config.in" source "package/on2-8170-modules/Config.in" source "package/open2300/Config.in" + source "package/open62541/Config.in" source "package/openipmi/Config.in" source "package/openocd/Config.in" source "package/openpowerlink/Config.in"package/open62541/Config.in new file +62
-0@@ -0,0 +1,62 @@ +config BR2_PACKAGE_OPEN62541 + bool "open62541" + help + open62541 is an open source and free implementation of OPC UA + + http://open62541.org + +if BR2_PACKAGE_OPEN62541 + +choice + prompt "choose UA_NAMESPACE_ZERO" + +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_NONE + bool "NONE" + help + Don't set the UA_NAMESPACE_ZERO. + +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_MINIMAL + bool "MINIMAL" + help + A barebones namespace zero that is compatible with most + clients. But this namespace 0 is so small that it does + not pass the CTT + (Conformance Testing Tools of the OPC Foundation). + +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED + bool "REDUCED" + help + Small namespace zero that passes the CTT. + +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL + bool "FULL" + help + Full namespace zero generated from the official XML + definitions. + +endchoice + +menu "Advanced build options" + +config BR2_PACKAGE_OPEN62541_JSON_ENCODING + bool "json encoding" + +config BR2_PACKAGE_OPEN62541_PUBSUB + bool "publish/subscribe" + +config BR2_PACKAGE_OPEN62541_PUBSUB_DELTAFRAMES + bool "publish/subscribe deltaframes" + +config BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL + bool "publish/subscribe informationmodel" + depends on BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED || BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL + select BR2_PACKAGE_OPEN62541_PUBSUB + +config BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL_METHODS + bool "publish/subscribe informationmodel methods" + depends on BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED || BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL + select BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL + +endmenu + +endifpackage/open62541/open62541.hash new file +3
-0@@ -0,0 +1,3 @@ +# Locally calculated +sha256 766dc30dd7d27578560f7091f70f97d1edcbbdbea6ac0c33c6bc6df5e9daadc9 open62541-v1.0.tar.gz +sha256 fab3dd6bdab226f1c08630b1dd917e11fcb4ec5e1e020e2c16f83a0a13863e85 LICENSEpackage/open62541/open62541.mk new file +7
-0@@ -0,0 +1,57 @@ +################################################################################ +# +# open62541 +# +################################################################################ + +OPEN62541_VERSION = v1.0
package/open62541/open62541.mk line 17
Quoted 10 lines
package/open62541/open62541.mk new file +10
-0+OPEN62541_SITE_METHOD = git +OPEN62541_SITE = git://github.com/open62541/open62541.git +OPEN62541_GIT_SUBMODULES = YES +OPEN62541_INSTALL_STAGING = YES +OPEN62541_LICENSE = MPL-2.0 +OPEN62541_LICENSE_FILES = LICENSE + +# Don't use git discribe to get the version number. +OPEN62541_CONF_OPTS += -DGIT_EXECUTABLE=NO \ + -DOPEN62541_VERSION=$(OPEN62541_VERSION)
I think you should not use the '+' for the first time.
On the other hand I tried to build the package with a compiler without c++ suport and it fails.
I just did a 'make defconfig', 'make menuconfig' with selecting the open62541 package and it fails.
At least there seems to be a missing 'C' in the CMakefile.txt.
CMakeLists.txt +1 -1
@@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.0...3.12) -project(open62541) +project(open62541 C) # set(CMAKE_VERBOSE_MAKEFILE ON) if(${CMAKE_VERSION} VERSION_LESS 3.12) cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
But then it fails with an missing compiler option (ssp).
Should we even support building on c only compiler?
--
Heiko
Quoted 46 lines
package/open62541/open62541.mk new file +39
-1+ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_MINIMAL),y) +OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=MINIMAL +else ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED),y) +OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=REDUCED +else ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL),y) +OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=FULL +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_JSON_ENCODING),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_JSON_ENCODING=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_JSON_ENCODING=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_DELTAFRAMES),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_DELTAFRAMES=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_DELTAFRAMES=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL_METHODS),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL_METHODS=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL_METHODS=OFF +endif + +$(eval $(cmake-package)) --2.21.1
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
PATCH 1/1 package/open62541: new package
Hi Heiko, Yann, All,
Le 03/02/2020 ? 17:05, Heiko Thiery a ?crit?:
Quoted 10 lines
Hi Yann,
Am Do., 16. Jan. 2020 um 23:05 Uhr schrieb Yann CARDAILLAC <[email protected]>:
Quoted 6 lines
From: Yann CARDAILLAC <[email protected]>
Signed-off-by Yann CARDAILLAC <[email protected]>Signed-off-by Romain Naour <[email protected]>---
[...]
Quoted 44 lines
Quoted 13 lines
package/open62541/open62541.mk new file +7
-0@@ -0,0 +1,57 @@ +################################################################################ +# +# open62541 +# +################################################################################ + +OPEN62541_VERSION = v1.0package/open62541/open62541.mk line 17
Quoted 10 lines
package/open62541/open62541.mk new file +10
-0+OPEN62541_SITE_METHOD = git +OPEN62541_SITE = git://github.com/open62541/open62541.git +OPEN62541_GIT_SUBMODULES = YES +OPEN62541_INSTALL_STAGING = YES +OPEN62541_LICENSE = MPL-2.0 +OPEN62541_LICENSE_FILES = LICENSE + +# Don't use git discribe to get the version number. +OPEN62541_CONF_OPTS += -DGIT_EXECUTABLE=NO \ + -DOPEN62541_VERSION=$(OPEN62541_VERSION)I think you should not use the '+' for the first time.
On the other hand I tried to build the package with a compiler without c++ suport and it fails.
I just did a 'make defconfig', 'make menuconfig' with selecting the open62541 package and it fails.At least there seems to be a missing 'C' in the CMakefile.txt.
CMakeLists.txt +1
-1@@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.0...3.12) -project(open62541) +project(open62541 C) # set(CMAKE_VERBOSE_MAKEFILE ON) if(${CMAKE_VERSION} VERSION_LESS 3.12) cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
Quoted 3 lines
But then it fails with an missing compiler option (ssp).
Should we even support building on c only compiler?
Thanks for the review.
By default, the ssp support is not enabled when you build a toolchain. But the hardening option of this package (UA_ENABLE_HARDENING) is enabled by default, so it add several hardening option even if the toolchain doesn't support it.
I would suggest to disable it from the package (-DUA_ENABLE_HARDENING=OFF) and let Buildroot (and its toolchain wrapper) handling the hardening support.
Best regards,
Romain
Quoted 5 lines
--
Heiko
PATCH 1/1 package/open62541: new package
In reply to Yann CARDAILLACHello,
Quoted 4 lines · On Thu, 16 Jan 2020 23:05:39 +0100 Yann CARDAILLAC <[email protected]>…
From: Yann CARDAILLAC <[email protected]>
Signed-off-by Yann CARDAILLAC <[email protected]>Signed-off-by Romain Naour <[email protected]>
Your patch was about to be one year old, so it was time to act and apply it, which is now done, with a number of changes. See below.
Quoted 6 lines
--- package/Config.in | 1 + package/open62541/Config.in | 62 ++++++++++++++++++++++++++++++++ package/open62541/open62541.hash | 3 ++ package/open62541/open62541.mk | 57 +++++++++++++++++++++++++++++ 4 files changed, 123 insertions(+)
I've added an entry in the DEVELOPERS file.
package/Config.in endmenu · line 502
Quoted 9 lines
package/Config.in +1
-0@@ -499,6 +499,7 @@ endmenu source "package/ofono/Config.in" source "package/on2-8170-modules/Config.in" source "package/open2300/Config.in" + source "package/open62541/Config.in"
You added it in the Hardware section, I believe it belongs better to the Networking libraries part, so I moved it there.
package/Config.in endmenu
Quoted 4 lines
package/Config.in +4
-0+if BR2_PACKAGE_OPEN62541 + +choice + prompt "choose UA_NAMESPACE_ZERO"
Changed to:
+ prompt "namespace zero nodes"
and added a help text:
+ help
+ Namespace zero contains the standard-defined nodes. The full
+ namespace zero may not be required for all applications.
package/Config.in
Quoted 5 lines
package/Config.in +5
-0+ +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_NONE + bool "NONE" + help + Don't set the UA_NAMESPACE_ZERO.
Changed to:
+config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_DEFAULT
+ bool "default"
+ help
+ Use the default namespace zero contents.
package/Config.in
Quoted 3 lines
package/Config.in +3
-0+ +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_MINIMAL + bool "MINIMAL"
Changed to lower case.
package/Config.in
Quoted 8 lines
package/Config.in +8
-0+ help + A barebones namespace zero that is compatible with most + clients. But this namespace 0 is so small that it does + not pass the CTT + (Conformance Testing Tools of the OPC Foundation). + +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED + bool "REDUCED"
Changed to lower case.
package/Config.in
Quoted 5 lines
package/Config.in +5
-0+ help + Small namespace zero that passes the CTT. + +config BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL + bool "FULL"
Changed to lower case.
package/Config.in
Quoted 13 lines
package/Config.in +13
-0+ help + Full namespace zero generated from the official XML + definitions. + +endchoice + +menu "Advanced build options" + +config BR2_PACKAGE_OPEN62541_JSON_ENCODING + bool "json encoding" + +config BR2_PACKAGE_OPEN62541_PUBSUB + bool "publish/subscribe"
I've added a help text.
package/Config.in
Quoted 2 lines
package/Config.in +2
-0+config BR2_PACKAGE_OPEN62541_PUBSUB_DELTAFRAMES + bool "publish/subscribe deltaframes"
I've added a help text.
package/Config.in
Quoted 4 lines
package/Config.in +4
-0+config BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL + bool "publish/subscribe informationmodel" + depends on BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED || BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL + select BR2_PACKAGE_OPEN62541_PUBSUB
Dropped this select, and instead moved the pubsub options in a if BR2_PACKAGE_OPEN62541_PUBSUB ... endif block. Also added a help text.
package/Config.in
Quoted 4 lines
package/Config.in +4
-0+config BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL_METHODS + bool "publish/subscribe informationmodel methods" + depends on BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED || BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL + select BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL
I dropped this option, because it's not even documented in the open62541 manual, so I couldn't add some reasonable help text. We can always re-add it later if you submit a patch with more details.
package/open62541/open62541.mk line 7
Quoted 13 lines
package/open62541/open62541.mk new file +7
-0@@ -0,0 +1,57 @@ +################################################################################ +# +# open62541 +# +################################################################################ + +OPEN62541_VERSION = v1.0
Changed to:
+OPEN62541_VERSION = 1.0
+OPEN62541_DL_VERSION = v$(OPEN62541_VERSION)
so that the _VERSION variable doesn't have the "v" prefix.
package/open62541/open62541.mk line 17
Quoted 10 lines
package/open62541/open62541.mk new file +10
-0+OPEN62541_SITE_METHOD = git +OPEN62541_SITE = git://github.com/open62541/open62541.git +OPEN62541_GIT_SUBMODULES = YES +OPEN62541_INSTALL_STAGING = YES +OPEN62541_LICENSE = MPL-2.0 +OPEN62541_LICENSE_FILES = LICENSE + +# Don't use git discribe to get the version number. +OPEN62541_CONF_OPTS += -DGIT_EXECUTABLE=NO \ + -DOPEN62541_VERSION=$(OPEN62541_VERSION)
Changed to:
+# Don't use git describe to get the version number. +# Disable hardening options to let Buildroot handle it. +OPEN62541_CONF_OPTS = \
+ -DGIT_EXECUTABLE=NO \ + -DOPEN62541_VERSION=$(OPEN62541_VERSION) \ + -DUA_ENABLE_HARDENING=OFF
i.e: fix the typo on discribe -> describe, replace += by =, and daded the UA_ENABLE_HARDENING=OFF option as suggested by Romain.
Quoted 27 lines
package/open62541/open62541.mk new file +27
-0+ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_MINIMAL),y) +OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=MINIMAL +else ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_REDUCED),y) +OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=REDUCED +else ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_FULL),y) +OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=FULL +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_JSON_ENCODING),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_JSON_ENCODING=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_JSON_ENCODING=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_DELTAFRAMES),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_DELTAFRAMES=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_DELTAFRAMES=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL),y)
package/open62541/open62541.mk line 55
Quoted 10 lines
package/open62541/open62541.mk new file +10
-0+OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL=OFF +endif + +ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_INFORMATIONMODEL_METHODS),y) +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL_METHODS=ON +else +OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_INFORMATIONMODEL_METHODS=OFF +endif
Dropped this last chunk, as I dropped the option.
Also, added a patch suggested by Heiko that removes the need for a C++ compiler.
Do not hesitate to have a look at
https://git.buildroot.org/buildroot/commit/?id=b36ea68b5ad0f89ffd92cac3f91654e180683b1c
for the final result. If there are build failures in the next days, you'll receive an e-mail about such build failures.
Thanks for your contribution!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com