CFLAGS?= -O2 -s
INI_F?=$(DESTDIR)/usr/share/games/fairymax/fmax.ini
INI_Q?=$(DESTDIR)/usr/share/games/fairymax/qmax.ini
-
+VERSION?=`grep 'define VERSION' fairymax.c | sed -e 's/.*"\(.*\)".*/\1/'`
ALL= fairymax shamax maxqi fairymax.6.gz
dist-clean:
rm -f ${ALL} *~ data/*~ *.man md5sums
-dist:
+dist: fairymax
install -d -m0755 Fairy-Max
install -d -m0755 Fairy-Max/data
rm -f fairymax.tar fairymax.tar.gz
cp fairymax.c maxqi.c fairymax.pod Makefile README changelog copyright Fairy-Max
cp data/* Fairy-Max/data
(md5sum Fairy-Max/* Fairy-Max/data/* > Fairy-Max/md5sums) || true
- tar -cvvf fairymax.tar Fairy-Max
- gzip fairymax.tar
+ tar -cvvf fairymax-$(VERSION).tar Fairy-Max
+ gzip fairymax-$(VERSION).tar
+ rm fairymax
rm Fairy-Max/data/*
rmdir Fairy-Max/data
rm Fairy-Max/*