#! /bin/csh -f ########################################################################### # PROJECT: DEMETER # MODULE: GENERATION # FILE: generate # SYSTEM: UNIX 4.3 BSD on sun #-------------------------------------------------------------------------- # COPYRIGHT (c) 1990-1993 Northeastern University # Prof. Karl J. Lieberherr #-------------------------------------------------------------------------- # AUTHOR: Walter Hursch # # #-------------------------------------------------------------------------- # DESCRIPTION: # This is the script file for the Demeter C++ generators. It is invoked # by the command: # # generate { SI | MI } # # Generate creates a Demeter environment for a class-dictionary (cd). # It also regenerates already existing environments correctly after # the cd has been updated. The environment has the following structure: # ########################################################################### #--------------------------------------------------------------------------- # command line evaluation #--------------------------------------------------------------------------- # Test usage if ($#argv != 3) then echo "Usage: generate { SI | MI} TOPENVNAME NOCONSTRUCTOR" exit (1) endif # Evaluation switch ($argv[1]) case "MI": case "SI": breaksw default: echo "Usage: generate { SI | MI} TOPENVNAME NOCONSTRUCTOR" exit (1) endsw if (! -f notmod/cds/cd-param-exp) then echo "Generate error: Cannot find class dictionary." echo "Make sure you are in directory TOP and have run sem-check -i" echo "" exit (1) endif set PROGRAM = $0 set PROGRAM_NAME = $PROGRAM:t set PROGRAM_DIR = $PROGRAM:h setenv GEN_DIR $PROGRAM_DIR/util/$PROGRAM_NAME $GEN_DIR/`get-cpu`/run-exec $1 $2 "$3" if ($status) exit (1)