diff options
author | Karl Palsson <karlp@etactica.com> | 2018-02-22 11:09:53 +0000 |
---|---|---|
committer | Hans Dedecker <dedeckeh@gmail.com> | 2018-06-07 17:20:40 +0200 |
commit | c24c8bfd0a3b89b31440bb59f429ff6b06350d6d (patch) | |
tree | 77159b5de07ae637736e228217e52e38a0b0f936 /package/system/ubox | |
parent | 0c59c9c9db5dcd18e7f45f093e6b5547f1c19329 (diff) | |
download | upstream-c24c8bfd0a3b89b31440bb59f429ff6b06350d6d.tar.gz upstream-c24c8bfd0a3b89b31440bb59f429ff6b06350d6d.tar.bz2 upstream-c24c8bfd0a3b89b31440bb59f429ff6b06350d6d.zip |
logd: create log directory for log_file
If log_file is specified, make sure its directory exists.
Signed-off-by: Karl Palsson <karlp@etactica.com>
Signed-off-by: Hans Dedecker <dedeckeh@gmail.com> [PKG_RELEASE increase]
Diffstat (limited to 'package/system/ubox')
-rw-r--r-- | package/system/ubox/Makefile | 2 | ||||
-rw-r--r-- | package/system/ubox/files/log.init | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/package/system/ubox/Makefile b/package/system/ubox/Makefile index 89cc6768fb..85dddff858 100644 --- a/package/system/ubox/Makefile +++ b/package/system/ubox/Makefile @@ -1,7 +1,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ubox -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/ubox.git diff --git a/package/system/ubox/files/log.init b/package/system/ubox/files/log.init index 21e0787125..ae5dd1f03d 100644 --- a/package/system/ubox/files/log.init +++ b/package/system/ubox/files/log.init @@ -55,6 +55,8 @@ start_service_file() } [ -z "${log_file}" ] && return + mkdir -p "$(dirname "${log_file}")" + procd_open_instance procd_set_param command "$PROG" -f -F "$log_file" -p "$pid_file" [ -n "${log_size}" ] && procd_append_param command -S "$log_size" |