Skip to content

Commit

Permalink
Fix DESTDIR support
Browse files Browse the repository at this point in the history
DESTDIR should not be passed to compiler, it only affects installation
  • Loading branch information
AMDmi3 committed Mar 12, 2015
1 parent 15078ba commit 2ba2af0
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
# Installation directories
DESTDIR ?=
PREFIX ?= /usr/local
BINIDIR := $(DESTDIR)$(PREFIX)/games
DATIDIR := $(DESTDIR)$(PREFIX)/share/games/harris
BINIDIR ?= $(PREFIX)/games
DATIDIR ?= $(PREFIX)/share/games/harris
# User directories (relative to $HOME)
USAVDIR := .local/share/harris

Expand All @@ -24,13 +24,13 @@ SDLFLAGS := `sdl-config --cflags`
all: harris $(SAVES)

install: all
install -d $(BINIDIR) $(DATIDIR)
install harris $(BINIDIR)/
./install.py -d $(DATIDIR)
install -d $(DESTDIR)$(BINIDIR) $(DESTDIR)$(DATIDIR)
install harris $(DESTDIR)$(BINIDIR)/
./install.py -d $(DESTDIR)$(DATIDIR)

uninstall:
rm $(BINIDIR)/harris
rm -r $(DATIDIR)
rm $(DESTDIR)$(BINIDIR)/harris
rm -r $(DESTDIR)$(DATIDIR)

clean:
-rm harris harris.o $(OBJS) $(SAVES)
Expand Down

0 comments on commit 2ba2af0

Please sign in to comment.