make DESRDIR a prefix of everything according my understanding
of the GNU standards. This is also useful(/needed) for installing
in Gentoo. Declare BINDIR for bin/program directory.
Signed-off-by: Martin Gysel <me@bearsh.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
# these locations seem to work for SuSE and Fedora
# prefix = $(HOME)
-prefix = /usr
-DESTDIR = $(prefix)/bin
+prefix = $(DESTDIR)/usr
+BINDIR = $(prefix)/bin
DATADIR = $(prefix)/share
DESKTOPDIR = $(DATADIR)/applications
ICONPATH = $(DATADIR)/icons/hicolor
$(CC) $(LDFLAGS) -o $(NAME) $(OBJS) $(LIBS)
install: $(NAME)
- $(INSTALL) -d -m 755 $(DESTDIR)
- $(INSTALL) $(NAME) $(DESTDIR)
+ $(INSTALL) -d -m 755 $(BINDIR)
+ $(INSTALL) $(NAME) $(BINDIR)
$(INSTALL) -d -m 755 $(DESKTOPDIR)
$(INSTALL) $(DESKTOPFILE) $(DESKTOPDIR)
$(INSTALL) -d -m 755 $(ICONDIR)