X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?p=xscreensaver;a=blobdiff_plain;f=Makefile.in;h=99b6f4a257bb5abef0f2deb39794dd6ab717bc7c;hp=2ae53cafda62955b2dfc6a692aba0b986097ead3;hb=6b1c86cf395f59389e4ece4ea8f4bea2c332745b;hpb=3f438031d610c7e15fd33876a879b97e290e05fb diff --git a/Makefile.in b/Makefile.in index 2ae53caf..99b6f4a2 100644 --- a/Makefile.in +++ b/Makefile.in @@ -7,16 +7,19 @@ VPATH = @srcdir@ SHELL = /bin/sh SUBDIRS = utils driver hacks hacks/glx po -TARFILES = README README.VMS README.debugging INSTALL \ +SUBDIRS2 = $(SUBDIRS) OSX +TARFILES = README README.hacking README.VMS INSTALL \ configure configure.in Makefile.in config.h.in \ config.h-vms install-sh setup.com config.guess aclocal.m4 \ config.sub makevms.com \ intltool-merge.in intltool-extract.in intltool-update.in \ xscreensaver.spec \ + xscreensaver.xcodeproj/project.pbxproj TAR = tar -MAKE_SUBDIR = for dir in $(SUBDIRS); do (cd $$dir; $(MAKE) $@) || exit 5; done +MAKE_SUBDIR = for dir in $(SUBDIRS); do (cd $$dir; $(MAKE) $@) || exit 5; done +MAKE_SUBDIR2 = for dir in $(SUBDIRS2);do (cd $$dir; $(MAKE) $@) || exit 5; done default:: @$(MAKE_SUBDIR) @@ -40,17 +43,19 @@ depend:: @$(MAKE_SUBDIR) distdepend:: @$(MAKE) update_spec_version - @$(MAKE_SUBDIR) + @$(MAKE_SUBDIR2) @cd po ; $(MAKE) generate_potfiles_in TAGS:: tags tags:: @$(MAKE_SUBDIR) + clean:: - @$(MAKE_SUBDIR) + @$(MAKE_SUBDIR2) + distclean:: clean -rm -f config.h Makefile config.status config.cache config.log TAGS *~ "#"* intltool-extract intltool-merge intltool-update - @$(MAKE_SUBDIR) + @$(MAKE_SUBDIR2) dist:: tar @@ -60,14 +65,13 @@ tar:: sh config.status ; \ rm -f configure ; \ $(MAKE) configure ; \ - $(MAKE) distdepend ; \ - NAME=`sed -n \ - 's/[^0-9]*\([0-9]\.[0-9][0-9]*[0-9]*\).*/xscreensaver-\1/p' \ - utils/version.h` ; \ + $(MAKE) version-date distdepend ; \ + VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][^. ]*\).*/\1/p' utils/version.h` ; \ + NAME="xscreensaver-$$VERS" ; \ rm -rf $$NAME ; ln -s . $$NAME ; \ FILES= ; \ ADIR=archive/ ; \ - for subdir in $(SUBDIRS) ; do \ + for subdir in $(SUBDIRS2) ; do \ d=`pwd` ; \ cd $$subdir ; \ FILES="$$FILES `$(MAKE) echo_tarfiles \ @@ -117,6 +121,8 @@ configure:: \ s@mandir=.\$${prefix}/man.@mandir=\\\$${datadir}/man@; \ \ + s@rm -f conftest@rm -rf conftest@g; \ + \ print;' \ < configure \ > $$TMP && \ @@ -139,7 +145,7 @@ bump-version:: if [ -f $${ADIR}xscreensaver-$$MAJOR.$$NEW.tar.gz ]; then \ echo "WARNING: $${ADIR}xscreensaver-$$MAJOR.$$NEW.tar.gz already exists.";\ fi ; \ - echo -n "Bumping $$MAJOR.$$MINOR to $$MAJOR.$$NEW ($$D), ok? "; \ + /bin/echo -n "Bumping $$MAJOR.$$MINOR to $$MAJOR.$$NEW ($$D), ok? "; \ read line; \ if [ "x$$line" != "xyes" -a "x$$line" != "xy" ]; then \ exit 1 ; \ @@ -148,7 +154,7 @@ bump-version:: sed -e "s/\([0-9]\.[0-9][0-9]*\)/$$MAJOR.$$NEW/" \ -e "s/\(([0-9][0-9]*-[A-Za-z][a-z][a-z]-[0-9][0-9][0-9]*\))/($$D)/" \ $$SRC > $$TMP ; \ - echo -n "New version and date are "; \ + /bin/echo -n "New version and date are "; \ sed -n "s/[^0-9]*\([0-9]\.[0-9][0-9]*\) (\([-A-Za-z0-9]*\)).*/\1, \2./p" \ $$TMP; \ cat $$TMP > $$SRC ; \ @@ -160,11 +166,27 @@ bump_version:: bump-version tick-version:: bump-version tick_version:: bump-version +version-date:: + @ \ + SRC=utils/version.h ; \ + D=`date '+%d-%b-%Y'`; \ + TMP=/tmp/bv.$$ ; \ + sed -e "s/([0-9][^()]*)/($$D)/" < $$SRC > $$TMP ; \ + /bin/echo -n "Updating date in $$SRC to \"$$D\"... " ; \ + if cmp -s $$SRC $$TMP ; then \ + echo "unchanged." ; \ + else \ + cat $$TMP > $$SRC ; \ + echo "done." ; \ + fi ; \ + rm -f $$TMP + + update_spec_version:: @S=$(srcdir)/xscreensaver.spec ; \ U=$(srcdir)/utils/version.h ; \ VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][^. ]*\).*/\1/p' < $$U` ; \ - echo -n "Updating $$S to \"$$VERS\"... " ; \ + /bin/echo -n "Updating $$S to \"$$VERS\"... " ; \ T=/tmp/xs.$$$$ ; \ sed "s/^\(%define.version[^0-9]*\)\(.*\)/\1$$VERS/" \ < $$S > $$T ; \ @@ -208,7 +230,7 @@ rpm:: test-tar:: @ \ - VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][^. ]*\).*/\1/p' utils/version.h` ; \ + VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][^. ]*\).*/\1/p' utils/version.h` ; \ D=xscreensaver-$$VERS ; \ ADIR=archive/ ; \ NAME="$${ADIR}$$D.tar.gz" ; \ @@ -254,41 +276,58 @@ test-tar:: \ chmod -R u+w . +dmg:: + cd OSX ; $(MAKE) release dmg www:: @ \ DEST=$$HOME/www/xscreensaver ; \ - VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][^. ]*\).*/\1/p' utils/version.h` ; \ + VERS=`sed -n 's/[^0-9]*\([0-9]\.[0-9][^. ]*\).*/\1/p' utils/version.h` ; \ HEAD="xscreensaver-$$VERS" ; \ ADIR=archive/ ; \ BNAME="$$HEAD.tar.gz" ; \ NAME="$$ADIR$$BNAME" ; \ DNAME="$$DEST/$$HEAD.tar.gz" ; \ + BNAME2="$$HEAD.dmg" ; \ + NAME2="$$ADIR$$BNAME2" ; \ + DNAME2="$$DEST/$$HEAD.dmg" ; \ \ if [ ! -f $$NAME ]; then \ echo "$$NAME does not exist! Did you forget to \`make tar'?" ; \ exit 1 ; \ fi ; \ + if [ ! -f $$NAME2 ]; then \ + echo "$$NAME2 does not exist! Did you forget to \`make dmg'?" ; \ + exit 1 ; \ + fi ; \ chmod a-w $$NAME ; \ if [ -f $$DNAME ]; then \ - echo -n "WARNING: $$DNAME already exists! Overwrite? "; \ + /bin/echo -n "WARNING: $$DNAME already exists! Overwrite? "; \ + read line; \ + if [ "x$$line" != "xyes" -a "x$$line" != "xy" ]; then \ + exit 1 ; \ + fi ; \ + fi ; \ + if [ -f $$DNAME2 ]; then \ + /bin/echo -n "WARNING: $$DNAME2 already exists! Overwrite? "; \ read line; \ if [ "x$$line" != "xyes" -a "x$$line" != "xy" ]; then \ exit 1 ; \ fi ; \ fi ; \ cp -p $$NAME $$DNAME ; \ - chmod u+w $$DNAME ; \ + cp -p $$NAME2 $$DNAME2 ; \ + chmod u+w $$DNAME $$DNAME2 ; \ cd $$DEST ; \ \ TMP=/tmp/xd.$$$$ ; \ - sed "s/xscreensaver-[0-9]\.[0-9][0-9]*/$$HEAD/g" download.html > $$TMP ; \ + sed "s/xscreensaver-5\.[0-9][0-9ab]*/$$HEAD/g" download.html > $$TMP ; \ echo '' ; \ diff -U0 download.html $$TMP ; \ echo '' ; \ \ OLDEST=`ls xscreensaver*.tar.gz | head -1` ; \ - echo -n "Delete $$DEST/$$OLDEST? "; \ + /bin/echo -n "Delete $$DEST/$$OLDEST? "; \ read line; \ if [ "x$$line" = "xyes" -o "x$$line" = "xy" ]; then \ set -x ; \ @@ -297,15 +336,16 @@ www:: else \ set -x ; \ fi ; \ - cvs add -kb $$BNAME ; \ + cvs add -kb $$BNAME $$BNAME2 ; \ cat $$TMP > download.html ; \ rm -f $$TMP ; \ \ - (cd ..; $(MAKE) xscreensaver/changelog.html ); \ + (cd ..; $(MAKE) xscreensaver/changelog.html \ + xscreensaver/screenshots/index.html ); \ cvs diff -U0 changelog.html ; \ set +x ; \ \ - echo -n "Ok? "; \ + /bin/echo -n "Ok? "; \ read line; \ if [ "x$$line" != "xyes" -a "x$$line" != "xy" ]; then \ exit 1 ; \ @@ -332,7 +372,7 @@ check_years:: count:: @ \ - echo -n "Current hack count: " ; \ + /bin/echo -n "Current hack count: " ; \ ( ( cd hacks; make -s INSTALL=true install-program install-scripts ) ; \ ( cd hacks/glx; make -s INSTALL=true install-program ) ) | \ grep true | \