mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Added support for systemd
This commit is contained in:
parent
687b93b215
commit
a4b8729e6a
@ -2935,6 +2935,7 @@ Christopher Reimer <vdr@creimer.net>
|
|||||||
VDR source directory when doing "make plugins"
|
VDR source directory when doing "make plugins"
|
||||||
for reverting the change from version 1.5.7 that made all logging go to LOG_ERR
|
for reverting the change from version 1.5.7 that made all logging go to LOG_ERR
|
||||||
for reporting a possible crash in the OSD demo
|
for reporting a possible crash in the OSD demo
|
||||||
|
for adding support for systemd
|
||||||
|
|
||||||
Stefan Huskamp <coca_cola1@gmx.de>
|
Stefan Huskamp <coca_cola1@gmx.de>
|
||||||
for suggesting to make entering characters via the number keys
|
for suggesting to make entering characters via the number keys
|
||||||
|
2
HISTORY
2
HISTORY
@ -8258,3 +8258,5 @@ Video Disk Recorder Revision History
|
|||||||
- Now resetting the isOnVideoDirectoryFileSystem member of a cRecording to -1 after
|
- Now resetting the isOnVideoDirectoryFileSystem member of a cRecording to -1 after
|
||||||
renaming it, so that it will be re-checked upon the next call to
|
renaming it, so that it will be re-checked upon the next call to
|
||||||
IsOnVideoDirectoryFileSystem().
|
IsOnVideoDirectoryFileSystem().
|
||||||
|
- Added support for systemd (thanks to Christopher Reimer). To activate this you
|
||||||
|
need to add "SDNOTIFY=1" to the 'make' call.
|
||||||
|
7
Makefile
7
Makefile
@ -4,7 +4,7 @@
|
|||||||
# See the main source file 'vdr.c' for copyright information and
|
# See the main source file 'vdr.c' for copyright information and
|
||||||
# how to reach the author.
|
# how to reach the author.
|
||||||
#
|
#
|
||||||
# $Id: Makefile 3.1 2013/05/23 10:10:00 kls Exp $
|
# $Id: Makefile 3.2 2014/03/16 12:47:35 kls Exp $
|
||||||
|
|
||||||
.DELETE_ON_ERROR:
|
.DELETE_ON_ERROR:
|
||||||
|
|
||||||
@ -93,6 +93,11 @@ INCLUDES += $(shell pkg-config --cflags fribidi)
|
|||||||
DEFINES += -DBIDI
|
DEFINES += -DBIDI
|
||||||
LIBS += $(shell pkg-config --libs fribidi)
|
LIBS += $(shell pkg-config --libs fribidi)
|
||||||
endif
|
endif
|
||||||
|
ifdef SDNOTIFY
|
||||||
|
INCLUDES += $(shell pkg-config --cflags libsystemd-daemon)
|
||||||
|
DEFINES += -DSDNOTIFY
|
||||||
|
LIBS += $(shell pkg-config --libs libsystemd-daemon)
|
||||||
|
endif
|
||||||
|
|
||||||
LIRC_DEVICE ?= /var/run/lirc/lircd
|
LIRC_DEVICE ?= /var/run/lirc/lircd
|
||||||
|
|
||||||
|
9
vdr.c
9
vdr.c
@ -22,7 +22,7 @@
|
|||||||
*
|
*
|
||||||
* The project's page is at http://www.tvdr.de
|
* The project's page is at http://www.tvdr.de
|
||||||
*
|
*
|
||||||
* $Id: vdr.c 3.10 2014/01/26 12:27:51 kls Exp $
|
* $Id: vdr.c 3.11 2014/03/16 12:49:13 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <getopt.h>
|
#include <getopt.h>
|
||||||
@ -34,6 +34,9 @@
|
|||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <sys/capability.h>
|
#include <sys/capability.h>
|
||||||
#include <sys/prctl.h>
|
#include <sys/prctl.h>
|
||||||
|
#ifdef SDNOTIFY
|
||||||
|
#include <systemd/sd-daemon.h>
|
||||||
|
#endif
|
||||||
#include <termios.h>
|
#include <termios.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "audio.h"
|
#include "audio.h"
|
||||||
@ -845,6 +848,10 @@ int main(int argc, char *argv[])
|
|||||||
alarm(WatchdogTimeout); // Initial watchdog timer start
|
alarm(WatchdogTimeout); // Initial watchdog timer start
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef SDNOTIFY
|
||||||
|
sd_notify(0, "READY=1");
|
||||||
|
#endif
|
||||||
|
|
||||||
// Main program loop:
|
// Main program loop:
|
||||||
|
|
||||||
#define DELETE_MENU ((IsInfoMenu &= (Menu == NULL)), delete Menu, Menu = NULL)
|
#define DELETE_MENU ((IsInfoMenu &= (Menu == NULL)), delete Menu, Menu = NULL)
|
||||||
|
Loading…
Reference in New Issue
Block a user