rsyslog: upgrade to 7.6.7

* fix CVEs CVE-2014-3634, CVE-2014-3683

* rebase the patch use-pkgconfig-to-check-libgcrypt.patch

* backport fixes for build error:
  lexer.l:34:14: error: expected identifier or '(' before '__extension__'

* replace the old configure option '--enable-cached-man-pages' with
  '--disable-generate-man-pages'

Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
Wenzong Fan
2016-09-20 01:57:25 -04:00
committed by Martin Jansa
parent 0de66c207c
commit b2d3dacc5e
3 changed files with 66 additions and 17 deletions
@@ -0,0 +1,51 @@
Backport below commit for fixing:
lexer.l:34:14: error: expected identifier or '(' before '__extension__'
From 876bdd1c85353f7e254f4b4c3e228484860cea57 Mon Sep 17 00:00:00 2001
From: Tomas Heinrich <theinric@redhat.com>
Date: Mon, 17 Nov 2014 20:53:22 +0100
Subject: [PATCH] bugfix: include config.h before any other headers
For some reason, flex used to prepend several standard headers before
config.h. This prevented some conditional extension in these headers
from being defined.
The explicit prototype for strdup() shouldn't be required anymore as
it should be provided by string.h.
Upstream-Status: Backport
---
grammar/lexer.l | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/grammar/lexer.l b/grammar/lexer.l
index 359cf9f..c834ef7 100644
--- a/grammar/lexer.l
+++ b/grammar/lexer.l
@@ -28,10 +28,12 @@
* limitations under the License.
*/
-%{
+%top{
#include "config.h"
+}
+
+%{
#include "parserif.h"
-extern char *strdup(__const char*); /* somehow we may not get this from string.h... */
%}
%option noyywrap nodefault case-insensitive yylineno
@@ -67,6 +69,7 @@ extern char *strdup(__const char*); /* somehow we may not get this from string.h
#include <ctype.h>
#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include <strings.h>
#include <libestr.h>
#include "rainerscript.h"
--
2.7.4
@@ -9,34 +9,31 @@ libgcrypt does no longer provide libgcrypt-config, and provide
*.pc, so we should use pkgconfig to check
Signed-off-by: Roy Li <rongqing.li@windriver.com>
Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
---
configure.ac | 19 +------------------
1 file changed, 1 insertion(+), 18 deletions(-)
configure.ac | 15 +--------------
1 file changed, 1 insertion(+), 14 deletions(-)
diff --git a/configure.ac b/configure.ac
index 017116e..1b880f8 100644
index 0f31869..d35db42 100644
--- a/configure.ac
+++ b/configure.ac
@@ -784,24 +784,7 @@ AC_ARG_ENABLE(libgcrypt,
@@ -777,20 +777,7 @@ AC_ARG_ENABLE(libgcrypt,
[enable_libgcrypt=yes]
)
if test "x$enable_libgcrypt" = "xyes"; then
- AC_CHECK_PROG(
- [HAVE_LIBGCRYPT_CONFIG],
- [libgcrypt-config],
- [yes],,,
- )
- if test "x${HAVE_LIBGCRYPT_CONFIG}" != "xyes"; then
- AC_PATH_PROG([LIBGCRYPT_CONFIG],[libgcrypt-config],[no])
- if test "x${LIBGCRYPT_CONFIG}" = "xno"; then
- AC_MSG_FAILURE([libgcrypt-config not found in PATH])
- fi
- AC_CHECK_LIB(
- [gcrypt],
- [gcry_cipher_open],
- [LIBGCRYPT_CFLAGS="`libgcrypt-config --cflags`"
- LIBGCRYPT_LIBS="`libgcrypt-config --libs`"
- [LIBGCRYPT_CFLAGS="`${LIBGCRYPT_CONFIG} --cflags`"
- LIBGCRYPT_LIBS="`${LIBGCRYPT_CONFIG} --libs`"
- ],
- [AC_MSG_FAILURE([libgcrypt is missing])],
- [`libgcrypt-config --libs --cflags`]
- [`${LIBGCRYPT_CONFIG} --libs --cflags`]
- )
- AC_DEFINE([ENABLE_LIBGCRYPT], [1], [Indicator that LIBGCRYPT is present])
+ PKG_CHECK_MODULES(LIBGCRYPT, libgcrypt)
@@ -44,5 +41,5 @@ index 017116e..1b880f8 100644
AM_CONDITIONAL(ENABLE_LIBGCRYPT, test x$enable_libgcrypt = xyes)
AC_SUBST(LIBGCRYPT_CFLAGS)
--
1.7.9.5
2.8.1
@@ -27,15 +27,16 @@ SRC_URI = "http://www.rsyslog.com/download/files/download/rsyslog/${BPN}-${PV}.t
file://json-0.12-fix.patch \
file://replace_deprecated_GnuTLS_functions.patch \
file://use_gnutls_certificate_type_set_priority_only_if_available.patch \
file://bugfix-include-config.h-before-any-other-headers.patch \
file://enable_tls_ptests.patch \
"
SRC_URI[md5sum] = "093c462a5245012bd9e7b82dd8aedffb"
SRC_URI[sha256sum] = "357f089d866c351d5fe5b7139fa85b010223d77b3c21f29b2a1baa8688926111"
SRC_URI[md5sum] = "fa78a6e675fe78a811edcdf7eb6f1975"
SRC_URI[sha256sum] = "fc29d2d9cbf3396091dd0bab2eb6f847aed4a44ef73138a97ddf9447446125ee"
inherit autotools pkgconfig systemd update-rc.d update-alternatives ptest
EXTRA_OECONF += "--enable-cached-man-pages"
EXTRA_OECONF += "--disable-generate-man-pages"
# first line is default yes in configure
PACKAGECONFIG ??= " \