SHELL=/bin/sh include ./Makefile.def SUBDIR = doc ddl INSTALLSUBDIR = cutver all: @ echo make the required executables. @ ( cd ddl; make all ) convert: @ echo running the database conversion. @ if [ "$(PRODDIR)" = "" ]; then \ echo "The destination directory for convert has not been specified. Set the environment" >&2; \ echo "variable $(PRODDIRNAME)" >&2; \ echo ""; \ exit 1; \ fi @ ( cd cutver; pwd; convert.als_db ${version} ${user} ${version} ) publish: @ echo publish target does nothing for misweb clean: clean_dir @ for subdir in $(SUBDIR); do \ if [ -d $$subdir ]; then \ (cd $$subdir; echo ""; echo "make clean in ./$$subdir"; echo ""; $(MAKE) $(MFLAGS) clean); \ else \ echo "Subdirectory does not exist: ./$$subdir"; \ fi; \ done # This is a very simple-minded install that just # copy ALL the files here in the target area. # in order to not copy rotten files we first clean :( install : clean @ echo "" @ echo "Make sure the current $(PROD) directories under" @ echo "" @ echo " `pwd`" @ echo "" @ echo "have the latest versions of the files. These will be copied to the" @ echo "the destination during the install of $(PROD)." @ echo "" @ if [ "$(PRODDIR)" = "" ]; then \ echo "The destination directory has not been specified. Set the environment" >&2; \ echo "variable $(PRODDIRNAME)" >&2; \ echo ""; \ exit 1; \ fi @ - if [ `(cd $(PRODDIR); pwd)` = `pwd` ]; then \ echo "The destination directory is the same as the current directory." >&2; \ echo "The install will be aborted." >&2; \ echo ""; \ exit 1; \ fi @ echo "You will be installing in" @ echo "" @ echo " $(PRODDIRNAME) = $(PRODDIR)" @ echo "" @ echo "\007Is this the correct directory? If yes, hit return. If not, use ^C to cancel. \c" @ read CORRECTDIR @ if [ ! -d $(PRODDIR) ]; then \ mkdir $(PRODDIR); \ fi @ if [ ! -d $(PRODDIR) ]; then \ mkdir $(PRODDIR); \ fi @ for subdir in $(SUBDIR); do \ if [ -d $$subdir ]; then \ if [ ! -r $(PRODDIR)/$$subdir ]; then \ mkdir $(PRODDIR)/$$subdir; \ fi; \ (cd $$subdir; echo ""; echo "copying ./$$subdir"; echo ""; cp -r . $(PRODDIR)/$$subdir); \ else \ echo "Subdirectory does not exist: ./$$subdir"; \ fi; \ done @ for subdir in $(INSTALLSUBDIR); do \ if [ -d $$subdir ]; then \ if [ ! -r $(PRODDIR)/$$subdir ]; then \ mkdir $(PRODDIR)/$$subdir; \ fi; \ (cd $$subdir; echo ""; echo "installing ./$$subdir"; echo ""; $(MAKE) $(MFLAGS) install); \ else \ echo "Subdirectory does not exist: ./$$subdir"; \ fi; \ done @ cp Makefile Makefile.def $(PRODDIR) @ echo publish the server. @ (cd $(PRODDIR); make publish) @ find $(PRODDIR) -name CVS -type d -exec rm -fr {} \;