#DIRS=skalar skalar_stl jacobi generate_mesh jacobi_oo_stl
DIRS=skalar skalar_stl jacobi jacobi_oo_stl thread_17 densematrices_libs generate_mesh mgrid
#
#WWW_ROOT=${HOME}/public_html/Lectures/Math2CPP/Codes/seq
WWW_ROOT=../../html/Codes/seq


clean:
	@for i in ${DIRS}; do cd $${i}; make clean_all; cd ..; done
#	rm *.tar

doc:
	@for i in ${DIRS}; do cd $${i}; make doc; cd ..; done

tar:
	@for i in ${DIRS}; do cd $${i}; make tar; cd ..; done

zip:
	@for i in ${DIRS}; do cd $${i}; make zip; cd ..; done

www: clean tar zip doc
	mkdir -p ${WWW_ROOT}
	cp -up *_default.mk ${WWW_ROOT}
	@for i in ${DIRS};\
	do \
	  mv $${i}.tar $${i}.zip ${WWW_ROOT}; \
	  cp -rup $${i} ${WWW_ROOT}; 	\
	  done


#	@for i in ${DIRS};\
#	do \
#	  tar -czf $${i}.tgz $${i} *default*.mk; \
#	  mv $${i}.tgz  ${WWW_ROOT}; \
#	  cp -r $${i} ${WWW_ROOT}; 	\
#	  find $${i} -name html -exec cp -r {} ${WWW_ROOT}/$${i}  \; ; done
