DESTDIR patch

From: Serge Leschinsky <fish_at_infonet.nnov.ru>
Date: Fri, 20 Mar 2009 17:53:58 -0700

Hello,

This is the trivial patch for DESTDIR support.

Thanks for your job,

Serge

--- a/Makefile 2009-03-20 19:03:00.000000000 -0500
+++ b/Makefile 2009-03-20 19:12:32.000000000 -0500
@@ -25,6 +25,7 @@
 INCROND_OBJ = icd-main.o incrontab.o inotify-cxx.o usertable.o strtok.o
appinst.o incroncfg.o appargs.o
 INCRONTAB_OBJ = ict-main.o incrontab.o inotify-cxx.o strtok.o incroncfg.o
appargs.o

+DESTDIR =

 all: $(PROGRAMS)

@@ -44,21 +45,22 @@
 distclean: clean

 install: all install-man
- [ -d $(PREFIX) ]
- $(INSTALL) -m 04755 -o $(USER) incrontab $(PREFIX)/bin/
- $(INSTALL) -m 0755 incrond $(PREFIX)/sbin/
- $(INSTALL) -m 0755 -o $(USER) -d $(USERDATADIR)
- $(INSTALL) -m 0755 -o $(USER) -d $(SYSDATADIR)
- $(INSTALL) -m 0644 -o $(USER) incron.conf.example $(CFGDIR)
+ $(INSTALL) -m 0755 -o $(USER) -d $(DESTDIR)$(PREFIX)/{bin,sbin}
+ [ -d $(DESTDIR)$(PREFIX) ]
+ $(INSTALL) -m 04755 -o $(USER) incrontab $(DESTDIR)$(PREFIX)/bin/
+ $(INSTALL) -m 0755 incrond $(DESTDIR)$(PREFIX)/sbin/
+ $(INSTALL) -m 0755 -o $(USER) -d $(DESTDIR)$(USERDATADIR)
+ $(INSTALL) -m 0755 -o $(USER) -d $(DESTDIR)$(SYSDATADIR)
+ $(INSTALL) -m 0644 -o $(USER) incron.conf.example $(DESTDIR)$(CFGDIR)

 install-man: incrontab.1 incrontab.5 incrond.8 incron.conf.5
- $(INSTALL) -m 0755 -d $(MANPATH)/man1
- $(INSTALL) -m 0755 -d $(MANPATH)/man5
- $(INSTALL) -m 0755 -d $(MANPATH)/man8
- $(INSTALL) -m 0644 incrontab.1 $(MANPATH)/man1
- $(INSTALL) -m 0644 incrontab.5 $(MANPATH)/man5
- $(INSTALL) -m 0644 incrond.8 $(MANPATH)/man8
- $(INSTALL) -m 0644 incron.conf.5 $(MANPATH)/man5
+ $(INSTALL) -m 0755 -d $(DESTDIR)$(MANPATH)/man1
+ $(INSTALL) -m 0755 -d $(DESTDIR)$(MANPATH)/man5
+ $(INSTALL) -m 0755 -d $(DESTDIR)$(MANPATH)/man8
+ $(INSTALL) -m 0644 incrontab.1 $(DESTDIR)$(MANPATH)/man1
+ $(INSTALL) -m 0644 incrontab.5 $(DESTDIR)$(MANPATH)/man5
+ $(INSTALL) -m 0644 incrond.8 $(DESTDIR)$(MANPATH)/man8
+ $(INSTALL) -m 0644 incron.conf.5 $(DESTDIR)$(MANPATH)/man5

 uninstall: uninstall-man
        [ -d $(PREFIX) ]
Received on Sat Mar 21 2009 - 02:03:24 CET

This archive was generated by hypermail 2.2.0 : Tue Jun 05 2012 - 22:14:21 CEST