[oe-commits] [meta-openembedded] 05/06: gensio: new package

git at git.openembedded.org git at git.openembedded.org
Tue Feb 25 23:53:56 UTC 2020


This is an automated email from the git hooks/post-receive script.

khem pushed a commit to branch master-next
in repository meta-openembedded.

commit 8266ed2e7898ad493d1e81e2074f02acb598ed69
Author: Pierre-Jean Texier <pjtexier at koncepto.io>
AuthorDate: Sun Feb 23 20:47:50 2020 +0000

    gensio: new package
    
    Signed-off-by: Pierre-Jean Texier <pjtexier at koncepto.io>
    Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
 ...filter-Rename-some-variables-to-tr_stdxxx.patch | 108 +++++++++++++++++++++
 .../recipes-connectivity/gensio/gensio_1.5.3.bb    |  27 ++++++
 2 files changed, 135 insertions(+)

diff --git a/meta-oe/recipes-connectivity/gensio/gensio/0001-filter-Rename-some-variables-to-tr_stdxxx.patch b/meta-oe/recipes-connectivity/gensio/gensio/0001-filter-Rename-some-variables-to-tr_stdxxx.patch
new file mode 100644
index 0000000..dbc48a2
--- /dev/null
+++ b/meta-oe/recipes-connectivity/gensio/gensio/0001-filter-Rename-some-variables-to-tr_stdxxx.patch
@@ -0,0 +1,108 @@
+From 601e6e56f44b91d957bb643662455f52540f336a Mon Sep 17 00:00:00 2001
+From: Corey Minyard <cminyard at mvista.com>
+Date: Tue, 25 Feb 2020 16:08:40 -0600
+Subject: [PATCH] filter: Rename some variables to tr_stdxxx
+
+stdout and stderr can be macros, don't use the names directly.
+
+Signed-off-by: Corey Minyard <cminyard at mvista.com>
+Upstream-Status: Backport [https://github.com/cminyard/gensio/commit/601e6e56f44b91d957bb643662455f52540f336a]
+Signed-off-by: Pierre-Jean Texier <pjtexier at koncepto.io>
+---
+ lib/gensio_filter_trace.c | 28 ++++++++++++++--------------
+ 1 file changed, 14 insertions(+), 14 deletions(-)
+
+diff --git a/lib/gensio_filter_trace.c b/lib/gensio_filter_trace.c
+index d39d58b..abe2db6 100644
+--- a/lib/gensio_filter_trace.c
++++ b/lib/gensio_filter_trace.c
+@@ -32,8 +32,8 @@ struct trace_filter {
+     enum trace_dir dir;
+     bool raw;
+     char *filename;
+-    bool stdout;
+-    bool stderr;
++    bool tr_stdout;
++    bool tr_stderr;
+ 
+     FILE *tr;
+ };
+@@ -82,9 +82,9 @@ trace_try_connect(struct gensio_filter *filter, struct timeval *timeout)
+ {
+     struct trace_filter *tfilter = filter_to_trace(filter);
+ 
+-    if (tfilter->stdout) {
++    if (tfilter->tr_stdout) {
+ 	tfilter->tr = stdout;
+-    } else if (tfilter->stderr) {
++    } else if (tfilter->tr_stderr) {
+ 	tfilter->tr = stderr;
+     } else if (tfilter->filename) {
+ 	tfilter->tr = fopen(tfilter->filename, "a+");
+@@ -99,7 +99,7 @@ trace_try_disconnect(struct gensio_filter *filter, struct timeval *timeout)
+ {
+     struct trace_filter *tfilter = filter_to_trace(filter);
+ 
+-    if (!tfilter->stdout && !tfilter->stderr && tfilter->tr)
++    if (!tfilter->tr_stdout && !tfilter->tr_stderr && tfilter->tr)
+ 	fclose(tfilter->tr);
+     tfilter->tr = NULL;
+     return 0;
+@@ -331,12 +331,12 @@ static int gensio_trace_filter_func(struct gensio_filter *filter, int op,
+ 
+ static struct gensio_filter *
+ gensio_trace_filter_raw_alloc(struct gensio_os_funcs *o, enum trace_dir dir,
+-			      bool raw, const char *filename, bool stdout,
+-			      bool stderr)
++			      bool raw, const char *filename, bool tr_stdout,
++			      bool tr_stderr)
+ {
+     struct trace_filter *tfilter;
+ 
+-    if (!filename && !stdout && !stderr)
++    if (!filename && !tr_stdout && !tr_stderr)
+ 	dir = TRACE_NONE;
+ 
+     tfilter = o->zalloc(o, sizeof(*tfilter));
+@@ -351,8 +351,8 @@ gensio_trace_filter_raw_alloc(struct gensio_os_funcs *o, enum trace_dir dir,
+ 	if (!tfilter->filename)
+ 	    goto out_nomem;
+     }
+-    tfilter->stdout = stdout;
+-    tfilter->stderr = stderr;
++    tfilter->tr_stdout = tr_stdout;
++    tfilter->tr_stderr = tr_stderr;
+ 
+     tfilter->lock = o->alloc_lock(o);
+     if (!tfilter->lock)
+@@ -385,7 +385,7 @@ gensio_trace_filter_alloc(struct gensio_os_funcs *o,
+ {
+     struct gensio_filter *filter;
+     int dir = TRACE_NONE;
+-    bool raw = false, stdout = false, stderr = false;
++    bool raw = false, tr_stdout = false, tr_stderr = false;
+     const char *filename = NULL;
+     unsigned int i;
+ 
+@@ -396,15 +396,15 @@ gensio_trace_filter_alloc(struct gensio_os_funcs *o,
+ 	    continue;
+ 	if (gensio_check_keyvalue(args[i], "file", &filename) > 0)
+ 	    continue;
+-	if (gensio_check_keybool(args[i], "stdout", &stdout) > 0)
++	if (gensio_check_keybool(args[i], "stdout", &tr_stdout) > 0)
+ 	    continue;
+-	if (gensio_check_keybool(args[i], "stderr", &stderr) > 0)
++	if (gensio_check_keybool(args[i], "stderr", &tr_stderr) > 0)
+ 	    continue;
+ 	return GE_INVAL;
+     }
+ 
+     filter = gensio_trace_filter_raw_alloc(o, dir, raw, filename,
+-					   stdout, stderr);
++					   tr_stdout, tr_stderr);
+     if (!filter)
+ 	return GE_NOMEM;
+ 
+-- 
+2.7.4
+
diff --git a/meta-oe/recipes-connectivity/gensio/gensio_1.5.3.bb b/meta-oe/recipes-connectivity/gensio/gensio_1.5.3.bb
new file mode 100644
index 0000000..8ba72f6
--- /dev/null
+++ b/meta-oe/recipes-connectivity/gensio/gensio_1.5.3.bb
@@ -0,0 +1,27 @@
+SUMMARY = "A library to abstract stream I/O like serial port, TCP, telnet, etc"
+HOMEPAGE = "https://github.com/cminyard/gensio"
+LICENSE = "GPL-2.0 & LGPL-2.1"
+LIC_FILES_CHKSUM = "file://COPYING.LIB;md5=a0fd36908af843bcee10cb6dfc47fa67 \
+                    file://COPYING;md5=bae3019b4c6dc4138c217864bd04331f \
+                    "
+
+SRCREV = "95ec1ab31ee97411fc37156d12061adcf0331598"
+PV = "1.5.3+git${SRCPV}"
+
+SRC_URI = "git://github.com/cminyard/gensio;protocol=https \
+           file://0001-filter-Rename-some-variables-to-tr_stdxxx.patch \
+           "
+
+S = "${WORKDIR}/git"
+
+inherit autotools
+
+PACKAGECONFIG ??= "openssl tcp-wrappers"
+
+PACKAGECONFIG[openssl] = "--with-openssl,--without-openssl, openssl"
+PACKAGECONFIG[tcp-wrappers] = "--with-tcp-wrappers,--without-tcp-wrappers, tcp-wrappers"
+PACKAGECONFIG[swig] = "--with-swig,--without-swig, swig"
+
+EXTRA_OECONF = "--without-python"
+
+RDEPENDS_${PN} += "bash"

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list