diff options
Diffstat (limited to 'testing/p910nd/fix-paths.patch')
-rw-r--r-- | testing/p910nd/fix-paths.patch | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/testing/p910nd/fix-paths.patch b/testing/p910nd/fix-paths.patch new file mode 100644 index 0000000000..d0d10960c1 --- /dev/null +++ b/testing/p910nd/fix-paths.patch @@ -0,0 +1,71 @@ +diff -u a/Makefile b/Makefile +--- a/Makefile 2014-06-01 13:58:41.867584813 +0400 ++++ b/Makefile 2014-06-01 14:20:47.460700951 +0400 +@@ -5,14 +5,11 @@ + DEFINES += -DUSE_LIBWRAP + endif + +-# If you don't have it in /var/log/subsys, uncomment and define +-#CFLAGS += -DLOCKFILE_DIR=\"/var/log\" ++# If you don't have it in /var/lock/subsys, uncomment and define ++CFLAGS += -DLOCKFILE_DIR=\"/var/lock\" + +-# GNU target string +-CROSS = +- +-CC = $(CROSS)gcc +-STRIP = $(CROSS)strip ++CC := gcc ++STRIP := strip + + CFLAGS += -O2 -Wall + +diff --git a/p910nd.c b/p910nd.c +index 2fa4454..a58c1f0 100644 +--- a/p910nd.c ++++ b/p910nd.c +@@ -133,11 +133,11 @@ extern int hosts_ctl(char *daemon, char *client_name, char *client_addr, char *c + #endif + + #define BASEPORT 9100 +-#define PIDFILE "/var/run/p910%cd.pid" ++#define PIDFILE "/run/p910nd/p910nd.%c.pid" + #ifdef LOCKFILE_DIR + #define LOCKFILE LOCKFILE_DIR "/p910%cd" + #else +-#define LOCKFILE "/var/lock/subsys/p910%cd" ++#define LOCKFILE "/run/lock/p910nd" + #endif + #ifndef PRINTERFILE + #define PRINTERFILE "/dev/lp%c" +diff --git a/Makefile b/Makefile +index 53db51f..6012199 100644 +--- a/Makefile ++++ b/Makefile +@@ -14,12 +14,10 @@ STRIP := strip + CFLAGS += -O2 -Wall + + PROG = p910nd +-CONFIG = p910nd.conf + INITSCRIPT = p910nd.init + MANPAGE = p910nd.8 + INSTALL = install + BINDIR = /usr/sbin +-CONFIGDIR = /etc/sysconfig + SCRIPTDIR = /etc/init.d + MANDIR = /usr/share/man/man8 + +@@ -29,11 +27,10 @@ $(PROG): p910nd.c + strip: $(PROG) + $(STRIP) -s $(PROG) + +-install: $(PROG) $(CONFIG) $(INITSCRIPT) $(MANPAGE) +- mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(CONFIGDIR) \ ++install: $(PROG) $(INITSCRIPT) $(MANPAGE) ++ mkdir -p $(DESTDIR)$(BINDIR) \ + $(DESTDIR)$(SCRIPTDIR) $(DESTDIR)$(MANDIR) + $(INSTALL) $(PROG) $(DESTDIR)$(BINDIR) +- $(INSTALL) -m 644 $(CONFIG) $(DESTDIR)$(CONFIGDIR)/$(PROG) + $(INSTALL) $(INITSCRIPT) $(DESTDIR)$(SCRIPTDIR)/$(PROG) + $(INSTALL) -m 644 $(MANPAGE) $(DESTDIR)$(MANDIR) + |