shadow-native: disable logging to syslog

Disable use of syslog to prevent sysroot user and group additions
from writing entries to the host's syslog.

This fixes [YOCTO #2012]

(From OE-Core rev: e5aee0a2f5973a7aef81d0f38307a93791f616c6)

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Scott Garman 2012-04-05 10:14:28 -07:00 committed by Richard Purdie
parent 73e3fd88b4
commit c54831fa89
2 changed files with 37 additions and 2 deletions

View File

@ -0,0 +1,34 @@
Disable use of syslog to prevent sysroot user and group additions from
writing entries to the host's syslog. This patch should only be used
with the shadow-native recipe.
Upstream-Status: Inappropriate [disable feature]
Signed-off-by: Scott Garman <scott.a.garman@intel.com>
diff -urN shadow-4.1.4.3.orig//src/groupadd.c shadow-4.1.4.3/src/groupadd.c
--- shadow-4.1.4.3.orig//src/groupadd.c 2011-02-13 09:58:16.000000000 -0800
+++ shadow-4.1.4.3/src/groupadd.c 2012-04-05 10:05:59.440001758 -0700
@@ -34,6 +34,9 @@
#ident "$Id: groupadd.c 3015 2009-06-05 22:16:56Z nekral-guest $"
+/* Disable use of syslog since we're running this command against a sysroot */
+#undef USE_SYSLOG
+
#include <ctype.h>
#include <fcntl.h>
#include <getopt.h>
diff -urN shadow-4.1.4.3.orig//src/useradd.c shadow-4.1.4.3/src/useradd.c
--- shadow-4.1.4.3.orig//src/useradd.c 2011-02-13 09:58:16.000000000 -0800
+++ shadow-4.1.4.3/src/useradd.c 2012-04-05 10:06:25.076001315 -0700
@@ -34,6 +34,9 @@
#ident "$Id: useradd.c 3015 2009-06-05 22:16:56Z nekral-guest $"
+/* Disable use of syslog since we're running this command against a sysroot */
+#undef USE_SYSLOG
+
#include <assert.h>
#include <ctype.h>
#include <errno.h>

View File

@ -7,14 +7,15 @@ LICENSE = "BSD | Artistic-1.0"
LIC_FILES_CHKSUM = "file://COPYING;md5=08c553a87d4e51bbed50b20e0adcaede \
file://src/passwd.c;firstline=8;endline=30;md5=2899a045e90511d0e043b85a7db7e2fe"
PR = "r3"
PR = "r4"
SRC_URI = "http://pkg-shadow.alioth.debian.org/releases/${BPN}-${PV}.tar.bz2 \
file://shadow.automake-1.11.patch \
file://shadow-4.1.3-dots-in-usernames.patch \
file://shadow-4.1.4.2-env-reset-keep-locale.patch \
file://add_root_cmd_options.patch \
file://useradd.patch"
file://disable-syslog.patch \
file://useradd.patch"
SRC_URI[md5sum] = "b8608d8294ac88974f27b20f991c0e79"
SRC_URI[sha256sum] = "633f5bb4ea0c88c55f3642c97f9d25cbef74f82e0b4cf8d54e7ad6f9f9caa778"