summaryrefslogtreecommitdiffstats
path: root/external/meta-openembedded/meta-oe/recipes-support/log4c
diff options
context:
space:
mode:
authorToshikazuOhiwa <toshikazu_ohiwa@mail.toyota.co.jp>2020-03-30 09:24:26 +0900
committerToshikazuOhiwa <toshikazu_ohiwa@mail.toyota.co.jp>2020-03-30 09:24:26 +0900
commit5b80bfd7bffd4c20d80b7c70a7130529e9a755dd (patch)
treeb4bb18dcd1487dbf1ea8127e5671b7bb2eded033 /external/meta-openembedded/meta-oe/recipes-support/log4c
parent706ad73eb02caf8532deaf5d38995bd258725cb8 (diff)
agl-basesystem
Diffstat (limited to 'external/meta-openembedded/meta-oe/recipes-support/log4c')
-rw-r--r--external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/0001-Use-the-API-properly-in-the-example-format-security-.patch26
-rw-r--r--external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/fix_configure_with-expat.patch21
-rw-r--r--external/meta-openembedded/meta-oe/recipes-support/log4c/log4c_1.2.4.bb21
3 files changed, 68 insertions, 0 deletions
diff --git a/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/0001-Use-the-API-properly-in-the-example-format-security-.patch b/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/0001-Use-the-API-properly-in-the-example-format-security-.patch
new file mode 100644
index 00000000..9ff9d700
--- /dev/null
+++ b/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/0001-Use-the-API-properly-in-the-example-format-security-.patch
@@ -0,0 +1,26 @@
+From 97f0b7b25474fab25f5757f7c50a77e20be5d05b Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Franti=C5=A1ek=20Dvo=C5=99=C3=A1k?= <valtri@civ.zcu.cz>
+Date: Mon, 7 Sep 2015 15:00:48 +0200
+Subject: [PATCH] Use the API properly in the example (format security error
+ fixed).
+
+---
+ examples/helloworld1/mylog.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/examples/helloworld1/mylog.h b/examples/helloworld1/mylog.h
+index 280f3dc..57e5369 100644
+--- a/examples/helloworld1/mylog.h
++++ b/examples/helloworld1/mylog.h
+@@ -39,7 +39,7 @@ static LOG4C_INLINE int mylog_fini(){
+
+ static LOG4C_INLINE void mylog_msg(char *catName,int a_priority, char *msg){
+ #ifndef WITHOUT_LOG4C
+- log4c_category_log(log4c_category_get(catName), a_priority, msg);
++ log4c_category_log(log4c_category_get(catName), a_priority, "%s", msg);
+ #else
+ printf(msg);
+ #endif
+--
+2.12.0
+
diff --git a/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/fix_configure_with-expat.patch b/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/fix_configure_with-expat.patch
new file mode 100644
index 00000000..4872eb4f
--- /dev/null
+++ b/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c/fix_configure_with-expat.patch
@@ -0,0 +1,21 @@
+The original use of AC_ARG_WITH is buggy and causes expat support
+to be *disabled* if "--with-expat" is passed to configure.
+
+Upstream status: pending
+
+Index: log4c-1.2.4/configure.in
+===================================================================
+--- log4c-1.2.4.orig/configure.in
++++ log4c-1.2.4/configure.in
+@@ -217,9 +217,9 @@ AC_ARG_WITH(expat,
+ have any effect and Log4C uses some bundled yacc/lex code
+ for parsing it's configuration file.
+ ]),
+- with_expat=no,
++ [],
+ with_expat=yes)
+-if test x$with_expat = xyes ; then
++if test x$with_expat != xno ; then
+ use_expat=yes
+ AM_PATH_EXPAT(1.95.1)
+ fi
diff --git a/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c_1.2.4.bb b/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c_1.2.4.bb
new file mode 100644
index 00000000..ef7ad847
--- /dev/null
+++ b/external/meta-openembedded/meta-oe/recipes-support/log4c/log4c_1.2.4.bb
@@ -0,0 +1,21 @@
+SUMMARY = "Log4c is a C library for flexible logging to files, syslog and other destinations"
+HOMEPAGE = "http://log4c.sourceforge.net"
+LICENSE = "LGPLv2"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${BP}.tar.gz \
+ file://fix_configure_with-expat.patch \
+ file://0001-Use-the-API-properly-in-the-example-format-security-.patch \
+ "
+
+SRC_URI[md5sum] = "0d94919136e1d16b68427562e74cb3dd"
+SRC_URI[sha256sum] = "5991020192f52cc40fa852fbf6bbf5bd5db5d5d00aa9905c67f6f0eadeed48ea"
+
+PACKAGECONFIG ??= "expat"
+PACKAGECONFIG[expat] = "--with-expat,--without-expat,expat"
+
+BINCONFIG = "${bindir}/log4c-config"
+
+inherit autotools binconfig-disabled
+
+BBCLASSEXTEND = "native"