
default:

wc:
ifdef IS_DOS
	wc -l *.el c:/home/lisp++-projects/*.el c:/home/hairy-lemon/src/50webs-com/research/2016/c2java-1.21/*.el c:/home/hairy-lemon/src/50webs-com/J.T.W/gnu-java-training-wheels/install-stuff/*.el experimental/*.el
else
	wc -l *.el /media/www/C1TB/home/lisp++-projects/*.el ~/c2java/*.el ~/gnu-java-training-wheels/install-stuff/*.el experimental/*.el
endif

test-htmlize:
	emacs --batch --eval "(setq target \"a.cc\")" --load d-htmlize.el

test-sound:
	emacs --batch --load "random-play-emacs-midi.el"

etags:
	etags a.php *.el imported-stuff/*.el

htags:
	etags a.htm

BAK = $(HOME)/bak
DATESTAMP = $$(date +"%Y%m%d-%H%M%S")
SHELL = /bin/bash

ifdef IS_DOS
tar:
	rm -fv *.el~ #*#
	rm -fv */*.el~ */#*#
	rm -fv */*/*.el~ */*/#*#
	cp -upv c:/home/.emacs c:/home/dlisp/dotemacs-dos-emacs.el
	cd .. && tar -cvf dlisp.tar dlisp;
	cd .. && gzip -fv dlisp.tar;
	-mkdir -p c:/davinpearson-com/binaries
	-mkdir -p f:/davinpearson-com/binaries
	-mkdir -p g:/davinpearson-com/binaries
	-mkdir -p h:/davinpearson-com/binaries
	-mkdir -p i:/davinpearson-com/binaries
	-mkdir -p j:/davinpearson-com/binaries
	-mkdir -p k:/davinpearson-com/binaries
	-cd .. && cp -upv  dlisp.tar.gz ~/hairy-lemon/output/davinpearson-com/binaries/dlisp.tar.gz
	-cd .. && cp -upv dlisp.tar.gz c:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz f:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz g:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz h:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz i:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz j:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz k:/davinpearson-com/binaries/dlisp-$(DATESTAMP).tar.gz
	-mkdir -p c:/home/bak
	-mkdir -p f:/home/bak
	-mkdir -p g:/home/bak
	-mkdir -p h:/home/bak
	-mkdir -p i:/home/bak
	-mkdir -p j:/home/bak
	-mkdir -p k:/home/bak
	-cd .. && cp -upv dlisp.tar.gz c:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz f:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz g:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz h:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz i:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz j:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && cp -upv dlisp.tar.gz k:/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd .. && rm -f dlisp.tar.gz
else
tar:
	rm -fv *.el~ #*#
	rm -fv */*.el~ */#*#
	rm -fv */*/*.el~ */*/#*#
	cp -upv /media/www/C1TB/home/.emacs /media/www/C1TB/home/dlisp/dotemacs-dos-emacs.el
	cp -upv ~/.emacs                    /media/www/C1TB/home/dlisp/dotemacs-unix-emacs.el
	cd /media/www/C1TB/home && tar -cvf dlisp.tar dlisp/*;
	cd /media/www/C1TB/home && gzip -fv dlisp.tar
	cd /media/www/C1TB/home && cp -upv  dlisp.tar.gz ~/bak/dlisp-$(DATESTAMP).tar.gz
	cd /media/www/C1TB/home && cp -upv  dlisp.tar.gz ~/hairy-lemon/output/davinpearson-com/binaries/dlisp.tar.gz
	-mkdir -p /media/www/F2TB/davinpearson-com/binaries
	-mkdir -p /media/www/G16GB/davinpearson-com/binaries
	-mkdir -p /media/www/I16GB/davinpearson-com/binaries
	-mkdir -p /media/www/K2TB/davinpearson-com/binaries
	-mkdir -p /media/www/BLU16GB/davinpearson-com/binaries
	-mkdir -p /media/www/CYN16GB/davinpearson-com/binaries
	-mkdir -p /media/www/GRN16GB/davinpearson-com/binaries
	-mkdir -p /media/www/WD2TB/davinpearson-com/binaries
	-mkdir -p /media/www/WD2TB2/davinpearson-com/binaries
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/F2TB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/G16GB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/I16GB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/K2TB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/BLU16GB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/CYN16GB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/GRN16GB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/WD2TB/davinpearson-com/binaries/dlisp.tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/WD2TB2/davinpearson-com/binaries/dlisp.tar.gz
	-mkdir -p /media/www/F2TB/home/bak
	-mkdir -p /media/www/G16GB/home/bak
	-mkdir -p /media/www/K2TB/home/bak
	-mkdir -p /media/www/BLU16GB/home/bak
	-mkdir -p /media/www/CYN16GB/home/bak
	-mkdir -p /media/www/GRN16GB/home/bak
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/C1TB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/F2TB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/G16GB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/I16GB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/K2TB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/BLU16GB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/CYN16GB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/GRN16GB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/WD2TB/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz /media/www/WD2TB2/home/bak/dlisp-$(DATESTAMP).tar.gz
	-cd /media/www/C1TB/home && cp -upv dlisp.tar.gz $(BAK)/dlisp-$(DATESTAMP).tar.gz
	cd /media/www/C1TB/home && rm -fv dlisp.tar.gz
endif

wagner:
	cd ~/C; tar -cvf ~/bak/wagner.tar wagners-ring-cycle-old*/download-ring-cycle-whole.bat wagners-ring-cycle-old*/order.html wagners-ring-cycle-old*/track-list.txt
	gzip -fv ~/bak/wagner.tar
	mv -fv ~/bak/wagner.tar.gz ~/bak/wagner-$(DATESTAMP).tar.gz

jtw:
	emacs --batch --load ~/dlisp/jtw-mode.el --funcall doit


