]> git.neil.brown.name Git - portmap.git/commitdiff
respect DESTDIR and dont use -s with install
authorMike Frysinger <vapier@gentoo.org>
Sun, 13 May 2007 21:15:12 +0000 (17:15 -0400)
committerNeil Brown <neilb@suse.de>
Sun, 13 May 2007 23:25:13 +0000 (09:25 +1000)
$(DESTDIR) is the standard for installing into other trees, not $(BASEDIR) ...
so I've converted the Makefile to use that.  I've also left in $(BASEDIR) as a
default to support old installs; not sure if you'd just cut it.

Stripping should be left to the person to handle, not automatically done by
the install step.  Also, `install -s` always calls `strip` which is
wrong/undesired in cross-compiling scenarios.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Neil Brown <neilb@suse.de>
Makefile

index 9e9a4b41117c61c5a2c6a1588ae59871ad183a75..53434284fc3e646cb3d3a564cb0248444e425e8d 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -135,13 +135,14 @@ from_local: CPPFLAGS += -DTEST
 portmap.man : portmap.8
        sed $(MAN_SED) < portmap.8 > portmap.man
 
+DESTDIR = $(BASEDIR)
 install: all
-       install -o root -g root -m 0755 -s portmap ${BASEDIR}/sbin
-       install -o root -g root -m 0755 -s pmap_dump ${BASEDIR}/sbin
-       install -o root -g root -m 0755 -s pmap_set ${BASEDIR}/sbin
-       install -o root -g root -m 0644 portmap.man ${BASEDIR}/usr/share/man/man8/portmap.8
-       install -o root -g root -m 0644 pmap_dump.8 ${BASEDIR}/usr/share/man/man8
-       install -o root -g root -m 0644 pmap_set.8 ${BASEDIR}/usr/share/man/man8
+       install -o root -g root -m 0755 portmap $(DESTDIR)/sbin
+       install -o root -g root -m 0755 pmap_dump $(DESTDIR)/sbin
+       install -o root -g root -m 0755 pmap_set $(DESTDIR)/sbin
+       install -o root -g root -m 0644 portmap.man $(DESTDIR)/usr/share/man/man8/portmap.8
+       install -o root -g root -m 0644 pmap_dump.8 $(DESTDIR)/usr/share/man/man8
+       install -o root -g root -m 0644 pmap_set.8 $(DESTDIR)/usr/share/man/man8
 
 clean:
        rm -f *.o portmap pmap_dump pmap_set from_local \