/*
 * generic imake template
 */

/**/#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
/**/# This Makefile was generated automatically from Imakefile, using imake,
/**/# which is provided as part of the X Windows distribution. imake was
/**/# written by Todd Brunhoff and Jim Fulton from the Mit X Consortium.
/**/#
/**/# The rules for turning an Imakefile into a Makefile are located in
/**/# conf/Imake.tmpl and conf/Imake.rules. Platform specific parameters
/**/# are set in the .cf files. Site specific parameters are set in the
/**/# system's CONFIG file. Rules and templates for RCCL/RCI created by 
/**/# John Lloyd, McGill University, November 27, 1990.
/**/#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

#define	YES	1
#define NO	0

#include <site.conf>
#include <defaults.conf>

/* Defining VxWorksConfig overrides the default target configuration */
#if VxWorksConfig
#undef TargetSystem
#define TargetSystem "VXWORKS_CFG"
#undef uVaxConfig
#undef Sun4Config
#undef SgiConfig
#undef LinuxConfig
#undef SimonlyConfig
#endif /* VxWorksConfig */

/* Commands ... */

      TARGET_DEFS = -D/**/TargetSystem
              RCC = rcc
#if VxWorksConfig
               CC = VxwCcCmd
               LD = VxwLdCmd
             LDIR = ../../lib
             BDIR = ../../bin
#else
               CC = CcCmd
               LD = ld
             LDIR = ../lib
             BDIR = ../bin
#endif
/*           MAKE = MakeCmd */
#if HasFortran
             FCMD = FortranCmd
            FLIBS = FortranLibs
#else
             FCMD = undefined
#endif
            RMCMD = /bin/rm -f
        JUNKFILES = *.BAK .*.BAK *~ *.CKP .*.CKP \\\#* *.o *.to *.tO core makelog

/* Includes, options, and libraries ... */

#if defined(IrixArch) && !defined(VxWorksConfig)
            CLIBS = -lbsd
#endif
#if VxWorksConfig
C_INCS := VxwCcInclude -I$$RCCL/h -I$$RCCL/h/vxWorks
C_DEFS := VxwCcDefines $(TARGET_DEFS) -D$(EMPTY)VxWorksVersion
C_OPNS := VxwCcOptions
#else
C_INCS := CcInclude
C_DEFS := CcDefines $(TARGET_DEFS)
C_OPNS := CcOptions FpuOption
#endif
#ifdef SystemSiteName
C_DEFS := $(C_DEFS) -D/**/SystemSiteName
#endif
       RCC_CFLAGS = $(C_OPNS) $(C_INCS) $(C_DEFS) $(TRACE)

            LUSER = $(LDIR)/rciUser.a
            LCTRL = $(LDIR)/rciCtrl.a
            LPUMA = $(LDIR)/libPuma.a
#ifdef uVaxConfig            
            LAUXK = $(LDIR)/libAux.a
#else
            LAUXK =
#endif
            LLIBC = $(LDIR)/libC.a
           LCTREE = $(LDIR)/libCtree.a   
 VOLATILE_RCILIBS = $(LUSER) $(LCTRL)
      ALL_RCILIBS = $(LUSER) $(LCTREE) $(LCTRL) $(LAUXK) $(LLIBC)

#include <Imake.rules>

.SUFFIXES:	.to .tO

.c.to:
	compileShadow($^,$*.o,$*.to,$(CC) $(CFLAGS) -c -DTEST)
.c.tO:
	compileShadow($^,$*.o,$*.tO,$(RCC) $(CFLAGS) -c -DTEST CTRL)

ULIST :=
CLIST :=
PLIST :=
UOBJS :=
COBJS :=
POBJS :=
UTARGS :=
VXWLO :=
VXWBO :=

define CheckForVXWDir
	if [ ! -d VXW ] ; then
	   if [ -f VXW ] ; then
	      echo error: VXW exits, but is not a directory; exit 1
	   fi
	   echo mkdir VXW
	   mkdir VXW
	fi
endef

#ifdef LinuxConfig            
            RTLDIR = RTLinuxDir
#endif

/**/#=-=-=-=-=-=-=-=-=-=-=-=- Imakefile starts here -=-=-=-=-=-=-=-=-=-=-=-=-=
#include INCLUDE_IMAKEFILE
/**/#=-=-=-=-=-=-=-=-=-=-=-=-= Imakefile ends here =-=-=-=-=-=-=-=-=-=-=-=-=-=

depend::
	
clean::

/* The line below was used by the old (non-GNU) "make depend". */
/**/# XXX line used by make depend - DO NOT DELETE XXX
