To simplify packaging of can-utils, add DESTDIR and PREFIX support to
the can-utils Makefile.

Signed-off-by: Olaf Hering <[email protected]>

Index: can-utils-0.svn1112/Makefile
===================================================================
--- can-utils-0.svn1112.orig/Makefile   2010-02-17 18:48:17.570215749 +0100
+++ can-utils-0.svn1112/Makefile        2010-02-17 18:50:40.039271474 +0100
@@ -40,6 +40,9 @@
 #
 #  Send feedback to <[email protected]>
 
+DESTDIR =
+PREFIX = /usr/local
+
 KERNELDIR = ../kernel/2.6
 
 MAKEFLAGS = -k
@@ -61,7 +64,8 @@
        rm -f $(PROGRAMS) *.o
 
 install:
-       cp -f $(PROGRAMS) /usr/local/bin
+       mkdir -p $(DESTDIR)$(PREFIX)/bin
+       cp -f $(PROGRAMS) $(DESTDIR)$(PREFIX)/bin
 
 distclean:
        rm -f $(PROGRAMS) *.o *~

_______________________________________________
Socketcan-core mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/socketcan-core

Reply via email to