2013-03-19 18:28:32 -04:00
|
|
|
SOFTWARE_MEANT_FOR_SORTIX=1
|
2012-09-10 17:36:15 -04:00
|
|
|
include ../compiler.mak
|
|
|
|
include ../version.mak
|
|
|
|
include ../dirs.mak
|
2011-08-11 16:51:04 -04:00
|
|
|
|
2012-09-10 17:36:15 -04:00
|
|
|
ifndef OPTLEVEL
|
2013-03-19 18:28:32 -04:00
|
|
|
OPTLEVEL=-g -O2
|
2012-09-10 17:36:15 -04:00
|
|
|
endif
|
2012-09-08 14:33:52 -04:00
|
|
|
|
2012-09-10 17:36:15 -04:00
|
|
|
ifndef CXXFLAGS
|
|
|
|
CXXFLAGS:=$(OPTLEVEL)
|
|
|
|
endif
|
|
|
|
|
|
|
|
CXXFLAGS:=$(CXXFLAGS) -Wall -Wextra -fno-exceptions -fno-rtti
|
|
|
|
|
|
|
|
BINARIES:=\
|
2011-08-28 06:33:46 -04:00
|
|
|
pong \
|
2011-08-28 18:09:37 -04:00
|
|
|
conway \
|
2011-09-07 06:20:28 -04:00
|
|
|
snake \
|
2012-05-22 15:46:38 -04:00
|
|
|
asteroids \
|
2011-08-11 16:51:04 -04:00
|
|
|
|
2013-03-19 18:28:32 -04:00
|
|
|
INSTALLBINARIES:=$(addprefix $(DESTDIR)$(BINDIR)/,$(BINARIES))
|
|
|
|
|
2012-12-15 16:15:30 -05:00
|
|
|
LIBS:=-ldispd
|
|
|
|
|
2012-09-10 17:36:15 -04:00
|
|
|
all: $(BINARIES)
|
|
|
|
|
|
|
|
.PHONY: all install uninstall clean
|
2011-08-11 16:51:04 -04:00
|
|
|
|
2012-09-10 17:36:15 -04:00
|
|
|
install: all
|
2013-03-19 18:28:32 -04:00
|
|
|
mkdir -p $(DESTDIR)$(BINDIR)
|
|
|
|
install $(BINARIES) $(DESTDIR)$(BINDIR)
|
2011-08-28 06:33:46 -04:00
|
|
|
|
2012-09-10 17:36:15 -04:00
|
|
|
uninstall:
|
2013-03-19 18:28:32 -04:00
|
|
|
rm -f $(INSTALLBINARIES)
|
2011-08-28 06:33:46 -04:00
|
|
|
|
|
|
|
%: %.cpp
|
2013-03-19 18:28:32 -04:00
|
|
|
$(CXX) -std=gnu++11 $(CPPFLAGS) $(CXXFLAGS) $< -o $@ $(LIBS)
|
2011-08-11 16:51:04 -04:00
|
|
|
|
|
|
|
clean:
|
2012-09-10 17:36:15 -04:00
|
|
|
rm -f $(BINARIES) *.o
|
2011-08-11 16:51:04 -04:00
|
|
|
|