distcc: fix initscript can not stop distcc daemon correctly
cover distcc: fix initscript can not stop distcc daemon correctly
The following changes since commit c45589a55c67bfd0bf9da5050141f4d18835e113:
poky.conf: mark all CentOS 6/7 versions as compatible (2015-01-12 13:31:08 +0000)
are available in the git repository at:
git://git.pokylinux.org/poky-contrib hongxu/fix-distcc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-distcc
Hongxu Jia (1):
distcc: fix initscript can not stop distcc daemon correctly
meta/recipes-devtools/distcc/files/distcc | 5 +++++ 1 file changed, 5 insertions(+)
Signature · 1 line
1.9.1
PATCH 1/1 distcc: fix initscript can not stop distcc daemon correctly
The distcc's initscript has used option '--pid-file' to save daemon process id, but it didn't to create that file, that caused start/stop distcc daemon failed.
We refer what Ubuntu 14.04 did, create pid file before start and delete it after stop
[YOCTO #7090]
--- meta/recipes-devtools/distcc/files/distcc | 5 +++++ 1 file changed, 5 insertions(+)
meta/recipes-devtools/distcc/files/distcc +5 -0
@@ -51,6 +51,9 @@ should_start() { echo "$DAEMON not starting" exit 0 fi + # we need permission to write to the pid file + touch /var/run/$NAME.pid + chown distcc /var/run/$NAME.pid } case "$1" in
@@ -75,6 +78,7 @@ case "$1" in echo "$0: stop failed with error code $code" >&2 exit $code } + rm -f /var/run/$NAME.pid >/dev/null 2>&1 echo "." ;; restart|force-reload)
@@ -92,6 +96,7 @@ case "$1" in --exec $DAEMON -- $DAEMON_ARGS $ALLOW || { code=$? + rm -f /var/run/$NAME.pid >/dev/null 2>&1 echo "$0: restart failed with error code $code" >&2 exit $code }
Signature · 1 line
1.9.1