2020-01-16 23:05:39 +01:00
|
|
|
################################################################################
|
|
|
|
#
|
|
|
|
# open62541
|
|
|
|
#
|
|
|
|
################################################################################
|
|
|
|
|
2023-12-12 13:01:50 +01:00
|
|
|
OPEN62541_VERSION = v1.3.9
|
2020-01-16 23:05:39 +01:00
|
|
|
OPEN62541_SITE_METHOD = git
|
2022-04-01 23:56:53 +02:00
|
|
|
OPEN62541_SITE = https://github.com/open62541/open62541.git
|
2020-01-16 23:05:39 +01:00
|
|
|
OPEN62541_GIT_SUBMODULES = YES
|
|
|
|
OPEN62541_INSTALL_STAGING = YES
|
|
|
|
OPEN62541_LICENSE = MPL-2.0
|
|
|
|
OPEN62541_LICENSE_FILES = LICENSE
|
2022-01-14 23:09:54 +01:00
|
|
|
OPEN62541_CPE_ID_VENDOR = open62541
|
2020-01-16 23:05:39 +01:00
|
|
|
|
2021-01-28 20:46:19 +01:00
|
|
|
# Force Release build to remove -Werror.
|
2020-01-16 23:05:39 +01:00
|
|
|
# Don't use git describe to get the version number.
|
|
|
|
# Disable hardening options to let Buildroot handle it.
|
|
|
|
OPEN62541_CONF_OPTS = \
|
2021-01-28 20:46:19 +01:00
|
|
|
-DCMAKE_BUILD_TYPE=Release \
|
2020-01-16 23:05:39 +01:00
|
|
|
-DGIT_EXECUTABLE=NO \
|
2021-07-26 07:01:51 +02:00
|
|
|
-DOPEN62541_VERSION=$(OPEN62541_VERSION) \
|
2021-08-02 09:58:41 +02:00
|
|
|
-DUA_ENABLE_HARDENING=OFF \
|
|
|
|
-DUA_FORCE_WERROR=OFF
|
2020-01-16 23:05:39 +01:00
|
|
|
|
2022-06-15 18:17:52 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_OPEN62541_ENCRYPTION_MBEDTLS),y)
|
|
|
|
OPEN62541_DEPENDENCIES += mbedtls
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_ENCRYPTION=MBEDTLS
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_OPEN62541_ENCRYPTION_OPENSSL),y)
|
|
|
|
OPEN62541_DEPENDENCIES += openssl
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_ENCRYPTION=OPENSSL
|
|
|
|
endif
|
|
|
|
|
2020-01-16 23:05:39 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_OPEN62541_UA_NAMESPACE_ZERO_MINIMAL),y)
|
2022-07-22 13:00:08 +02:00
|
|
|
OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=MINIMAL -DUA_ENABLE_SUBSCRIPTIONS_EVENTS=OFF
|
2020-01-16 23:05:39 +01:00
|
|
|
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)
|
2021-11-29 23:14:51 +01:00
|
|
|
OPEN62541_CONF_OPTS += -DUA_NAMESPACE_ZERO=FULL
|
2020-01-16 23:05:39 +01:00
|
|
|
endif
|
|
|
|
|
2022-06-15 18:17:50 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_OPEN62541_HISTORIZING),y)
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_HISTORIZING=ON
|
|
|
|
else
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_HISTORIZING=OFF
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_OPEN62541_DISCOVERY),y)
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_DISCOVERY=ON
|
|
|
|
else
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_DISCOVERY=OFF
|
|
|
|
endif
|
|
|
|
|
2020-01-16 23:05:39 +01:00
|
|
|
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
|
|
|
|
|
2022-06-15 18:17:51 +02:00
|
|
|
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
|
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_OPEN62541_PUBSUB_ETH_UADP),y)
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_ETH_UADP=ON
|
|
|
|
else
|
|
|
|
OPEN62541_CONF_OPTS += -DUA_ENABLE_PUBSUB_ETH_UADP=OFF
|
|
|
|
endif
|
|
|
|
|
2021-02-22 06:39:52 +01:00
|
|
|
# Remove unneeded files
|
|
|
|
define OPEN62541_REMOVE_UNNEEDED_FILES
|
|
|
|
$(RM) -r $(TARGET_DIR)/usr/share/open62541
|
|
|
|
endef
|
|
|
|
|
|
|
|
OPEN62541_POST_INSTALL_TARGET_HOOKS += OPEN62541_REMOVE_UNNEEDED_FILES
|
|
|
|
|
2020-01-16 23:05:39 +01:00
|
|
|
$(eval $(cmake-package))
|