# Makefile for the galaxis game
# Note: When the version changes, you also have to change
-# * the name of the containing directory
-# * the RPM spec file
-V=1.1
+# the RPM spec file and the LSM.
+VERS=1.2
# Flags for use with the Linux ncurses package (recommended)
CFLAGS = -g -DNDEBUG # -I/usr/local/include -L/usr/local/lib
$(CC) $(CFLAGS) -o galaxis galaxis.c $(TERMLIB)
clean:
- rm -f galaxis galaxis.shar *~
+ rm -f galaxis galaxis.shar galaxis-*.rpm galaxis-*.tar.gz *~
SOURCES = READ.ME galaxis.c Makefile galaxis.6 galaxis.lsm galaxis.spec
-galaxis.shar:
- shar $(SOURCES) >galaxis.shar
-
-galaxis.tar.gz:
- (cd ..; tar -cvf galaxis-$(V)/galaxis.tar `echo $(SOURCES) | sed "/\(^\| \)/s// galaxis-$(V)\//g"`)
- gzip -f galaxis.tar
-
-rpm: galaxis.tar.gz
- cp galaxis.tar.gz /usr/src/SOURCES/galaxis-$(V).tar.gz
- cp galaxis.spec /usr/src/SPECS/galaxis-$(V)-1.spec
- rpm -ba galaxis-$(V)-1.spec
+galaxis-$(VERS).tar.gz: $(SOURCES)
+ @ls $(SOURCES) | sed s:^:galaxis-$(VERS)/: >MANIFEST
+ @(cd ..; ln -s galaxis galaxis-$(VERS))
+ (cd ..; tar -czvf galaxis/galaxis-$(VERS).tar.gz `cat galaxis/MANIFEST`)
+ @(cd ..; rm galaxis-$(VERS))
+
+galaxis-$(VERS).shar:
+ shar $(SOURCES) >galaxis-$(VERS).shar
+
+dist: galaxis-$(VERS).tar.gz
+
+RPMROOT=/usr/src/redhat
+RPM = rpm
+RPMFLAGS = -ba
+rpm: dist
+ cp galaxis-$(VERS).tar.gz $(RPMROOT)/SOURCES;
+ cp galaxis.spec $(RPMROOT)/SPECS
+ cd $(RPMROOT)/SPECS; $(RPM) $(RPMFLAGS) galaxis.spec
+ cp $(RPMROOT)/RPMS/`arch|sed 's/i[4-9]86/i386/'`/galaxis-$(VERS)*.rpm .
+ cp $(RPMROOT)/SRPMS/galaxis-$(VERS)*.src.rpm .
galaxis.6 -- a trivial man page
Send bug reports to esr@snark.thyrsus.com. Also, see my WWW home page
-at http://www.ccil.org/~esr/home.html for updates and other resources.
+at http://www.tuxedo.org/~esr/index.html for updates and other resources.
+
+Version 1.2: Fri Jul 28 16:05:25 EDT 2000
+ * Update to modern RPM tools.
+
+Version 1.1: Sun Oct 23 1994
+ * Initial release.