mirror of
https://github.com/kernelkit/infix.git
synced 2026-07-22 01:13:00 +02:00
package/p-net: new package
Use ael fork with not-yet upstreamed fixes for now. Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com> Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
committed by
Joachim Wiberg
parent
04e646ab40
commit
23a25147cc
@@ -6,6 +6,9 @@ source "$BR2_EXTERNAL_INFIX_PATH/package/ifupdown2/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/ifupdown-ng/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/mdnsd/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/mech/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/osal/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/p-net/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/profeth/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/python-templating/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/skeleton-init-finit/Config.in"
|
||||
source "$BR2_EXTERNAL_INFIX_PATH/package/sysrepo-plugins-common/Config.in"
|
||||
|
||||
@@ -0,0 +1,13 @@
|
||||
config BR2_PACKAGE_OSAL
|
||||
bool "osal"
|
||||
depends on BR2_TOOLCHAIN_HAS_THREADS
|
||||
help
|
||||
This package contains an OS abstraction layer. The goal of
|
||||
the abstraction layer is to simplify writing software that
|
||||
runs on many platforms. This abstraction layer is mainly
|
||||
focused on threading functionality.
|
||||
|
||||
https://github.com/rtlabs-com/osal
|
||||
|
||||
comment "osal needs a toolchain w/ threads"
|
||||
depends on !BR2_TOOLCHAIN_HAS_THREADS
|
||||
@@ -0,0 +1,18 @@
|
||||
################################################################################
|
||||
#
|
||||
# osal
|
||||
#
|
||||
################################################################################
|
||||
|
||||
OSAL_VERSION = 0ab080859e3ba6d2b6d2fcac6f471d3c3d08d5f2
|
||||
OSAL_SITE_METHOD = git
|
||||
OSAL_SITE = https://github.com/rtlabs-com/osal
|
||||
OSAL_GIT_SUBMODULES = YES
|
||||
OSAL_INSTALL_STAGING = YES
|
||||
OSAL_LICENSE = BSD-3-Clause
|
||||
OSAL_LICENSE_FILES = LICENSE
|
||||
OSAL_SUPPORTS_IN_SOURCE_BUILD = NO
|
||||
OSAL_CONF_OPTS += \
|
||||
-DBUILD_SHARED_LIBS=true
|
||||
|
||||
$(eval $(cmake-package))
|
||||
@@ -0,0 +1,42 @@
|
||||
menuconfig BR2_PACKAGE_P_NET
|
||||
bool "p-net"
|
||||
depends on BR2_PACKAGE_NETSNMP_SERVER
|
||||
select BR2_PACKAGE_OSAL
|
||||
help
|
||||
The rt-labs PROFINET stack p-net is used for PROFINET device
|
||||
implementations. It is easy to use and provides a small
|
||||
footprint. It is especially well suited for embedded systems
|
||||
where resources are limited and efficiency is crucial.
|
||||
|
||||
It is written in C and can be run on bare-metal hardware, an
|
||||
RTOS such as rt-kernel, or on Linux or Windows. The main
|
||||
requirement is that the platform can send and receive RAW
|
||||
Ethernet Layer 2 frames. The p-net stack is supplied with
|
||||
full sources including a porting layer.
|
||||
|
||||
https://github.com/rtlabs-com/p-net
|
||||
|
||||
if BR2_PACKAGE_P_NET
|
||||
|
||||
config BR2_PACKAGE_P_NET_MAX_SLOTS
|
||||
int "PNET_MAX_SLOTS"
|
||||
default 5
|
||||
help
|
||||
Per API. Should be > 1 to allow at least one I/O module
|
||||
|
||||
config BR2_PACKAGE_P_NET_MAX_SUBSLOTS
|
||||
int "PNET_MAX_SUBSLOTS"
|
||||
default 3
|
||||
help
|
||||
Per slot (DAP requires 2 + PNET_MAX_PHYSICAL_PORTS)
|
||||
|
||||
config BR2_PACKAGE_P_NET_MAX_PHYSICAL_PORTS
|
||||
int "PNET_MAX_PHYSICAL_PORTS"
|
||||
default 1
|
||||
help
|
||||
Max number of physical ports
|
||||
|
||||
endif
|
||||
|
||||
comment "p-net needs the netsnmp server"
|
||||
depends on !BR2_PACKAGE_NETSNMP_SERVER
|
||||
@@ -0,0 +1,25 @@
|
||||
################################################################################
|
||||
#
|
||||
# p-net
|
||||
#
|
||||
################################################################################
|
||||
|
||||
#P_NET_VERSION = a55fce3f0872bad0254040d8fa344f6a35f64d78
|
||||
#P_NET_SITE = https://github.com/rtlabs-com/p-net
|
||||
P_NET_VERSION = 6e4bc6d1842970fb33469c8998e3b4d11ee4c0e6
|
||||
P_NET_SITE = https://github.com/addiva-elektronik/p-net
|
||||
P_NET_SITE_METHOD = git
|
||||
P_NET_GIT_SUBMODULES = YES
|
||||
P_NET_INSTALL_STAGING = YES
|
||||
P_NET_LICENSE = GPL-3.0
|
||||
P_NET_LICENSE_FILES = LICENSE.md
|
||||
P_NET_SUPPORTS_IN_SOURCE_BUILD = NO
|
||||
P_NET_DEPENDENCIES = osal netsnmp
|
||||
P_NET_CONF_OPTS += \
|
||||
-DBUILD_SHARED_LIBS=true \
|
||||
-DPNET_OPTION_SNMP=ON \
|
||||
-DPNET_MAX_SLOTS=$(BR2_PACKAGE_P_NET_MAX_SLOTS) \
|
||||
-DPNET_MAX_SUBSLOTS=$(BR2_PACKAGE_P_NET_MAX_SUBSLOTS) \
|
||||
-DPNET_MAX_PHYSICAL_PORTS=$(BR2_PACKAGE_P_NET_MAX_PHYSICAL_PORTS)
|
||||
|
||||
$(eval $(cmake-package))
|
||||
@@ -0,0 +1,14 @@
|
||||
config BR2_PACKAGE_PROFETH_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
depends on BR2_PACKAGE_P_NET
|
||||
depends on BR2_PACKAGE_NETSNMP_SERVER
|
||||
|
||||
config BR2_PACKAGE_PROFETH
|
||||
bool "profeth"
|
||||
depends on BR2_PACKAGE_PROFETH_SUPPORTED
|
||||
help
|
||||
Simple profinet switch management
|
||||
|
||||
comment "profeth needs p-net"
|
||||
depends on !BR2_PACKAGE_PROFETH_SUPPORTED
|
||||
@@ -0,0 +1,19 @@
|
||||
################################################################################
|
||||
#
|
||||
# profeth
|
||||
#
|
||||
################################################################################
|
||||
PROFETH_VERSION = 1.0
|
||||
PROFETH_LICENSE = GPL-3.0
|
||||
PROFETH_SITE_METHOD = local
|
||||
PROFETH_SITE = $(BR2_EXTERNAL_INFIX_PATH)/src/profeth
|
||||
PROFETH_DEPENDENCIES = p-net
|
||||
PROFETH_AUTORECONF = YES
|
||||
|
||||
define PROFETH_POST_RSYNC_INSTALL_OPTS
|
||||
@echo Installing generated options.h from p-net
|
||||
cp $(BUILD_DIR)/p-net*/buildroot-build/src/options.h $(@D)/src/options.h
|
||||
endef
|
||||
PROFETH_POST_RSYNC_HOOKS += PROFETH_POST_RSYNC_INSTALL_OPTS
|
||||
|
||||
$(eval $(autotools-package))
|
||||
Reference in New Issue
Block a user