Skip to content

Commit dac0acd

Browse files
committed
feat: add build of p-net from source if available
1 parent 19331dc commit dac0acd

File tree

3 files changed

+37
-0
lines changed

3 files changed

+37
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
p-net-sources-1.0.2-20250519.113257-21.zip
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# P-Net Yocto Files
2+
3+
Place source code of p-net in `p-net-sources.zip` here
4+
to build from a source dump.
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
SUMMARY = "P-Net Profinet communication stack"
2+
LICENSE = "GPL-3.0-or-later"
3+
LIC_FILES_CHKSUM = "file://CMakeLists.txt;beginline=1;endline=14;md5=aa7e6f963fad674b02c35dc8e9aa5519"
4+
SECTION = "libs"
5+
PROVIDES = "p-net"
6+
7+
SRC_URI = "file://p-net-sources-1.0.2-20250519.113257-21.zip"
8+
9+
# Require activation to use the official stack
10+
# since this requires available sources.
11+
DEFAULT_PREFERENCE = "-1"
12+
13+
S = "${WORKDIR}/p-net"
14+
15+
FILES:${PN}-dev += " \
16+
${prefix}/cmake/*.cmake \
17+
"
18+
19+
FILES:${PN} += " \
20+
${prefix}/share/profinet \
21+
"
22+
23+
# We need network access to get Osal
24+
EXTRA_OECMAKE += "-DFETCHCONTENT_FULLY_DISCONNECTED=OFF"
25+
do_configure[network] = "1"
26+
27+
# Disable the tests since build fail
28+
# when cross compiling due to test discovery
29+
# using GOOGLE_TEST_INDIVIDUAL
30+
EXTRA_OECMAKE += "-DBUILD_TESTING=OFF"
31+
32+
inherit pkgconfig cmake

0 commit comments

Comments
 (0)