meta-openembedded/meta-networking/recipes-connectivity/libiec61850/files/0002-serial_port_linux-Add-missing-include-sys-time.h.patch
Romain Naour 25b91b3d2b libiec61850: add recipe for libiec61850
IEC 61850 is an international standard for communication systems in
Substation Automation Systems (SAS) and management of Decentralized
Energy Resources (DER). It is seen as one of the communication
standards of the emerging Smart Grid.

Add two upstream patch fixing build issues with musl libc.

Enable the libiec61850 python binding (pyiec61850) that require a fix
to find the correct PYTHON_SITE_DIR path while cross-compiling.

Signed-off-by: Romain Naour <romain.naour@smile.fr>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2020-09-24 12:42:04 -07:00

33 lines
926 B
Diff

From 661405eb6066b67dfe51d5ff9635e29f86bdd238 Mon Sep 17 00:00:00 2001
From: Romain Naour <romain.naour@smile.fr>
Date: Tue, 7 Apr 2020 21:02:54 +0200
Subject: [PATCH] serial_port_linux: Add missing include sys/time.h
POSIX says `struct timeval` is defined if <sys/time.h> is included.
Adding this header allow to build against musl-libc.
Upstream status: Pending
https://github.com/mz-automation/libiec61850/pull/228
Signed-off-by: Romain Naour <romain.naour@smile.fr>
---
hal/serial/linux/serial_port_linux.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hal/serial/linux/serial_port_linux.c b/hal/serial/linux/serial_port_linux.c
index e6308c0..15e5794 100644
--- a/hal/serial/linux/serial_port_linux.c
+++ b/hal/serial/linux/serial_port_linux.c
@@ -29,6 +29,7 @@
#include <termios.h>
#include <fcntl.h>
#include <unistd.h>
+#include <sys/time.h>
#include "hal_serial.h"
#include "hal_time.h"
--
2.21.1