-# Makefile.in --- xscreensaver, Copyright (c) 1997 Jamie Zawinski.
+# Makefile.in --- xscreensaver, Copyright (c) 1999 Jamie Zawinski.
# the `../configure' script generates `Makefile' from this file.
@SET_MAKE@
configure configure.in Makefile.in config.h.in \
config.h-vms install-sh setup.com config.guess \
config.sub makevms.com screenblank.txt \
- xscreensaver.lsm.sh
+ xscreensaver.lsm.sh xscreensaver.spec
TAR = tar
COMPRESS = gzip --verbose --best
COMPRESS_EXT = gz
depend:
@$(MAKE_SUBDIR)
distdepend:
+ @$(MAKE) update_spec_version
@$(MAKE_SUBDIR)
TAGS: tags
tags:
# nearly impossible to customize --help blurb. This horrid set of regexps
# go through and clean up the help text, by inserting whitespace and ripping
# out options we don't use. Odds are good that this will fail with any version
-# of autoconf other than 2.12.
+# of autoconf other than the ones I've tried (2.12 and 2.13.)
#
configure::
autoconf
echo "overwrote $$SRC"; \
ls -lFd $$SRC
+update_spec_version::
+ @S=$(srcdir)/xscreensaver.spec ; \
+ U=$(srcdir)/utils/version.h ; \
+ V=`sed -n 's/.*\([0-9][0-9]*\.[0-9]*\).*/\1/p' < $$U` ; \
+ echo -n "Updating version number in $$S to \"$$V\"... " ; \
+ T=/tmp/xs.$$$$ ; \
+ sed "s/^\(Version:[^0-9]*\)\(.*\)/\1$$V/" \
+ < $$S > $$T ; \
+ if cmp -s $$S $$T ; then \
+ echo "unchanged." ; \
+ else \
+ cat $$T > $$S ; \
+ echo "done." ; \
+ fi ; \
+ rm $$T
+
+rpm::
+ @ \
+ VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][0-9]*\).*/\1/p' utils/version.h` ; \
+ cp -p xscreensaver-$$VERS.tar.gz /usr/src/redhat/SOURCES/ ; \
+ rpm -ba xscreensaver.spec
+
test-tar::
@ \
VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][0-9]*\).*/\1/p' utils/version.h` ; \
( cd BIN/motif ; \
CC=cc ; \
export CC ; \
- ../../configure --with-motif=/usr/local/motif ; \
+ ../../configure --without-xpm --with-motif=/usr/local/motif ; \
echo --------------------------------------------------------------- ; \
- ( cd utils; gmake ) ; \
- ( cd driver; gmake ) ; \
+ gmake ; \
( cd driver; gmake xscreensaver-demo-Xaw ) ; \
echo --------------------------------------------------------------- ); \
\