# This file is included by the makefile. # It forwards the execution to a version specific makefile. # S_DOWN, S_UP and SICS_VERSION must be defined # M. Zolliker 08.2003 VERS_UNDEFINED= VERS_UNDEFINED$(SICS_VERSION)=version_undefined SICS_ROOT=$(PWD)/$(S_UP) OBJROOT=$(SICS_ROOT)/obj/$(SICS_VERSION) MD=cd $(OBJROOT)/$(S_DOWN); \ make -f $(SRC)makefile_$(SICS_VERSION) SRC=$(SRC) #define TREE only when version defined TREE$(VERS_UNDEFINED)=$(OBJROOT)/tree # overwrite MD when SICS_VERSION undefined MD$(SICS_VERSION)=@ true SRC=src/ .SUFFIXES: .none default: $(VERS_UNDEFINED) $(TREE) $(MD) %.o: $(VERS_UNDEFINED) $(TREE) $(MD) $@ %: $(VERS_UNDEFINED) $(TREE) $(MD) $@ .DEFAULT: $(VERS_UNDEFINED) $(TREE) $(MD) $@ makefile: @ echo makefile tree: $(TREE) @ true $(TREE): @ $(VERS_UNDEFINED) test 1 @ echo --- Make object tree --- @ $(SICS_ROOT)/maketree . @ $(SICS_ROOT)/maketree matrix @ $(SICS_ROOT)/maketree dummy @ $(SICS_ROOT)/maketree psi @ $(SICS_ROOT)/maketree psi/hardsup @ $(SICS_ROOT)/maketree psi/utils @ $(SICS_ROOT)/maketree psi/tecs touch $(TREE) @ echo --- End object tree --- cleanall: $(MD:makfil=makefile_alpha) clean $(MD:makfil=makefile_alpha_dummy) clean version_undefined: @ echo "" @ echo "Usage:" @ echo "" @ echo "Creating objects and targets mixed up with sources:" @ echo "" @ echo " make -f makefile_xxx [target]" @ echo "" @ echo ' where makefile_xxx is one of' @ echo "" @ ls -1 makefile_* | pr -t -o 4 @ echo "" @ echo "Creating objects and targets in separate subdirectories" @ echo "" @ echo " setenv SICS_VERSION version_xxx (assume we are using tcsh)" @ echo " make [target]" @ echo "" @ echo " where version_xxx is one of" @ echo "" @ ls -1 makefile_* | cut -b 10-99 | pr -t -o 4 @ echo "" @ echo " Remarks:" @ echo " All objects for alpha version will be created in subdirectory obj/alpha/," @ echo " SICServer is also found there." @ echo " Tip: define SICS_VERSION at login" @ echo ""