[298] in Kerberos-V5-bugs

home help back first fref pref prev next nref lref last post

imake-reorg.patch

daemon@ATHENA.MIT.EDU (Marc Horowitz)
Fri Feb 26 17:55:58 1993

To: krb5-bugs@MIT.EDU
Date: Fri, 26 Feb 1993 17:51:31 -0500
From: Marc Horowitz <marc@Aktis.COM>

** Imake system reorganization

./config/Project.tmpl
./config/Imake.tmpl
./config/Imake.rules
	(Project.tmpl patch relative to Steve Lunt's changes)
	Many, many changes and improvements to the general imake setup.
	Many changes and files stoken from X11R5.


*** ./config/Project.tmpl.old	1992/11/10 18:53:02
--- ./config/Project.tmpl	1993/01/03 21:24:55
***************
*** 73,87 ****
  #define DesDefines YouMustFigureOutYourDesDefines
  #endif
  #ifndef Krb5Root
! #define Krb5Root	/krb5
  #endif
  
  #ifndef PepsyTarget
  #define	PepsyTarget(basename)						@@\
  .SUFFIXES:	.py							@@\
! basename/**/_defs.h basename/**/_pre_defs.h basename-types.h basename/**/_tables.c: basename-asn.py					@@\
! 	@echo '***Ignore the warning message "Warning\: Can'\''t find UNIV.ph failed"' @@\
! 	$(PEPSY) $(PSYFLAGS) $(SRCDIR)basename-asn.py
  #endif /* PepsyTarget */
  
  #ifndef ErrorTableObjectRule
--- 73,146 ----
  #define DesDefines YouMustFigureOutYourDesDefines
  #endif
  #ifndef Krb5Root
! #define Krb5Root	/usr/local/krb5
  #endif
+ #ifndef Krb5Manroot
+ #define Krb5Manroot	$(KRB5ROOT)/man
+ #endif
+ #ifndef AdminManSuffix
+ #define AdminManSuffix 8
+ #endif
+ #ifndef AdminMandir
+ #define AdminMandir $(KRB5MANROOT)/man$(ADMIN_MANSUFFIX)
+ #endif
+ #ifndef ServerManSuffix
+ #define ServerManSuffix 8
+ #endif
+ #ifndef ServerMandir
+ #define ServerMandir $(KRB5MANROOT)/man$(SERVER_MANSUFFIX)
+ #endif
+ #ifndef ClientManSuffix
+ #define ClientManSuffix 1
+ #endif
+ #ifndef ClientMandir
+ #define ClientMandir $(KRB5MANROOT)/man$(CLIENT_MANSUFFIX)
+ #endif
+ #ifndef FileManSuffix
+ #define FileManSuffix 5
+ #endif
+ #ifndef FileMandir
+ #define FileMandir $(KRB5MANROOT)/man$(FILE_MANSUFFIX)
+ #endif
+ #ifndef AdminBindir
+ #define AdminBindir $(KRB5ROOT)/admin
+ #endif
+ #ifndef ServerBindir
+ #define ServerBindir $(KRB5ROOT)/sbin
+ #endif
+ #ifndef ClientBindir
+ #define ClientBindir $(KRB5ROOT)/bin
+ #endif
+ #ifndef Krb5Libdir
+ #define	Krb5Libdir $(KRB5ROOT)/lib
+ #endif
+ #ifndef Krb5Incdir
+ #define	Krb5Incdir $(KRB5ROOT)/include
+ #endif
+ #ifndef Krb5Othermkdirs
+ #define Krb5Othermkdirs
+ #endif
+ #ifndef Krb5Srvtabdir
+ #define Krb5Srvtabdir /etc
+ #endif
+ 
+ #if HasNdbm
+ #define DbmLib
+ #else
+ #define DbmLib -ldbm
+ #endif
+ 
+ /* Hack around sun cpp bug */
  
+ PEPSY_WARNING_STRING = \
+ 	@echo '***Ignore the warning message "Warning: Can'"'"'t find UNIV.ph failed"'
+ 
  #ifndef PepsyTarget
  #define	PepsyTarget(basename)						@@\
  .SUFFIXES:	.py							@@\
! Concat(basename,_defs.h) Concat(basename,_pre_defs.h) Concat(basename,-types.h) Concat(basename,_tables.c): Concat(basename,-asn.py)			@@\
! 	$(PEPSY_WARNING_STRING)						@@\
! 	$(PEPSY) $(PSYFLAGS) Concat3($(SRCDIR),basename,-asn.py)
  #endif /* PepsyTarget */
  
  #ifndef ErrorTableObjectRule
***************
*** 114,120 ****
  
  #ifndef SharedLibraryTarget
  #define SharedLibraryTarget(libname,deps)				@@\
! lib/**/libname.a::
  #endif
  
  /*
--- 173,179 ----
  
  #ifndef SharedLibraryTarget
  #define SharedLibraryTarget(libname,deps)				@@\
! Concat3(lib,libname,.a)::
  #endif
  
  /*
***************
*** 123,150 ****
   */
  #ifndef AdditiveLibraryTarget
  #define	AdditiveLibraryTarget(libname,objlist,deps)			@@\
! AllTarget(lib/**/libname.a)						@@\
! AllTarget(foo/**/libname)						@@\
  DependTarget()								@@\
  									@@\
! foo/**/libname: objlist							@@\
! 	$(ARADD) lib/**/libname.a objlist				@@\
! 	$(TOUCH) foo/**/libname						@@\
! lib/**/libname.a: foo/**/libname					@@\
  	$(RANLIB) $@							@@\
  clean::									@@\
! 	$(RM) foo/**/libname lib/**/libname.a
  #endif /* AdditiveLibraryTarget */
  
  #ifndef RanlibLibraryTarget
  #define	RanlibLibraryTarget(libname,deps)				@@\
! AllTarget(lib/**/libname.a)						@@\
! foo2/**/libname: foo/**/libname						@@\
  	$(TOUCH) $@							@@\
! lib/**/libname.a: foo2/**/libname					@@\
  	$(RANLIB) $@							@@\
  clean::									@@\
! 	$(RM) foo/**/libname foo2/**/libname lib/**/libname.a
  #endif
  
  /*
--- 182,209 ----
   */
  #ifndef AdditiveLibraryTarget
  #define	AdditiveLibraryTarget(libname,objlist,deps)			@@\
! AllTarget(Concat3(lib,libname,.a))					@@\
! AllTarget(Concat(foo,libname))						@@\
  DependTarget()								@@\
  									@@\
! Concat(foo,libname): objlist						@@\
! 	$(ARADD) Concat3(lib,libname,.a) objlist			@@\
! 	$(TOUCH) Concat(foo,libname)					@@\
! Concat3(lib,libname,.a): Concat(foo,libname)				@@\
  	$(RANLIB) $@							@@\
  clean::									@@\
! 	$(RM) Concat(foo,libname) Concat3(lib,libname,.a)
  #endif /* AdditiveLibraryTarget */
  
  #ifndef RanlibLibraryTarget
  #define	RanlibLibraryTarget(libname,deps)				@@\
! AllTarget(Concat3(lib,libname,.a))					@@\
! Concat(foo2,libname): Concat(foo,libname)				@@\
  	$(TOUCH) $@							@@\
! Concat3(lib,libname,.a): Concat(foo2,libname)				@@\
  	$(RANLIB) $@							@@\
  clean::									@@\
! 	$(RM) Concat(foo,libname) Concat(foo2,libname) Concat3(lib,libname,.a)
  #endif
  
  /*
***************
*** 154,170 ****
  #ifndef OtherdirLibraryTarget
  #define	OtherdirLibraryTarget(libdir,libname,objlist)			@@\
  AllTarget(objlist)							@@\
! AllTarget(libdir/lib/**/libname.a)					@@\
! AllTarget(foo/**/libname)						@@\
  									@@\
! libdir/lib/**/libname.a foo/**/libname:	objlist				@@\
! 	$(ARADD) libdir/lib/**/libname.a objlist			@@\
! 	$(TOUCH) foo/**/libname						@@\
! 	$(TOUCH) libdir/foo/**/libname					@@\
  /* The $(RANLIB) is done at the end by the directory itself */		@@\
  									@@\
  clean::									@@\
! 	$(RM) foo/**/libname
  #endif /* OtherdirLibraryTarget */
  
  /*
--- 213,229 ----
  #ifndef OtherdirLibraryTarget
  #define	OtherdirLibraryTarget(libdir,libname,objlist)			@@\
  AllTarget(objlist)							@@\
! AllTarget(Concat4(libdir,/lib,libname,.a))				@@\
! AllTarget(Concat(foo,libname))						@@\
  									@@\
! Concat4(libdir,/lib,libname,.a) Concat(foo,libname):	objlist		@@\
! 	$(ARADD) Concat4(libdir,/lib,libname,.a) objlist		@@\
! 	$(TOUCH) Concat(foo,libname)					@@\
! 	$(TOUCH) Concat3(libdir,/foo,libname)				@@\
  /* The $(RANLIB) is done at the end by the directory itself */		@@\
  									@@\
  clean::									@@\
! 	$(RM) Concat(foo,libname)
  #endif /* OtherdirLibraryTarget */
  
  /*
***************
*** 191,197 ****
     indicating some adjustment of the file took place. */
  #ifndef ProcessStockHeader
  #define ProcessStockHeader(stockname,newname)				@@\
! newname: stockname Makefile						@@\
  	-$(RM) newname.new						@@\
  	-$(UNIFDEF) $(PROCESS_DEFINES) stockname | sed $(PROCESS_REPLACE) >newname.new		@@\
  	if cmp -s newname.new newname ; then true; \			@@\
--- 250,256 ----
     indicating some adjustment of the file took place. */
  #ifndef ProcessStockHeader
  #define ProcessStockHeader(stockname,newname)				@@\
! newname: stockname							@@\
  	-$(RM) newname.new						@@\
  	-$(UNIFDEF) $(PROCESS_DEFINES) stockname | sed $(PROCESS_REPLACE) >newname.new		@@\
  	if cmp -s newname.new newname ; then true; \			@@\
***************
*** 204,225 ****
   */
  #ifndef Krb5LibraryTarget
  #define	Krb5LibraryTarget(libname,objlist)				@@\
! AllTarget(lib/**/libname.a)						@@\
  DependTarget()								@@\
  									@@\
! lib/**/libname.a: objlist						@@\
  	$(RM) $@							@@\
  	$(AR) $@ objlist						@@\
  	$(RANLIB) $@							@@\
! 	$(RM) $(TOPLIBD)/lib/**/libname.a				@@\
! 	$(LN) ../$(CURRENT_DIR)/lib/**/libname.a $(TOP)/lib/lib/**/libname.a
  #endif /* Krb5LibraryTarget */
  
  #ifndef Krb5InstallLibrary
  #define	Krb5InstallLibrary(libname,destdir)				@@\
! install:: lib/**/libname.a						@@\
! 	$(RM) destdir/lib/**/libname.a					@@\
! 	$(CP) lib/**/libname.a destdir/lib/**/libname.a
  #endif
  
  #ifndef Krb5InstallHeaders
--- 263,285 ----
   */
  #ifndef Krb5LibraryTarget
  #define	Krb5LibraryTarget(libname,objlist)				@@\
! AllTarget(Concat3(lib,libname,.a))					@@\
  DependTarget()								@@\
  									@@\
! Concat3(lib,libname,.a): objlist					@@\
  	$(RM) $@							@@\
  	$(AR) $@ objlist						@@\
  	$(RANLIB) $@							@@\
! 	$(RM) Concat3($(TOPLIBD)/lib,libname,.a)			@@\
! 	$(LN) Concat3(../$(CURRENT_DIR)/lib,libname,.a) Concat3($(TOP)/lib/lib,libname,.a)
  #endif /* Krb5LibraryTarget */
  
  #ifndef Krb5InstallLibrary
  #define	Krb5InstallLibrary(libname,destdir)				@@\
! install:: Concat3(lib,libname,.a)					@@\
! 	$(RM) Concat4(destdir,/lib,libname,.a)				@@\
! 	$(CP) Concat3(lib,libname,.a) Concat4(destdir,/lib,libname,.a)	@@\
! 	$(RANLIB) Concat4(destdir,/lib,libname,.a)
  #endif
  
  #ifndef Krb5InstallHeaders
***************
*** 459,471 ****
   */
  
              ARADD = ArAddCmd
- #ifdef SourceTop
-      TOP_INCLUDES = -I$(TOP)/include -I/**/SourceTop/include $(STDC_TOP_INCLUDES)
- #else
       TOP_INCLUDES = -I$(TOP)/include $(STDC_TOP_INCLUDES)
! #endif
          CONFIGSRC = $(TOP)/config
-             ISODE = IsodeDir
           PSYFLAGS = PepsyFlags
              PEPSY = PepsyCmd
              TOUCH = TouchCmd
--- 519,527 ----
   */
  
              ARADD = ArAddCmd
       TOP_INCLUDES = -I$(TOP)/include $(STDC_TOP_INCLUDES)
!    EXTRA_INCLUDES = ExtraIncludes
          CONFIGSRC = $(TOP)/config
           PSYFLAGS = PepsyFlags
              PEPSY = PepsyCmd
              TOUCH = TouchCmd
***************
*** 479,487 ****
           ZEPHLIBS = ZephyrLibs
  #endif
           KRB5ROOT = Krb5Root
  
    PROCESS_DEFINES = $(P_TERMIOS) $(P_FLOCKS) $(P_TYPES) $(P_SIGTYPE) $(P_STRINGH) $(P_BITSIZE) $(P_DBM) $(P_INET) $(P_STDLIBH) $(P_TIME_DEFS) $(P_PROTOS) $(P_NPROTO) $(P_STDARG) $(P_ANSI_STDIO) $(P_VOID) $(P_CONST) $(P_VOLATILE) $(P_UNISTD) $(P_NESTPROTO) -DUnifdefRan
!   PROCESS_REPLACE = -e "s+@KRB5ROOT+$(KRB5ROOT)+"
         DESDEFINES = DesDefines
  #if HasSharedLibraries
            TOPLIBD = $(TOP)/lib/shared
--- 535,545 ----
           ZEPHLIBS = ZephyrLibs
  #endif
           KRB5ROOT = Krb5Root
+     KRB5SRVTABDIR = Krb5Srvtabdir
  
    PROCESS_DEFINES = $(P_TERMIOS) $(P_FLOCKS) $(P_TYPES) $(P_SIGTYPE) $(P_STRINGH) $(P_BITSIZE) $(P_DBM) $(P_INET) $(P_STDLIBH) $(P_TIME_DEFS) $(P_PROTOS) $(P_NPROTO) $(P_STDARG) $(P_ANSI_STDIO) $(P_VOID) $(P_CONST) $(P_VOLATILE) $(P_UNISTD) $(P_NESTPROTO) -DUnifdefRan
!   PROCESS_REPLACE = -e "s+@KRB5ROOT+$(KRB5ROOT)+" \
! 		    -e "s+@KRB5SRVTABDIR+${KRB5SRVTABDIR}+"
         DESDEFINES = DesDefines
  #if HasSharedLibraries
            TOPLIBD = $(TOP)/lib/shared
***************
*** 517,522 ****
--- 575,581 ----
          COMERRLIB = ComErrLib
         COMPILE_ET = CompileEtCmd
  
+       KRB5MANROOT = Krb5Manroot
       ADMIN_BINDIR = AdminBindir
    ADMIN_MANSUFFIX = AdminManSuffix
       ADMIN_MANDIR = AdminMandir
***************
*** 530,532 ****
--- 589,595 ----
        FILE_MANDIR = FileMandir
        KRB5_LIBDIR = Krb5Libdir
        KRB5_INCDIR = Krb5Incdir
+   KRB5_INCSUBDIRS = concat(Krb5Incdir,/krb5) \
+                     concat(Krb5Incdir,/krb5/asn.1) \
+                     concat(Krb5Incdir,/kerberosIV)
+  KRB5_OTHERMKDIRS = Krb5Othermkdirs

*** ./config/Imake.rules.old	1993/02/26 22:17:03
--- ./config/Imake.rules	1993/02/26 22:17:36
***************
*** 1,119 ****
! /**/# $Source$
! /**/# $Author$
! /**/# $Id$
! /**/#
! 
! /**/###########################################################################
! /**/# Imake rules for building libraries, programs, scripts, and data files
! /**/# rules:  $XConsortium: Imake.rules,v 1.67 89/12/18 17:14:15 jim Exp $
  
  /*
   *		   MACHINE-INDEPENDENT RULES; DO NOT MODIFY
   *
!  * Warning, when defining rules: make sure you don't include both a trailing
   * backslash and double ampersand backslash or else you will get an extra
   * backslash in the Makefile.
   * 
!  * These macros are defined for the various templates and Imakefiles (for a 
!  * list of the applicable make variables, see the template files):
   * 
!  *      SaberProgramTarget          (program,srclist,objlist,locallibs,syslibs)
!  *      RemoveTargetProgram                      (program)
!  *      BuildIncludes                            (srclist,dstdir)
!  *     	NormalProgramTarget         (program,objects,deplibs,locallibs,syslibs)
!  *     	SimpleProgramTarget                      (program)
!  *     	ComplexProgramTarget                     (program)
!  *     	ComplexProgramTarget_1                   (program,locallib,syslib)
!  *     	ComplexProgramTarget_2                   (program,locallib,syslib)
!  *     	ComplexProgramTarget_3                   (program,locallib,syslib)
!  *     	ServerTarget                     (server,subdirs,objects,libs,syslibs)
!  *     	InstallLibrary                           (libname,dest)
!  *     	InstallSharedLibrary                     (libname,rev,dest)
!  *     	InstallLibraryAlias                      (libname,alias,dest)
!  *     	InstallLintLibrary                       (libname,dest)
!  *     	InstallManPageLong                       (file,destdir,dest)
!  *     	InstallManPage                           (file,dest)
!  *     	InstallNonExec                           (file,dest)
!  *     	InstallProgram                           (program,dest)
!  *      InstallProgramWithFlags                  (program,dest,flags)
!  *     	InstallScript                            (program,dest)
!  *      LinkFileList                             (step,list,dir,sub)
!  *      InstallMultipleDestFlags                 (step,list,dest,flags)
!  *      InstallMultipleDest                      (step,list,dest)
!  *     	InstallMultiple                          (list,dest)
!  *      InstallMultipleFlags                     (list,dest,flags)
!  *      InstallMultipleMan                       (list,dest)
!  *     	InstallAppDefaults                       (class)
!  *      DependDependency                         ()
!  *     	DependTarget                             ()
!  *     	CleanTarget                              ()
!  *     	TagsTarget                               ()
!  *      ImakeDependency                          (target)
!  *     	BuildMakefileTarget                      (imakefile,imakeflags)
!  *      MakefileTarget                           ()
!  *     	NormalLibraryObjectRule                  ()
!  *     	ProfiledLibraryObjectRule                ()
!  *     	DebuggedLibraryObjectRule                ()
!  *     	DebuggedAndProfiledLibraryObjectRule     ()
!  *      SharedLibraryObjectRule                  ()
!  *      SharedAndDebuggedLibraryObjectRule       ()
!  *      SpecialObjectRule                        (objs,depends,options)
!  *     	SpecialProfiledObjectRule                (objs,depends,options)
!  *     	SpecialDebuggedObjectRule                (objs,depends,options)
!  *     	SpecialDebuggedAndProfiledObjectRule     (objs,depends,options)
!  *     	NormalLibraryTarget                      (libname,objlist)
!  *      NormalSharedLibraryTarget                (libname,rev,solist,salist)
!  *     	NormalLibraryTarget2                     (libname,objlist1,objlist2)
!  *     	ProfiledLibraryTarget                    (libname,objlist)
!  *     	DebuggedLibraryTarget                    (libname,objlist)
!  *     	AliasedLibraryTarget                     (libname,alias)
!  *     	NormalRelocatableTarget                  (objname,objlist)
!  *     	ProfiledRelocatableTarget                (objname,objlist)
!  *     	DebuggedRelocatableTarget                (objname,objlist)
!  *     	LintLibraryTarget                        (libname,srclist)
!  *      NormalLintTarget                         (srclist)
!  *      LintTarget                               ()
!  *      MakeSubincludesForBuild                  (step,dir,srclist)
!  *      NamedTargetSubdirs                       (name,dirs,verb,flags,subname)
!  *      MakeSubdirs                              (dirs)
!  *      NamedMakeSubdirs                         (name,dirs)
!  *      DependSubdirs                            (dirs)
!  *      InstallSubdirs                           (dirs)
!  *      InstallManSubdirs                        (dirs)
!  *      NamedIncludesSubdirs                     (name,dirs)
!  *      IncludesSubdirs                             (dirs)
!  *      NamedCleanSubdirs                        (name,dirs)
!  *      CleanSubdirs                             (dirs)
!  *      NamedTagSubdirs                          (name,dirs)
!  *      TagSubdirs                               (dirs)
!  *      MakeLintSubdirs                          (dirs,target,subtarget)
!  *      LintSubdirs                              (dirs)
!  *      MakeLintLibSubdirs                       (dirs)
!  *      MakeMakeSubdirs                          (dirs,target)
!  *      MakeNsubdirMakefiles                     ()
!  *      MakefileSubdirs                          (dirs)
!  *      CppScriptTarget                          (dst,src,defs,deplist)
!  *      MakeScriptFromCpp                        (name,defs)
!  *      MakeDirectories                          (step,dirs)
!  *      MakeFonts                                ()
!  *      InstallFonts                             (dest)
!  *      InstallFontAliases                       (dest)
!  *      FontTarget                               (basename)
!  *      CompressedFontTarget                     (basename)
!  *      AllTarget                                (depends)
!  *	DoRanlib				 (flags,files)
!  * 
!  * 
!  * The general linking for building programs is:
   * 
!  *      program-objects programlibs syslibs EXTRA_LIBRARIES systemlibs \
!  *              EXTRA_LOAD_FLAGS
   *
!  * where programlibs is LOCAL_LIBRARIES for ComplexProgramTarget
!  * and EXTRA comes with syslibs from the LDLIBS
   */
  
  
  
  /*
   * SaberProgramTarget - generate rules to make Saber-C read in sources and
--- 1,150 ----
! XCOMM -------------------------------------------------------------------------
! XCOMM Imake rules for building libraries, programs, scripts, and data files
! XCOMM rules:  $XConsortium: Imake.rules,v 1.123 91/09/16 20:12:16 rws Exp $
  
  /*
   *		   MACHINE-INDEPENDENT RULES; DO NOT MODIFY
   *
!  * Warning, when defining rules: make sure you do not include both a trailing
   * backslash and double ampersand backslash or else you will get an extra
   * backslash in the Makefile.
   * 
!  * The following macros are defined for the various templates and Imakefiles
!  * (for a list of the applicable make variables, see the template files):
   * 
!  * SaberProgramTarget		(program,srclist,objlist,locallibs,syslibs)
!  * RemoveTargetProgram		(program)
!  * MakeDir			(dir)
!  * BuildIncludes		(srclist,dstsubdir,dstupdir)
!  * NormalProgramTarget		(program,objects,deplibs,locallibs,syslibs)
!  * SetUIDProgramTarget		(program,objects,deplibs,locallibs,syslibs)
!  * SingleProgramTarget		(program,objects,locallibs,syslibs)
!  * SimpleProgramTarget		(program)
!  * ComplexProgramTarget		(program)
!  * ComplexProgramTarget_1	(program,locallib,syslib)
!  * ComplexProgramTarget_2	(program,locallib,syslib)
!  * ComplexProgramTarget_3	(program,locallib,syslib)
!  * ServerTarget			(server,subdirs,objects,libs,syslibs)
!  * RanLibrary			(args)
!  * InstallLibrary		(libname,dest)
!  * MergeIntoInstalledLibrary	(tolib,fromlib)
!  * InstallLibraryAlias		(libname,alias,dest)
!  * InstallLintLibrary		(libname,dest)
!  * InstallManPageLong		(file,destdir,dest)
!  * InstallManPage		(file,destdir)
!  * InstallManPageAliases	(file,destdir,aliases)
!  * InstallNamedNonExec		(srcname,dstname,dest)
!  * InstallNonExecFile		(file,dest)
!  * InstallNonExec		(file,dest)
!  * InstallProgramWithFlags	(program,dest,flags)
!  * InstallProgram		(program,dest)
!  * InstallScript		(program,dest)
!  * InstallNamedProg		(srcname,dstname,dest)
!  * LinkFileList			(step,list,dir,sub)
!  * InstallMultipleDestFlags	(step,list,dest,flags)
!  * InstallMultipleDest		(step,list,dest)
!  * InstallMultiple		(list,dest)
!  * InstallMultipleFlags		(list,dest,flags)
!  * InstallMultipleMan		(list,dest)
!  * InstallAppDefaults		(class)
!  * InstallAppDefaultsLong	(file,class)
!  * DependDependency		()
!  * DependTarget			()
!  * DependTarget3		(srcs1,srcs2,srcs3)
!  * CleanTarget			()
!  * TagsTarget			()
!  * ImakeDependency		(target)
!  * BuildMakefileTarget		(notused,imakeflags)
!  * MakefileTarget		()
!  * LibMkdir			(dir)
!  * LibCleanDir			(dir)
!  * ObjectCompile		(options)
!  * NormalLibObjCompile		(options)
!  * NormalSharedLibObjCompile	(options)
!  * LibObjCompile		(dir,options)
!  * DebuggedLibObjCompile	(options)
!  * ProfiledLibObjCompile	(options)
!  * SharedLibObjCompile		(options)
!  * NormalLibraryObjectRule	()
!  * NormalFortranObjectRule	()
!  * ObjectFromSpecialSource	(dst,src,flags)
!  * SpecialObjectRule		(objs,depends,options)
!  * NormalLibraryTarget		(libname,objlist)
!  * NormalLibraryTarget2		(libname,objlist1,objlist2)
!  * NormalLibraryTarget3		(libname,objlist1,objlist2,objlist3)
!  * NormalDepLibraryTarget	(libname,deplist,objlist)
!  * SubdirLibraryRule		(objlist)
!  * ProfiledLibraryTarget	(libname,objlist)
!  * DebuggedLibraryTarget	(libname,objlist)
!  * AliasedLibraryTarget		(libname,alias)
!  * NormalRelocatableTarget	(objname,objlist)
!  * ProfiledRelocatableTarget	(objname,objlist)
!  * DebuggedRelocatableTarget	(objname,objlist)
!  * LintLibraryTarget		(libname,srclist)
!  * NormalLintTarget		(srclist)
!  * LintTarget			()
!  * LinkSourceFile		(src,dir)
!  * LinkFile			(tofile,fromfile)
!  * MakeSubincludesForBuild	(step,dir,srclist)
!  * NamedTargetSubdirs		(name,dirs,verb,flags,subname)
!  * NamedMakeSubdirs		(name,dirs)
!  * MakeSubdirs			(dirs)
!  * DependSubdirs		(dirs)
!  * ForceSubdirs			(dirs)
!  * InstallSubdirs		(dirs)
!  * InstallManSubdirs		(dirs)
!  * IncludesSubdirs		(dirs)
!  * NamedCleanSubdirs		(name,dirs)
!  * CleanSubdirs			(dirs)
!  * NamedTagSubdirs		(name,dirs)
!  * TagSubdirs			(dirs)
!  * MakeLintSubdirs		(dirs,target,subtarget)
!  * LintSubdirs			(dirs)
!  * MakeLintLibSubdirs		(dirs)
!  * MakeMakeSubdirs		(dirs,target)
!  * MakeNsubdirMakefiles		()
!  * MakefileSubdirs		(dirs)
!  * CppScriptTarget		(dst,src,defs,deplist)
!  * MakeScriptFromCpp		(name,defs)
!  * CppFileTarget		(dst,src,defs,deplist)
!  * MakeDirectories		(step,dirs)
!  * MakeFontsDir			(deplist)
!  * MakeFonts			()
!  * InstallFontObjs		(objs,dest)
!  * InstallFonts			(dest)
!  * InstallFontAliases		(dest)
!  * FontSrc			(basename)
!  * FontBaseObj			(basename)
!  * InstallFontScale		(dest)
!  * UncompressedFontTarget	(basename)
!  * UncompressedFontTarget	(basename)
!  * CompressedFontTarget		(basename)
!  * FontTarget			(basename)
!  * FontObj			(basename)
!  * AllTarget			(depends)
!  *
!  *
!  * The following are in Imake.tmpl:
!  *
!  * Concat			(a,b)
!  * Concat3			(a,b,c)
   * 
!  *
!  * The following are in specific <os>Lib.rules:
   *
!  * SharedLibraryTarget		(libname,rev,solist,down,up)
!  * SharedLibraryDataTarget	(libname,rev,salist)
!  * InstallSharedLibrary		(libname,rev,dest)
!  * InstallSharedLibraryData	(libname,rev,dest)
!  * 
   */
  
+ #define NullParameter
  
+ /* if [ -d ] or [ ! -d ] causes make to fail, define this as - */
+ #ifndef DirFailPrefix
+ #define DirFailPrefix
+ #endif
  
  /*
   * SaberProgramTarget - generate rules to make Saber-C read in sources and
***************
*** 122,132 ****
  #ifndef SaberProgramTarget
  #if HasSaberC
  #define SaberProgramTarget(program,srclist,objlist,locallibs,syslibs)	@@\
! saber_/**/program:							@@\
! 	#load $(ALLDEFINES) srclist locallibs $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) syslibs @@\
  									@@\
! osaber_/**/program:							@@\
! 	#load $(ALLDEFINES) objlist locallibs $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) syslibs
  
  #else
  #define SaberProgramTarget(program,srclist,objlist,locallibs,syslibs) /**/
--- 153,163 ----
  #ifndef SaberProgramTarget
  #if HasSaberC
  #define SaberProgramTarget(program,srclist,objlist,locallibs,syslibs)	@@\
! Concat(saber_,program):: srclist					@@\
! 	XCOMM load $(ALLDEFINES) srclist locallibs $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) syslibs @@\
  									@@\
! Concat(osaber_,program):: objlist					@@\
! 	XCOMM load $(ALLDEFINES) objlist locallibs $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) syslibs
  
  #else
  #define SaberProgramTarget(program,srclist,objlist,locallibs,syslibs) /**/
***************
*** 136,151 ****
  #ifndef RemoveTargetProgram
  #if RemoveTargetProgramByMoving
  #define RemoveTargetProgram(program) \
! $(RM) program; if [ -f program ]; then $(MV) program program/**/~; fi
  #else
  #define RemoveTargetProgram(program) $(RM) program
  #endif
  #endif
  
  #ifndef BuildIncludes
  #define BuildIncludes(srclist,dstsubdir,dstupdir)			@@\
  includes::								@@\
! 	$(MKDIRHIER) $(BUILDINCDIR)/dstsubdir				@@\
  	@(set -x; cd $(BUILDINCDIR)/dstsubdir; for i in srclist; do \	@@\
  		$(RM) $$i; \						@@\
  		$(LN) $(BUILDINCTOP)/dstupdir/$(CURRENT_DIR)/$$i .; \	@@\
--- 167,187 ----
  #ifndef RemoveTargetProgram
  #if RemoveTargetProgramByMoving
  #define RemoveTargetProgram(program) \
! if [ -f program ]; then $(RM) Concat(program,~); $(MV) program Concat(program,~); fi
  #else
  #define RemoveTargetProgram(program) $(RM) program
  #endif
  #endif
  
+ #ifndef MakeDir
+ #define MakeDir(dir) DirFailPrefix@if [ -d dir ]; then set +x; \	@@\
+ 		else (set -x; $(MKDIRHIER) dir); fi
+ #endif
+ 
  #ifndef BuildIncludes
  #define BuildIncludes(srclist,dstsubdir,dstupdir)			@@\
  includes::								@@\
! 	MakeDir($(BUILDINCDIR)/dstsubdir)				@@\
  	@(set -x; cd $(BUILDINCDIR)/dstsubdir; for i in srclist; do \	@@\
  		$(RM) $$i; \						@@\
  		$(LN) $(BUILDINCTOP)/dstupdir/$(CURRENT_DIR)/$$i .; \	@@\
***************
*** 168,180 ****
  #endif /* NormalProgramTarget */
  
  
  /*
!  * SingleProgramTarget - obsolete version of NormalProgramTarget that doesn't have
!  * deplibs.
   */
  #ifndef SingleProgramTarget
  #define	SingleProgramTarget(program,objects,locallibs,syslibs)		@@\
! NormalProgramTarget(program,objects, /**/,locallibs,syslibs)
  #endif /* SingleProgramTarget */
  
  /*
--- 204,221 ----
  #endif /* NormalProgramTarget */
  
  
+ #ifndef SetUIDProgramTarget
+ #define SetUIDProgramTarget NormalProgramTarget
+ #endif
+ 
+ 
  /*
!  * SingleProgramTarget - obsolete version of NormalProgramTarget that does
!  * not have deplibs.
   */
  #ifndef SingleProgramTarget
  #define	SingleProgramTarget(program,objects,locallibs,syslibs)		@@\
! NormalProgramTarget(program,objects,NullParameter,locallibs,syslibs)
  #endif /* SingleProgramTarget */
  
  /*
***************
*** 208,214 ****
  	RemoveTargetProgram($@)						@@\
  	$(CC) -o $@ $(OBJS) $(LDOPTIONS) $(LOCAL_LIBRARIES) $(LDLIBS) $(EXTRA_LOAD_FLAGS) @@\
  									@@\
! SaberProgramTarget(program,$(SRCS),$(OBJS),$(LOCAL_LIBRARIES), /**/)	@@\
  									@@\
  InstallProgram(program,$(BINDIR))					@@\
  InstallManPage(program,$(MANDIR))					@@\
--- 249,255 ----
  	RemoveTargetProgram($@)						@@\
  	$(CC) -o $@ $(OBJS) $(LDOPTIONS) $(LOCAL_LIBRARIES) $(LDLIBS) $(EXTRA_LOAD_FLAGS) @@\
  									@@\
! SaberProgramTarget(program,$(SRCS),$(OBJS),$(LOCAL_LIBRARIES),NullParameter) @@\
  									@@\
  InstallProgram(program,$(BINDIR))					@@\
  InstallManPage(program,$(MANDIR))					@@\
***************
*** 289,302 ****
  #endif /* ComplexProgramTarget_3 */
  
  
  /*
   * InstallLibrary - generate rules to install the indicated library.
   */
  #ifndef InstallLibrary
  #define	InstallLibrary(libname,dest)					@@\
! install:: lib/**/libname.a						@@\
! 	$(INSTALL) -c $(INSTLIBFLAGS) lib/**/libname.a dest		@@\
! 	$(RANLIB) $(RANLIBINSTFLAGS) dest/lib/**/libname.a
  #endif /* InstallLibrary */
  
  /*
--- 330,368 ----
  #endif /* ComplexProgramTarget_3 */
  
  
+ 
+ /*
+  * ServerTarget - generate rules to compile, link, and relink an X server.
+  */
+ #ifndef ServerTarget
+ #define	ServerTarget(server,subdirs,objects,libs,syslibs)		@@\
+ server: subdirs objects libs						@@\
+ 	-@if [ -f server ]; then set -x; \				@@\
+ 		$(MV) server server.bak; else exit 0; fi		@@\
+ 	$(CC) $(CDEBUGFLAGS) $(CCOPTIONS) -o server objects libs $(EXTRA_LIBRARIES) syslibs $(EXTRA_LOAD_FLAGS) @@\
+ 									@@\
+ Concat(load,server):							@@\
+ 	-@if [ -f server ]; then set -x; \				@@\
+ 		$(MV) server server.bak; else exit 0; fi		@@\
+ 	$(CC) $(CDEBUGFLAGS) $(CCOPTIONS) -o server objects libs $(EXTRA_LIBRARIES) syslibs $(EXTRA_LOAD_FLAGS)
+ #endif /* ServerTarget */
+ 
+ 
+ #if DoRanlibCmd
+ #define RanLibrary(args) $(RANLIB) args
+ #else
+ #define RanLibrary(args) /**/
+ #endif
+ 
  /*
   * InstallLibrary - generate rules to install the indicated library.
   */
  #ifndef InstallLibrary
  #define	InstallLibrary(libname,dest)					@@\
! install:: Concat(lib,libname.a)						@@\
! 	MakeDir($(DESTDIR)dest)						@@\
! 	$(INSTALL) -c $(INSTLIBFLAGS) Concat(lib,libname.a) $(DESTDIR)dest @@\
! 	RanLibrary($(RANLIBINSTFLAGS) Concat($(DESTDIR)dest/lib,libname.a))
  #endif /* InstallLibrary */
  
  /*
***************
*** 305,335 ****
  #ifndef MergeIntoInstalledLibrary
  #define MergeIntoInstalledLibrary(tolib,fromlib)			@@\
  install::  fromlib							@@\
! 	$(SCRIPTSRC)/mergelib tolib fromlib
  #endif /* MergeIntoInstalledLibrary */
  
  /*
-  * InstallSharedLibrary - generate rules to install the shared library.
-  */
- #ifndef InstallSharedLibrary
- #define	InstallSharedLibrary(libname,rev,dest)				@@\
- install:: lib/**/libname.so.rev 					@@\
- 	$(INSTALL) -c $(INSTLIBFLAGS) lib/**/libname.so.rev dest	@@\
- 
- #endif /* InstallSharedLibrary */
- 
- /*
-  * InstallSharedLibraryData - generate rules to install the shared library data
-  */
- #ifndef InstallSharedLibraryData
- #define	InstallSharedLibraryData(libname,rev,dest)			@@\
- install:: lib/**/libname.sa.rev						@@\
- 	$(INSTALL) -c $(INSTLIBFLAGS) lib/**/libname.sa.rev dest
- 
- #endif /* InstallSharedLibraryData */
- 
- 
- /*
   * InstallLibraryAlias - generate rules to create a link from one library name
   * to another for the purposes of aliasing.
   */
--- 371,380 ----
  #ifndef MergeIntoInstalledLibrary
  #define MergeIntoInstalledLibrary(tolib,fromlib)			@@\
  install::  fromlib							@@\
! 	$(SCRIPTSRC)/mergelib $(DESTDIR)tolib fromlib
  #endif /* MergeIntoInstalledLibrary */
  
  /*
   * InstallLibraryAlias - generate rules to create a link from one library name
   * to another for the purposes of aliasing.
   */
***************
*** 336,342 ****
  #ifndef InstallLibraryAlias
  #define	InstallLibraryAlias(libname,alias,dest)				@@\
  install::								@@\
! 	-(cd dest; $(LN) lib/**/libname.a lib/**/alias.a)
  #endif /* InstallLibraryAlias */
  
  
--- 381,389 ----
  #ifndef InstallLibraryAlias
  #define	InstallLibraryAlias(libname,alias,dest)				@@\
  install::								@@\
! 	-(cd $(DESTDIR)dest; \						@@\
! 		$(RM) Concat(lib,alias.a); \				@@\
! 		$(LN) Concat(lib,libname.a) Concat(lib,alias.a))
  #endif /* InstallLibraryAlias */
  
  
***************
*** 345,352 ****
   */
  #ifndef InstallLintLibrary
  #define	InstallLintLibrary(libname,dest)				@@\
! install.ln:: llib-l/**/libname.ln					@@\
! 	$(INSTALL) -c $(INSTLIBFLAGS) llib-l/**/libname.ln dest
  #endif /* InstallLintLibrary */
  
  
--- 392,400 ----
   */
  #ifndef InstallLintLibrary
  #define	InstallLintLibrary(libname,dest)				@@\
! install.ln:: Concat(llib-l,libname.ln)					@@\
! 	MakeDir($(DESTDIR)dest)						@@\
! 	$(INSTALL) -c $(INSTLIBFLAGS) Concat(llib-l,libname.ln) $(DESTDIR)dest
  #endif /* InstallLintLibrary */
  
  
***************
*** 360,366 ****
  #ifndef InstallManPageLong
  #define	InstallManPageLong(file,destdir,dest)				@@\
  install.man:: file.man							@@\
! 	$(INSTALL) -c $(INSTMANFLAGS) file.man destdir/dest.ManSuffix
  #endif /* InstallManPageLong */
  
  
--- 408,415 ----
  #ifndef InstallManPageLong
  #define	InstallManPageLong(file,destdir,dest)				@@\
  install.man:: file.man							@@\
! 	MakeDir($(DESTDIR)destdir)					@@\
! 	$(INSTALL) -c $(INSTMANFLAGS) file.man $(DESTDIR)destdir/dest.$(MANSUFFIX)
  #endif /* InstallManPageLong */
  
  
***************
*** 368,386 ****
   * InstallManPage - generate rules to install the indicated manual page.
   */
  #ifndef InstallManPage
! #define	InstallManPage(file,dest)					@@\
! InstallManPageLong(file,dest,file)
  #endif /* InstallManPage */
  
  
  /*
!  * InstallNonExec - generate rules to install a data file using any special
!  * install flags
   */
  #ifndef InstallNonExec
  #define	InstallNonExec(file,dest)					@@\
  install:: file								@@\
! 	$(INSTALL) -c $(INSTDATFLAGS) file dest
  #endif /* InstallNonExec */
  
  
--- 417,473 ----
   * InstallManPage - generate rules to install the indicated manual page.
   */
  #ifndef InstallManPage
! #define	InstallManPage(file,destdir)					@@\
! InstallManPageLong(file,destdir,file)
  #endif /* InstallManPage */
  
  
  /*
!  * InstallManPageAliases - generate rules to install manual page aliases.
!  */
! #ifndef InstallManPageAliases
! #define	InstallManPageAliases(file,destdir,aliases)			@@\
! install.man::								@@\
! 	@(TMP=/tmp/tmp.$$$$; \						@@\
! 	$(RM) $${TMP}; \						@@\
! 	echo .so `basename destdir`/file.$(MANSUFFIX) > $${TMP}; \	@@\
! 	for i in aliases; do (set -x; \					@@\
! 	$(INSTALL) -c $(INSTMANFLAGS) $${TMP} $(DESTDIR)destdir/$$i.$(MANSUFFIX)); \ @@\
! 	done; \								@@\
! 	$(RM) $${TMP})
! #endif /* InstallManPageAliases */
! 
! 
! /*
!  * InstallNamedNonExec - generate rules to install a data file
!  */
! #ifndef InstallNamedNonExec
! #define	InstallNamedNonExec(srcname,dstname,dest)			@@\
! install:: srcname							@@\
! 	MakeDir($(DESTDIR)dest)						@@\
! 	$(INSTALL) -c $(INSTDATFLAGS) srcname $(DESTDIR)dest/dstname
! #endif /* InstallNamedNonExec */
! 
! 
! /*
!  * InstallNonExecFile - generate rules to install a data file
!  */
! #ifndef InstallNonExecFile
! #define	InstallNonExecFile(file,dest)					@@\
! install:: file								@@\
! 	MakeDir($(DESTDIR)dest)						@@\
! 	$(INSTALL) -c $(INSTDATFLAGS) file $(DESTDIR)dest
! #endif /* InstallNonExecFile */
! 
! 
! /*
!  * InstallNonExec - generate rules to install a data file, but does not
!  * try to create the destination directory (deprecated)
   */
  #ifndef InstallNonExec
  #define	InstallNonExec(file,dest)					@@\
  install:: file								@@\
! 	$(INSTALL) -c $(INSTDATFLAGS) file $(DESTDIR)dest
  #endif /* InstallNonExec */
  
  
***************
*** 391,397 ****
  #ifndef InstallProgramWithFlags
  #define InstallProgramWithFlags(program,dest,flags)			@@\
  install:: program							@@\
! 	$(INSTALL) -c $(INSTPGMFLAGS) flags program dest
  #endif /* InstallProgramWithFlags */
  
  
--- 478,485 ----
  #ifndef InstallProgramWithFlags
  #define InstallProgramWithFlags(program,dest,flags)			@@\
  install:: program							@@\
! 	MakeDir($(DESTDIR)dest)						@@\
! 	$(INSTALL) -c $(INSTPGMFLAGS) flags program $(DESTDIR)dest
  #endif /* InstallProgramWithFlags */
  
  
***************
*** 401,423 ****
   */
  #ifndef InstallProgram
  #define	InstallProgram(program,dest)					@@\
! InstallProgramWithFlags(program,dest/program, /**/)
  #endif /* InstallProgram */
  
  
  
  /*
!  * InstallScript - install a shell script using special install flags set in 
!  * $(INSTALLFLAGS).  This macro has been superceeded by CppScriptTarget.
   */
  #ifndef InstallScript
  #define	InstallScript(program,dest)					@@\
  install:: program.script						@@\
! 	$(INSTALL) -c $(INSTSCRFLAGS) program.script dest/program
  #endif /* InstallScript */
  
  
  /*
   * LinkFileList - link a list of list of files from one place to another
   */
  #ifndef LinkFileList
--- 489,522 ----
   */
  #ifndef InstallProgram
  #define	InstallProgram(program,dest)					@@\
! InstallProgramWithFlags(program,dest,NullParameter)
  #endif /* InstallProgram */
  
  
  
  /*
!  * InstallScript - install a shell script.
   */
  #ifndef InstallScript
  #define	InstallScript(program,dest)					@@\
  install:: program.script						@@\
! 	MakeDir($(DESTDIR)dest)						@@\
! 	$(INSTALL) -c $(INSTBINFLAGS) program.script $(DESTDIR)dest/program
  #endif /* InstallScript */
  
  
  /*
+  * InstallNamedProg - install a program with renaming and no stripping.
+  */
+ #ifndef InstallNamedProg
+ #define	InstallNamedProg(srcname,dstname,dest)				@@\
+ install:: srcname							@@\
+ 	MakeDir($(DESTDIR)dest)						@@\
+ 	$(INSTALL) -c $(INSTBINFLAGS) srcname $(DESTDIR)dest/dstname
+ #endif /* InstallNamedProg */
+ 
+ 
+ /*
   * LinkFileList - link a list of list of files from one place to another
   */
  #ifndef LinkFileList
***************
*** 424,430 ****
  #define LinkFileList(step,list,dir,sub)					@@\
  step:: list								@@\
  	@case '${MFLAGS}' in *[i]*) set +e;; esac; \			@@\
! 	echo "	cd" dir; cd dir; for i in list; do (set -x; $(LN) sub/$$i .); done
  #endif
  
  
--- 523,530 ----
  #define LinkFileList(step,list,dir,sub)					@@\
  step:: list								@@\
  	@case '${MFLAGS}' in *[i]*) set +e;; esac; \			@@\
! 	echo "	cd" dir; cd dir; \					@@\
! 	for i in list; do (set -x; $(RM) $$i; $(LN) sub/$$i .); done
  #endif
  
  
***************
*** 436,444 ****
  #ifndef InstallMultipleDestFlags
  #define InstallMultipleDestFlags(step,list,dest,flags)			@@\
  step:: list								@@\
  	@case '${MFLAGS}' in *[i]*) set +e;; esac; \			@@\
  	for i in list; do \						@@\
! 		(set -x; $(INSTALL) -c flags $$i dest); \		@@\
  	done
  #endif /* InstallMultipleDestFlags */
  
--- 536,545 ----
  #ifndef InstallMultipleDestFlags
  #define InstallMultipleDestFlags(step,list,dest,flags)			@@\
  step:: list								@@\
+ 	MakeDir($(DESTDIR)dest)						@@\
  	@case '${MFLAGS}' in *[i]*) set +e;; esac; \			@@\
  	for i in list; do \						@@\
! 		(set -x; $(INSTALL) -c flags $$i $(DESTDIR)dest); \	@@\
  	done
  #endif /* InstallMultipleDestFlags */
  
***************
*** 480,490 ****
   */
  #ifndef InstallMultipleMan
  #define InstallMultipleMan(list,dest)					@@\
! InstallMultipleDest(install.man,list,dest)
  #endif /* InstallMultipleMan */
  
  
  /*
   * DependDependency - generate rules to build the makedepend program if 
   * this Imakefile is within the source tree.
   */
--- 581,624 ----
   */
  #ifndef InstallMultipleMan
  #define InstallMultipleMan(list,dest)					@@\
! InstallMultipleDestFlags(install.man,list,dest,$(INSTMANFLAGS))
  #endif /* InstallMultipleMan */
  
  
  /*
+  * InstallAppDefaults - generate rules to install appliation default files 
+  * if the InstallAppDefFiles configuration parameter is set.
+  */
+ #ifndef InstallAppDefaults
+ #if InstallAppDefFiles
+ #define	InstallAppDefaults(class)					@@\
+ install:: class.ad							@@\
+ 	MakeDir($(DESTDIR)$(XAPPLOADDIR))				@@\
+ 	$(INSTALL) -c $(INSTAPPFLAGS) class.ad $(DESTDIR)$(XAPPLOADDIR)/class
+ #else
+ #define	InstallAppDefaults(class)
+ #endif /* InstallAppDefFiles */
+ #endif /* InstallAppDefaults */
+ 
+ /*
+  * InstallAppDefaultsLong - generate rules to install appliation default files 
+  * if the InstallAppDefFiles configuration parameter is set.
+  */
+ #ifndef InstallAppDefaultsLong
+ #if InstallAppDefFiles
+ #define	InstallAppDefaultsLong(file,class)				@@\
+ install:: file.ad							@@\
+ 	MakeDir($(DESTDIR)$(XAPPLOADDIR))				@@\
+ 	$(INSTALL) -c $(INSTAPPFLAGS) file.ad $(DESTDIR)$(XAPPLOADDIR)/class
+ #else
+ #define	InstallAppDefaultsLong(file,class)
+ #endif /* InstallAppDefFiles */
+ #endif /* InstallAppDefaultsLong */
+ 
+ 
+ 
+ 
+ /*
   * DependDependency - generate rules to build the makedepend program if 
   * this Imakefile is within the source tree.
   */
***************
*** 513,523 ****
  DependDependency()							@@\
  									@@\
  depend::								@@\
! 	$(DEPEND) -s "# DO NOT DELETE" -- $(ALLDEFINES) $(MDFLAGS) -- $(SRCS)
  #endif /* DependTarget */
  
  
  /*
   * CleanTarget - generate rules to remove any garbage files; the #* is here
   * instead of in the definition of RM_CMD because System V will treat the 
   * pound sign in the RM_CMD variable as a comment.
--- 647,671 ----
  DependDependency()							@@\
  									@@\
  depend::								@@\
! 	$(DEPEND) $(DEPENDFLAGS) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- $(SRCS)
  #endif /* DependTarget */
  
  
  /*
+  * DependTarget3 - generate rules to compute dependencies for all files given.
+  */
+ #ifndef DependTarget3
+ #define	DependTarget3(srcs1,srcs2,srcs3)				@@\
+ DependDependency()							@@\
+ 									@@\
+ depend::								@@\
+ 	$(DEPEND) $(DEPENDFLAGS) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- srcs1	@@\
+ 	$(DEPEND) -a $(DEPENDFLAGS) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- srcs2	@@\
+ 	$(DEPEND) -a $(DEPENDFLAGS) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- srcs3
+ #endif /* DependTarget3 */
+ 
+ 
+ /*
   * CleanTarget - generate rules to remove any garbage files; the #* is here
   * instead of in the definition of RM_CMD because System V will treat the 
   * pound sign in the RM_CMD variable as a comment.
***************
*** 525,531 ****
  #ifndef CleanTarget
  #define	CleanTarget()							@@\
  clean::									@@\
! 	$(RM_CMD) \#*
  #endif /* CleanTarget */
  
  
--- 673,679 ----
  #ifndef CleanTarget
  #define	CleanTarget()							@@\
  clean::									@@\
! 	$(RM_CMD) "#"*
  #endif /* CleanTarget */
  
  
***************
*** 536,542 ****
  #define	TagsTarget()							@@\
  tags::									@@\
  	$(TAGS) -w *.[ch]						@@\
! 	$(ETAGS) *.[ch]
  #endif /* TagsTarget */
  
  
--- 684,690 ----
  #define	TagsTarget()							@@\
  tags::									@@\
  	$(TAGS) -w *.[ch]						@@\
! 	$(TAGS) -xw *.[ch] > TAGS
  #endif /* TagsTarget */
  
  
***************
*** 547,553 ****
  #ifndef ImakeDependency
  #ifdef UseImakeInstalled
  #define ImakeDependency(target) 					@@\
! target:: Imakefile
  #else
  #define ImakeDependency(target)						@@\
  $(IMAKE):								@@\
--- 695,701 ----
  #ifndef ImakeDependency
  #ifdef UseImakeInstalled
  #define ImakeDependency(target) 					@@\
! target:: 
  #else
  #define ImakeDependency(target)						@@\
  $(IMAKE):								@@\
***************
*** 557,563 ****
  	$(MAKE) -f Makefile.ini BOOTSTRAPCFLAGS=$(BOOTSTRAPCFLAGS); fi; \	@@\
  	echo "okay, continuing in $(CURRENT_DIR)")			@@\
  									@@\
! target:: $(IMAKE) Imakefile
  #endif /* UseImakeInstalled */
  #endif /* ImakeDependency */
  
--- 705,711 ----
  	$(MAKE) -f Makefile.ini BOOTSTRAPCFLAGS=$(BOOTSTRAPCFLAGS); fi; \	@@\
  	echo "okay, continuing in $(CURRENT_DIR)")			@@\
  									@@\
! target:: $(IMAKE) 
  #endif /* UseImakeInstalled */
  #endif /* ImakeDependency */
  
***************
*** 590,771 ****
   */
  #ifndef MakefileTarget
  #define MakefileTarget()						@@\
! BuildMakefileTarget(Imakefile, /**/)
  #endif /* MakefileTarget */
  
  
  /*
!  * NormalLibraryObjectRule - generate make rules to build "normal" objects.
   */
! #ifndef NormalLibraryObjectRule
! #define	NormalLibraryObjectRule()					@@\
! .c.o:									@@\
! 	$(RM) $@							@@\
! 	$(CC) -c $(CFLAGS) $(SRCDIR)$*.c
! #endif /* NormalLibraryObjectRule */
! 
! #ifndef NormalFortranObjectRule
! #define NormalFortranObjectRule()					@@\
! .f.o:									@@\
! 	$(RM) $@							@@\
! 	$(FC) -c $(FCFLAGS) $*.f
  #endif
  
- 
  /*
!  * ProfiledLibraryObjectRule - generate make rules to build both profiled
!  * and "normal" objects.
   */
! #ifndef ProfiledLibraryObjectRule
! #define	ProfiledLibraryObjectRule()					@@\
! all::									@@\
! 	@if [ ! -d profiled ]; then mkdir profiled; else exit 0; fi	@@\
! 									@@\
! .c.o:									@@\
! 	$(RM) $@ profiled/$@						@@\
! 	$(CC) -pg -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 	$(MV) $*.o profiled/$*.o					@@\
! 	$(CC) -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 									@@\
! clean::									@@\
! 	-@if [ -d profiled ]; then echo "	$(RM) profiled/?*.o"; \	@@\
! 		$(RM) profiled/?*.o; else exit 0; fi			@@\
! 
! #endif /* ProfiledLibraryObjectRule */
! 
  
  /*
!  * DebuggedLibraryObjectRule - generate make rules to build both debuggable
!  * and "normal" objects.
   */
! #ifndef DebuggedLibraryObjectRule
! #define	DebuggedLibraryObjectRule()					@@\
! all::									@@\
! 	@if [ ! -d debugger ]; then mkdir debugger; else exit 0; fi	@@\
! 									@@\
! .c.o:									@@\
! 	$(RM) $@ debugger/$@						@@\
! 	$(CC) -g -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 	$(MV) $*.o debugger/$*.o					@@\
! 	$(CC) -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 									@@\
! clean::									@@\
! 	-@if [ -d debugger ]; then echo "	$(RM) debugger/?*.o"; \ @@\
! 		$(RM) debugger/?*.o; else exit 0; fi			@@\
! 
! #endif /* DebuggedLibraryObjectRule */
  
  
  /*
!  * DebuggedAndProfiledLibraryOjbectRule - generate make rules to build
!  * debuggable, profiled, and "normal" objects.
   */
! #ifndef DebuggedAndProfiledLibraryObjectRule
! #define	DebuggedAndProfiledLibraryObjectRule()				@@\
! all::									@@\
! 	@if [ ! -d profiled ]; then mkdir profiled; else exit 0; fi	@@\
! 	@if [ ! -d debugger ]; then mkdir debugger; else exit 0; fi	@@\
! 									@@\
! .c.o:									@@\
! 	$(RM) $@ profiled/$@ debugger/$@				@@\
! 	$(CC) -pg -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 	$(MV) $*.o profiled/$*.o					@@\
! 	$(CC) -g -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 	$(MV) $*.o debugger/$*.o					@@\
! 	$(CC) -c $(CFLAGS) $(SRCDIR)$*.c				@@\
! 									@@\
! clean::									@@\
! 	-@if [ -d profiled ]; then echo "	$(RM) profiled/?*.o"; \ @@\
! 		$(RM) profiled/?*.o; else exit 0; fi			@@\
! 	-@if [ -d debugger ]; then echo "	$(RM) debugger/?*.o"; \ @@\
! 		$(RM) debugger/?*.o; else exit 0; fi			@@\
  
! #endif /* DebuggedAndProfiledLibraryObjectRule */
  
  
  /*
!  * SharedLibraryObjectRule - generate make rules to build shared and "normal"
!  * object files.
   */
! #ifndef SharedLibraryObjectRule
! #define SharedLibraryObjectRule()					@@\
! all::									@@\
! 	@if [ ! -d shared ]; then mkdir shared; else exit 0; fi		@@\
! 									@@\
! .c.o:									@@\
! 	$(RM) $@ shared/$@						@@\
! 	$(CC) -pic -c $(SHAREDCODEDEF) $(SHLIBDEF) $(CFLAGS) $(SRCDIR)$*.c @@\
! 	$(MV) $*.o shared/$*.o						@@\
! 	$(CC) -c $(SHLIBDEF) $(CFLAGS) $(SRCDIR)$*.c			@@\
! 									@@\
! clean::									@@\
! 	-@if [ -d shared ]; then echo "	$(RM) shared/?*.o"; \		@@\
! 		$(RM) shared/?*.o; else exit 0; fi			@@\
  
! #endif /* SharedLibraryObjectRule */
  
  /*
!  * SharedAndDebuggedLibraryObjectRule - generate make rules to build shared,
!  * debuggable, and "normal" object files.
   */
! #ifndef SharedAndDebuggedLibraryObjectRule
! #define SharedAndDebuggedLibraryObjectRule()				@@\
! all::									@@\
! 	@if [ ! -d shared ]; then mkdir shared; else exit 0; fi		@@\
! 	@if [ ! -d debugger ]; then mkdir debugger; else exit 0; fi	@@\
! 									@@\
  .c.o:									@@\
! 	$(RM) $@ shared/$@ debugger/$@					@@\
! 	$(CC) -pic -c $(SHAREDCODEDEF) $(SHLIBDEF) $(CFLAGS) $(SRCDIR)$*.c @@\
! 	$(MV) $*.o shared/$*.o						@@\
! 	$(CC) -g -c $(SHLIBDEF) $(CFLAGS) $(SRCDIR)$*.c			@@\
! 	$(MV) $*.o debugger/$*.o					@@\
! 	$(CC) -c $(SHLIBDEF) $(CFLAGS) $(SRCDIR)$*.c			@@\
  									@@\
! clean::									@@\
! 	-@if [ -d shared ]; then echo "	$(RM) shared/?*.o"; \	@@\
! 		$(RM) shared/?*.o; else exit 0; fi			@@\
! 	-@if [ -d debugger ]; then echo "	$(RM) debugger/?*.o"; \ @@\
! 		$(RM) debugger/?*.o; else exit 0; fi			@@\
! 
! #endif /* SharedAndDebuggedLibraryObjectRule */
! 
! /*
!  * SpecialSharedAndDebuggedObjectRule - generate rules to compile a file 
!  * with special flags and to make shared and debuggable versions.
!  */
! #ifndef SpecialSharedAndDebuggedObjectRule
! #define	SpecialSharedAndDebuggedObjectRule(objs,depends,options)	@@\
! all::									@@\
! 	@if [ ! -d shared ]; then mkdir shared; else exit 0; fi		@@\
! 	@if [ ! -d debugger ]; then mkdir debugger; else exit 0; fi	@@\
  									@@\
! objs:	depends								@@\
! 	$(RM) $@ shared/$@ debugger/$@					@@\
! 	$(CC) -pic -c $(SHAREDCODEDEF) $(SHLIBDEF) $(CFLAGS) options $*.c @@\
! 	$(MV) $*.o shared/$*.o						@@\
! 	$(CC) -g -c $(SHLIBDEF) $(CFLAGS) options $*.c			@@\
! 	$(MV) $*.o debugger/$*.o					@@\
! 	$(CC) -c $(SHLIBDEF) $(CFLAGS) options $*.c
! #endif /* SpecialDebuggedAndProfiledObjectRule */
! 
! /*
!  * SpecialSharedObjectRule - generate rules to compile a file 
!  * with special flags and to make shared and debuggable versions.
!  */
! #ifndef SpecialSharedObjectRule
! #define	SpecialSharedObjectRule(objs,depends,options)			@@\
! all::									@@\
! 	@if [ ! -d shared ]; then mkdir shared; else exit 0; fi		@@\
  									@@\
! objs:	depends								@@\
! 	$(RM) $@ shared/$@ 						@@\
! 	$(CC) -pic -c $(SHAREDCODEDEF) $(SHLIBDEF) $(CFLAGS) options $*.c @@\
! 	$(MV) $*.o shared/$*.o						@@\
! 	$(CC) -c $(SHLIBDEF) $(CFLAGS) options $*.c
! #endif /* SpecialDebuggedAndProfiledObjectRule */
! 
! 
  
  /*
   * SpecialObjectRule - generate rules to compile a file with special flags.
--- 738,846 ----
   */
  #ifndef MakefileTarget
  #define MakefileTarget()						@@\
! BuildMakefileTarget(Imakefile,NullParameter)
  #endif /* MakefileTarget */
  
  
  /*
!  * LibMkdir - helper for creating library object subdirectories
   */
! #ifndef LibMkdir
! #define LibMkdir(dir) DirFailPrefix@if [ -d dir ]; then exit 0; else set -x; mkdir dir; fi
  #endif
  
  /*
!  * LibCleanDir - helper for cleaning library object subdirectories
   */
! #ifndef LibCleanDir
! #define LibCleanDir(dir) -@if [ -d dir ]; then \			@@\
! 		(set -x; cd dir; $(RM) *.o); else exit 0; fi
! #endif
  
  /*
!  * ObjectCompile - compile fragment for a normal object file
   */
! #ifndef ObjectCompile
! #define ObjectCompile(options) $(RM) $@					@@\
! 	$(CC) -c $(CFLAGS) options $*.c
! #endif
  
+ /*
+  * NormalLibObjCompile - compile fragment for a normal library object file
+  */
+ #ifndef NormalLibObjCompile
+ #define NormalLibObjCompile(options) ObjectCompile(options)
+ #endif
  
  /*
!  * NormalSharedLibObjCompile - compile fragment for shared object when
!  * a normal library is not being built
   */
! #ifndef NormalSharedLibObjCompile
! #define NormalSharedLibObjCompile(options) NormalLibObjCompile(options $(SHLIBDEF) $(SHAREDCODEDEF) $(PICFLAGS))
! #endif
  
! /*
!  * LibObjCompile - compile fragment for shared/profiled/debugged objects
!  */
! #ifndef LibObjCompile
! #define LibObjCompile(dir,options) $(RM) $@ dir/$@			@@\
! 	$(CC) -c $(CCOPTIONS) $(ALLDEFINES) options $*.c		@@\
! 	$(MV) $@ dir/$@
! #endif
  
+ /*
+  * DebuggedLibObjCompile - compile fragment for debugged objects
+  */
+ #ifndef DebuggedLibObjCompile
+ #define DebuggedLibObjCompile(options) LibObjCompile(debugger,-g options)
+ #endif
  
  /*
!  * ProfiledLibObjCompile - compile fragment for profiled objects
   */
! #ifndef ProfiledLibObjCompile
! #define ProfiledLibObjCompile(options) LibObjCompile(profiled,-pg options)
! #endif
  
! /*
!  * SharedLibObjCompile - compile fragment for shared objects
!  */
! #ifndef SharedLibObjCompile
! #define SharedLibObjCompile(options) LibObjCompile(shared,options $(SHLIBDEF) $(SHAREDCODEDEF) $(PICFLAGS) $(CDEBUGFLAGS))
! #endif
  
  /*
!  * NormalLibraryObjectRule - for simple libraries
   */
! #ifndef NormalLibraryObjectRule
! #define	NormalLibraryObjectRule()					@@\
  .c.o:									@@\
! 	ObjectCompile($(_NOOP_))
! #endif /* NormalLibraryObjectRule */
! 
! 
! #ifndef NormalFortranObjectRule
! #define NormalFortranObjectRule()					@@\
! .f.o:									@@\
! 	$(RM) $@							@@\
! 	$(FC) -c $(FCFLAGS) $*.f
! #endif
! 
! #ifndef ObjectFromSpecialSource
! #define ObjectFromSpecialSource(dst,src,flags)				@@\
! dst.c:  src.c								@@\
! 	$(RM) $@							@@\
! 	$(LN) $? $@							@@\
  									@@\
! dst.o:  dst.c								@@\
! 	ObjectCompile(flags)						@@\
  									@@\
! depend::  dst.c								@@\
  									@@\
! clean::									@@\
! 	$(RM) dst.c
! #endif /* ObjectFromSpecialSource */
  
  /*
   * SpecialObjectRule - generate rules to compile a file with special flags.
***************
*** 773,909 ****
  #ifndef SpecialObjectRule
  #define SpecialObjectRule(objs,depends,options)				@@\
  objs:	depends								@@\
! 	$(RM) $@							@@\
! 	$(CC) -c $(CFLAGS) options $*.c
  #endif /* SpecialObjectRule */
  
  
  /*
!  * SpecialProfiledObjectRule - generate rules to compile a file with special
!  * flags and to make a profiled version.
   */
! #ifndef SpecialProfiledObjectRule
! #define	SpecialProfiledObjectRule(objs,depends,options)			@@\
! all::									@@\
! 	@if [ ! -d profiled ]; then mkdir profiled; else exit 0; fi	@@\
  									@@\
! objs:	depends								@@\
! 	$(RM) $@ profiled/$@						@@\
! 	$(CC) -pg -c $(CFLAGS) options $*.c				@@\
! 	$(MV) $*.o profiled/$*.o					@@\
! 	$(CC) -c $(CFLAGS) options $*.c
! #endif /* SpecialProfiledObjectRule */
  
  
  /*
!  * SpecialDebuggedObjectRule - generate rules to compile a file with special
!  * flags and to make a debuggable version.
   */
! #ifndef SpecialDebuggedObjectRule
! #define	SpecialDebuggedObjectRule(objs,depends,options)			@@\
! all::									@@\
! 	@if [ ! -d debugger ]; then mkdir debugger; else exit 0; fi	@@\
  									@@\
! objs:	depends								@@\
! 	$(RM) $@ debugger/$@						@@\
! 	$(CC) -g -c $(CFLAGS) options $*.c				@@\
! 	$(MV) $*.o debugger/$*.o					@@\
! 	$(CC) -c $(CFLAGS) options $*.c
! #endif /* SpecialDebuggedObjectRule */
  
  
  /*
!  * SpecialDebuggedAndProfiledObjectRule - generate rules to compile a file 
!  * with special flags and to make debuggable and profiled versions.
   */
! #ifndef SpecialDebuggedAndProfiledObjectRule
! #define	SpecialDebuggedAndProfiledObjectRule(objs,depends,options)	@@\
! all::									@@\
! 	@if [ ! -d profiled ]; then mkdir profiled; else exit 0; fi	@@\
! 	@if [ ! -d debugger ]; then mkdir debugger; else exit 0; fi	@@\
  									@@\
! objs:	depends								@@\
! 	$(RM) $@ profiled/$@ debugger/$@				@@\
! 	$(CC) -pg -c $(CFLAGS) options $*.c				@@\
! 	$(MV) $*.o profiled/$*.o					@@\
! 	$(CC) -g -c $(CFLAGS) options $*.c				@@\
! 	$(MV) $*.o debugger/$*.o					@@\
! 	$(CC) -c $(CFLAGS) options $*.c
! #endif /* SpecialDebuggedAndProfiledObjectRule */
  
  
  /*
!  * NormalLibraryTarget - generate rules to create a library.
   */
! #ifndef NormalLibraryTarget
! #define	NormalLibraryTarget(libname,objlist)				@@\
! AllTarget(lib/**/libname.a)						@@\
! DependTarget()								@@\
  									@@\
! lib/**/libname.a: objlist						@@\
  	$(RM) $@							@@\
  	$(AR) $@ objlist						@@\
! 	$(RANLIB) $@
! #endif /* NormalLibraryTarget */
! 
! 
! /*
!  * NormalSharedLibraryTarget - generate rules to create a shared library;
!  * build it into a different name so that the we don't hose people by having
!  * the library gone for long periods.
!  */
! #ifndef NormalSharedLibraryTarget
! #define NormalSharedLibraryTarget(libname,rev,solist)			@@\
! AllTarget(lib/**/libname.so.rev)					@@\
! 									@@\
! lib/**/libname.so.rev:  solist						@@\
! 	$(RM) $@~							@@\
! 	(cd shared; $(LD) -o ../$@~ -assert pure-text solist)		@@\
! 	$(RM) $@ 							@@\
! 	$(MV) $@~ $@							@@\
! 									@@\
! clean::									@@\
! 	$(RM) lib/**/libname.so.rev
  
- #endif
  
  /*
!  * NormalSharedLibraryDataTarget - generate rules to create shlib data file;
!  * build it into a different name so that the we don't hose people by having
!  * the library gone for long periods.
   */
! #ifndef NormalSharedLibraryDataTarget
! #define NormalSharedLibraryDataTarget(libname,rev,salist)		@@\
! AllTarget(lib/**/libname.sa.rev)					@@\
  									@@\
! lib/**/libname.sa.rev:  salist						@@\
! 	$(RM) $@							@@\
! 	$(AR) $@ salist							@@\
! 	$(RANLIB) $@							@@\
  									@@\
  clean::									@@\
! 	$(RM) lib/**/libname.sa.rev
! 
! #endif /* NormalSharedLibraryTarget */
! 
! 
! 
! 
! 
! /*
!  * NormalLibraryTarget2 - generate rules to create a library in two steps.
!  * This is used to create libraries with large numbers of files.
!  */
! #ifndef NormalLibraryTarget2
! #define	NormalLibraryTarget2(libname,objlist1,objlist2)			@@\
! AllTarget(lib/**/libname.a)						@@\
! 									@@\
! lib/**/libname.a: objlist1 objlist2					@@\
! 	$(RM) $@							@@\
! 	$(AR) $@ objlist1						@@\
! 	$(AR) $@ objlist2						@@\
! 	$(RANLIB) $@
! #endif /* NormalLibraryTarget2 */
  
  
  /*
--- 848,931 ----
  #ifndef SpecialObjectRule
  #define SpecialObjectRule(objs,depends,options)				@@\
  objs:	depends								@@\
! 	ObjectCompile(options)
  #endif /* SpecialObjectRule */
  
  
  /*
!  * NormalLibraryTarget - generate rules to create a library.
   */
! #ifndef NormalLibraryTarget
! #define	NormalLibraryTarget(libname,objlist)				@@\
! AllTarget(Concat(lib,libname.a))					@@\
  									@@\
! Concat(lib,libname.a): objlist						@@\
! 	$(RM) $@							@@\
! 	$(AR) $@ objlist						@@\
! 	RanLibrary($@)
! #endif /* NormalLibraryTarget */
  
  
  /*
!  * NormalLibraryTarget2 - generate rules to create a library in two steps.
!  * This is used to create libraries with large numbers of files.
   */
! #ifndef NormalLibraryTarget2
! #define	NormalLibraryTarget2(libname,objlist1,objlist2)			@@\
! AllTarget(Concat(lib,libname.a))					@@\
  									@@\
! Concat(lib,libname.a): objlist1 objlist2				@@\
! 	$(RM) $@							@@\
! 	$(AR) $@ objlist1						@@\
! 	$(AR) $@ objlist2						@@\
! 	RanLibrary($@)
! #endif /* NormalLibraryTarget2 */
  
  
  /*
!  * NormalLibraryTarget3 - generate rules to create a library in three steps.
!  * This is used to create libraries with very large numbers of files.
   */
! #ifndef NormalLibraryTarget3
! #define	NormalLibraryTarget3(libname,objlist1,objlist2,objlist3)	@@\
! AllTarget(Concat(lib,libname.a))					@@\
  									@@\
! Concat(lib,libname.a): objlist1 objlist2 objlist3			@@\
! 	$(RM) $@							@@\
! 	$(AR) $@ objlist1						@@\
! 	$(AR) $@ objlist2						@@\
! 	$(AR) $@ objlist3						@@\
! 	RanLibrary($@)
! #endif /* NormalLibraryTarget3 */
  
  
  /*
!  * NormalDepLibraryTarget - generate rules to create a library.
   */
! #ifndef NormalDepLibraryTarget
! #define	NormalDepLibraryTarget(libname,deplist,objlist)			@@\
! AllTarget(Concat(lib,libname.a))					@@\
  									@@\
! Concat(lib,libname.a): deplist						@@\
  	$(RM) $@							@@\
  	$(AR) $@ objlist						@@\
! 	RanLibrary($@)
! #endif /* NormalDepLibraryTarget */
  
  
  /*
!  * SubdirLibraryRule -
   */
! #ifndef SubdirLibraryRule
! #define	SubdirLibraryRule(objlist)					@@\
! all:: DONE								@@\
  									@@\
! DONE: objlist								@@\
! 	touch $@							@@\
  									@@\
  clean::									@@\
! 	$(RM) DONE
! #endif /* SubdirLibraryRule */
  
  
  /*
***************
*** 911,922 ****
   */
  #ifndef ProfiledLibraryTarget
  #define	ProfiledLibraryTarget(libname,objlist)				@@\
! AllTarget(lib/**/libname/**/_p.a)					@@\
  									@@\
! lib/**/libname/**/_p.a: objlist						@@\
  	$(RM) $@							@@\
  	cd profiled; $(AR) ../$@ objlist				@@\
! 	$(RANLIB) $@
  
  #endif /* ProfiledLibraryTarget */
  
--- 933,944 ----
   */
  #ifndef ProfiledLibraryTarget
  #define	ProfiledLibraryTarget(libname,objlist)				@@\
! AllTarget(Concat3(lib,libname,_p.a))					@@\
  									@@\
! Concat3(lib,libname,_p.a): objlist					@@\
  	$(RM) $@							@@\
  	cd profiled; $(AR) ../$@ objlist				@@\
! 	RanLibrary($@)
  
  #endif /* ProfiledLibraryTarget */
  
***************
*** 926,937 ****
   */
  #ifndef DebuggedLibraryTarget
  #define	DebuggedLibraryTarget(libname,objlist)				@@\
! AllTarget(lib/**/libname/**/_d.a)					@@\
  									@@\
! lib/**/libname/**/_d.a: objlist						@@\
  	$(RM) $@							@@\
  	cd debugger; $(AR) ../$@ objlist				@@\
! 	$(RANLIB) $@
  
  #endif /* DebuggedLibraryTarget */
  
--- 948,959 ----
   */
  #ifndef DebuggedLibraryTarget
  #define	DebuggedLibraryTarget(libname,objlist)				@@\
! AllTarget(Concat3(lib,libname,_d.a))					@@\
  									@@\
! Concat3(lib,libname,_d.a): objlist					@@\
  	$(RM) $@							@@\
  	cd debugger; $(AR) ../$@ objlist				@@\
! 	RanLibrary($@)
  
  #endif /* DebuggedLibraryTarget */
  
***************
*** 941,951 ****
   */
  #ifndef AliasedLibraryTarget
  #define	AliasedLibraryTarget(libname,alias)				@@\
! AllTarget(lib/**/alias.a)						@@\
  									@@\
! lib/**/alias.a: lib/**/libname.a					@@\
  	$(RM) $@							@@\
! 	$(LN) lib/**/libname.a $@
  #endif /* AliasedLibraryTarget */
  
  
--- 963,973 ----
   */
  #ifndef AliasedLibraryTarget
  #define	AliasedLibraryTarget(libname,alias)				@@\
! AllTarget(Concat(lib,alias.a))						@@\
  									@@\
! Concat(lib,alias.a): Concat(lib,libname.a)				@@\
  	$(RM) $@							@@\
! 	$(LN) Concat(lib,libname.a) $@
  #endif /* AliasedLibraryTarget */
  
  
***************
*** 969,977 ****
   */
  #ifndef ProfiledRelocatableTarget
  #define	ProfiledRelocatableTarget(objname,objlist)			@@\
! AllTarget(objname/**/_p.o)						@@\
  									@@\
! objname/**/_p.o: objlist						@@\
  	$(RM) $@							@@\
  	$(LD) -X -r objlist -o $@
  
--- 991,999 ----
   */
  #ifndef ProfiledRelocatableTarget
  #define	ProfiledRelocatableTarget(objname,objlist)			@@\
! AllTarget(Concat(objname,_p.o))						@@\
  									@@\
! Concat(objname,_p.o): objlist						@@\
  	$(RM) $@							@@\
  	$(LD) -X -r objlist -o $@
  
***************
*** 984,992 ****
   */
  #ifndef DebuggedRelocatableTarget
  #define	DebuggedRelocatableTarget(objname,objlist)			@@\
! AllTarget(objname/**/_d.o)						@@\
  									@@\
! objname/**/_d.o: objlist						@@\
  	$(RM) $@							@@\
  	$(LD) -X -r objlist -o $@
  
--- 1006,1014 ----
   */
  #ifndef DebuggedRelocatableTarget
  #define	DebuggedRelocatableTarget(objname,objlist)			@@\
! AllTarget(Concat(objname,_d.o))						@@\
  									@@\
! Concat(objname,_d.o): objlist						@@\
  	$(RM) $@							@@\
  	$(LD) -X -r objlist -o $@
  
***************
*** 999,1009 ****
   */
  #ifndef LintLibraryTarget
  #define	LintLibraryTarget(libname,srclist)				@@\
! lintlib:: llib-l/**/libname.ln						@@\
  									@@\
! llib-l/**/libname.ln: srclist						@@\
  	$(RM) $@							@@\
! 	$(LINT) $(LINTLIBFLAG)/**/libname $(LINTFLAGS) srclist
  #endif /* LintLibraryTarget */
  
  
--- 1021,1031 ----
   */
  #ifndef LintLibraryTarget
  #define	LintLibraryTarget(libname,srclist)				@@\
! lintlib:: Concat(llib-l,libname.ln)					@@\
  									@@\
! Concat(llib-l,libname.ln): srclist					@@\
  	$(RM) $@							@@\
! 	$(LINT) Concat($(LINTLIBFLAG),libname) $(LINTFLAGS) srclist
  #endif /* LintLibraryTarget */
  
  
***************
*** 1040,1045 ****
--- 1062,1077 ----
  #endif
  
  
+ /*
+  * LinkFile - link a file
+  */
+ #ifndef LinkFile
+ #define LinkFile(tofile,fromfile)					@@\
+ tofile:: fromfile							@@\
+ 	$(RM) $@							@@\
+ 	$(LN) $? $@
+ #endif
+ 
  
  #ifndef MakeSubincludesForBuild
  #define MakeSubincludesForBuild(step,dir,srclist)			@@\
***************
*** 1050,1056 ****
  		(set -x; cd dir; $(LN) ../$$i .); \			@@\
  	done								@@\
  									@@\
! MakeDirectories(dir,dir)						@@\
  									@@\
  clean::									@@\
  	@-(if [ -d dir ]; then \					@@\
--- 1082,1089 ----
  		(set -x; cd dir; $(LN) ../$$i .); \			@@\
  	done								@@\
  									@@\
! dir::									@@\
! 	$(MKDIRHIER) dir						@@\
  									@@\
  clean::									@@\
  	@-(if [ -d dir ]; then \					@@\
***************
*** 1098,1108 ****
   */
  #ifndef DependSubdirs
  #define DependSubdirs(dirs) \
! NamedTargetSubdirs(depend,dirs,"depending", /**/,depend)
  #endif /* DependSubdirs */
  
  
  /*
   * InstallSubdirs - generate rules to recursively install programs and files.
   */
  #ifndef InstallSubdirs
--- 1131,1153 ----
   */
  #ifndef DependSubdirs
  #define DependSubdirs(dirs) \
! NamedTargetSubdirs(depend,dirs,"depending",NullParameter,depend)
  #endif /* DependSubdirs */
  
  
  /*
+  * ForceSubdirs - force make to build subdirectories
+  */
+ #ifndef ForceSubdirs
+ #define ForceSubdirs(dirs)						@@\
+ dirs: FRC								@@\
+ 	@cd $@ ; echo "making all in $(CURRENT_DIR)/$@..."; \		@@\
+ 	$(MAKE) $(MFLAGS) PassCDebugFlags all				@@\
+ 									@@\
+ FRC:
+ #endif /* ForceSubdirs */
+ 
+ /*
   * InstallSubdirs - generate rules to recursively install programs and files.
   */
  #ifndef InstallSubdirs
***************
*** 1125,1131 ****
   */
  #ifndef IncludesSubdirs
  #define IncludesSubdirs(dirs) \
! NamedTargetSubdirs(includes,dirs,including, /**/,includes)
  #endif
  
  
--- 1170,1176 ----
   */
  #ifndef IncludesSubdirs
  #define IncludesSubdirs(dirs) \
! NamedTargetSubdirs(includes,dirs,including,NullParameter,includes)
  #endif
  
  
***************
*** 1148,1154 ****
   */
  #ifndef NamedTagSubdirs
  #define NamedTagSubdirs(name,dirs) \
! NamedTargetSubdirs(name,dirs,"tagging",TAGS='$(TAGS)' ETAGS='$(ETAGS)',tags)
  #endif /* TagSubdirs */
  
  #ifndef TagSubdirs
--- 1193,1199 ----
   */
  #ifndef NamedTagSubdirs
  #define NamedTagSubdirs(name,dirs) \
! NamedTargetSubdirs(name,dirs,"tagging",TAGS='$(TAGS)',tags)
  #endif /* TagSubdirs */
  
  #ifndef TagSubdirs
***************
*** 1188,1194 ****
  /*
   * MakeMakeSubdirs - generate rules to recursively recreate Makefiles as part
   * of the specified step in the build.  If $(TOP) is set to an absolute path, 
!  * don't prepend the ../ prefix.  This makes running things outside of the 
   * source tree to be much easier.
   */
  #ifndef MakeMakeSubdirs
--- 1233,1239 ----
  /*
   * MakeMakeSubdirs - generate rules to recursively recreate Makefiles as part
   * of the specified step in the build.  If $(TOP) is set to an absolute path, 
!  * do not prepend the ../ prefix.  This makes running things outside of the 
   * source tree to be much easier.
   */
  #ifndef MakeMakeSubdirs
***************
*** 1195,1257 ****
  #define MakeMakeSubdirs(dirs,target)					@@\
  target::								@@\
  	@case '${MFLAGS}' in *[ik]*) set +e;; esac; \			@@\
- 	case '${MFLAGS}' in *n*) executeit="no";; esac; \		@@\
  	for i in dirs ;\						@@\
  	do \								@@\
  		case "$$i" in \						@@\
! 		./?*/?*/?*/?*)	newtop=../../../..;; \			@@\
! 		./?*/?*/?*)	newtop=../../..;; \			@@\
! 		./?*/?*)	newtop=../..;; \			@@\
! 		./?*)		newtop=..;; \				@@\
! 		*/?*/?*/?*)	newtop=../../../..;; \			@@\
! 		*/?*/?*)	newtop=../../..;; \			@@\
! 		*/?*)		newtop=../..;; \			@@\
! 		*)		newtop=..;; \				@@\
  		esac; \							@@\
  		case "$(TOP)" in \					@@\
! 		/?*) imaketop=$(TOP) ; top=$(TOP) ; curdir=$(CURRENT_DIR)/;; \ @@\
! 		.) imaketop=$$newtop/ ; top=$$newtop ; curdir= ;; \	@@\
! 		*) imaketop=$$newtop/ ; top=$$newtop/$(TOP) ; curdir=$(CURRENT_DIR)/ ;; \	@@\
  		esac; \							@@\
! 		echo "making Makefiles in $${curdir}$$i..."; \		@@\
! 		cd $$i; \						@@\
! 		$(RM) Makefile.bak; \					@@\
! 		if [ -f Makefile ]; then \				@@\
! 			echo "	$(MV) Makefile Makefile.bak"; \		@@\
! 			if [ "$$executeit" != "no" ]; then \		@@\
! 				$(MV) Makefile Makefile.bak; \		@@\
! 			fi; \						@@\
! 		fi; \							@@\
! 		if [ "$$executeit" != "no" ]; then \			@@\
! 			ImakeSubCmdHelper -DTOPDIR=$$top -DCURDIR=$${curdir}$$i -f$(SRCSUBDIR)Imakefile; \ @@\
! 		fi; \							@@\
! 		$(MAKE) $(MFLAGS) Makefiles; \				@@\
! 		cd $$newtop; \						@@\
  	done
  
- #ifdef SourceTop
-         SRCSUBDIR = SourceTop/$${curdir}$${i}/
- #endif
  
! #ifdef UseImakeInstalled
! #define ImakeSubCmdHelper $(IMAKE) -I$${imaketop}$(NEWTOP)$(IRULESRC) $(IMAKE_DEFINES)
! #else
! #ifdef UseInstalled
! #define ImakeSubCmdHelper $(IMAKE_CMD)
! #else
! #define ImakeSubCmdHelper $${imaketop}$(NEWTOP)$(IMAKE) -I$${imaketop}$(NEWTOP)$(IRULESRC) $(IMAKE_DEFINES)
! #endif
! #endif
  
- #endif /* MakeMakeSubdirs */
  
  /*
   * MakefileSubdirs - generate rules to create Makefiles.
   */
  #ifndef MakefileSubdirs
! #define MakefileSubdirs(dirs)	MakeMakeSubdirs(dirs,Makefiles)
  #endif /* MakefileSubdirs */
  
  
  /*
   * CppScriptTarget - generate rules to create a shell script by running the
--- 1240,1327 ----
  #define MakeMakeSubdirs(dirs,target)					@@\
  target::								@@\
  	@case '${MFLAGS}' in *[ik]*) set +e;; esac; \			@@\
  	for i in dirs ;\						@@\
  	do \								@@\
+ 		echo "making Makefiles in $(CURRENT_DIR)/$$i..."; \	@@\
  		case "$$i" in \						@@\
! 		./?*/?*/?*/?*) newtop=../../../../ sub=subsubsubsub;; \	@@\
! 		./?*/?*/?*) newtop=../../../ sub=subsubsub;; \		@@\
! 		./?*/?*)    newtop=../../ sub=subsub;; \		@@\
! 		./?*)       newtop=../ sub=sub;; \			@@\
! 		*/?*/?*/?*)    newtop=../../../../ sub=subsubsubsub;; \	@@\
! 		*/?*/?*)    newtop=../../../ sub=subsubsub;; \		@@\
! 		*/?*)       newtop=../../ sub=subsub;; \		@@\
! 		*)	    newtop=../ sub=sub;; \			@@\
  		esac; \							@@\
  		case "$(TOP)" in \					@@\
! 		/?*) newtop=  upprefix=  ;; \				@@\
! 		*) upprefix=../ ;; \					@@\
  		esac; \							@@\
! 		$(MAKE) $${sub}dirMakefiles UPPREFIX=$$upprefix NEWTOP=$$newtop \		@@\
! 		MAKEFILE_SUBDIR=$$i NEW_CURRENT_DIR=$(CURRENT_DIR)/$$i;\ @@\
  	done
+ #endif /* MakeMakeSubdirs */
  
  
! /*
!  * MakeNsubdirMakefiles - generate rules to create sub Makefiles.
!  */
! #ifndef MakeNsubdirMakefiles
! #define MakeNsubdirMakefiles()						@@\
! subdirMakefiles:							@@\
! 	$(RM) $(MAKEFILE_SUBDIR)/Makefile.bak				@@\
! 	-@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \		@@\
! 	$(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ @@\
! 	else exit 0; fi							@@\
! 	cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \	@@\
! 	$(MAKE) $(MFLAGS) Makefiles 					@@\
! 									@@\
! subsubdirMakefiles:							@@\
! 	$(RM) $(MAKEFILE_SUBDIR)/Makefile.bak				@@\
! 	-@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \		@@\
! 	$(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ @@\
! 	else exit 0; fi							@@\
! 	cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \	@@\
! 	$(MAKE) $(MFLAGS) Makefiles 					@@\
! 									@@\
! subsubsubdirMakefiles:							@@\
! 	$(RM) $(MAKEFILE_SUBDIR)/Makefile.bak				@@\
! 	-@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \		@@\
! 	$(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ @@\
! 	else exit 0; fi @@\
! 	cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(UPPREFIX)$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \	@@\
! 	$(MAKE) $(MFLAGS) Makefiles 					@@\
! 									@@\
! subsubsubsubdirMakefiles:						@@\
! 	$(RM) $(MAKEFILE_SUBDIR)/Makefile.bak				@@\
! 	-@if [ -f $(MAKEFILE_SUBDIR)/Makefile ]; then set -x; \		@@\
! 	$(MV) $(MAKEFILE_SUBDIR)/Makefile $(MAKEFILE_SUBDIR)/Makefile.bak; \ @@\
! 	else exit 0; fi 						@@\
! 	cd $(MAKEFILE_SUBDIR); $(IMAKE_CMD) -DTOPDIR=$(UPPREFIX)$(UPPREFIX)$(UPPREFIX)$(UPPREFIX)$(TOP) -DCURDIR=$(NEW_CURRENT_DIR); \	@@\
! 	$(MAKE) $(MFLAGS) Makefiles
! #endif /* MakeNsubdirMakefiles */
  
  
  /*
   * MakefileSubdirs - generate rules to create Makefiles.
   */
  #ifndef MakefileSubdirs
! #define MakefileSubdirs(dirs)						@@\
! MakeMakeSubdirs(dirs,Makefiles)						@@\
! 									@@\
! MakeNsubdirMakefiles()
  #endif /* MakefileSubdirs */
  
+ /*
+  * Translate XCOMM into pound sign with sed, rather than passing -DXCOMM=XCOMM
+  * to cpp, because that trick does not work on all ANSI C preprocessors.
+  * Also delete line numbers from the cpp output (-P is not portable, I guess).
+  */
+ #ifndef CppSedMagic
+ #define CppSedMagic sed -e '/^#  *[0-9][0-9]*  *.*$$/d' \
+ 		    -e '/^XCOMM$$/s//#/' \
+ 		    -e '/^XCOMM[^a-zA-Z0-9_]/s/^XCOMM/#/'
+ #endif /* CppSedMagic */
  
  /*
   * CppScriptTarget - generate rules to create a shell script by running the
***************
*** 1263,1270 ****
  #define CppScriptTarget(dst,src,defs,deplist)				@@\
  dst::  src deplist							@@\
  	$(RM) $@							@@\
! 	$(CPP) defs <src | \						@@\
! 		sed -e '/^#  *[0-9][0-9]*  *.*$$/d' >$@			@@\
  	chmod a+x $@
  #else
  #define CppScriptTarget(dst,src,defs,deplist)				@@\
--- 1333,1339 ----
  #define CppScriptTarget(dst,src,defs,deplist)				@@\
  dst::  src deplist							@@\
  	$(RM) $@							@@\
! 	CppSedMagic <src | $(CPP) defs | CppSedMagic >$@		@@\
  	chmod a+x $@
  #else
  #define CppScriptTarget(dst,src,defs,deplist)				@@\
***************
*** 1271,1278 ****
  dst::  src deplist							@@\
  	$(RM) $@							@@\
  	echo \: >$@							@@\
! 	sed '1d' src | $(CPP) defs  | \					@@\
! 		sed -e '/^#  *[0-9][0-9]*  *.*$$/d' >>$@		@@\
  	chmod a+x $@
  #endif /* ExecableScripts */
  #endif /* CppScriptTarget */
--- 1340,1346 ----
  dst::  src deplist							@@\
  	$(RM) $@							@@\
  	echo \: >$@							@@\
! 	sed '1d' src | $(CPP) defs | CppSedMagic >>$@			@@\
  	chmod a+x $@
  #endif /* ExecableScripts */
  #endif /* CppScriptTarget */
***************
*** 1284,1292 ****
   */
  #ifndef MakeScriptFromCpp
  #define MakeScriptFromCpp(name,defs)					@@\
! CppScriptTarget(name,name.cpp,defs, /**/)
  #endif /* MakeScriptFromCpp */
  
  
  /*
   * MakeDirectories - generate rules to create a hierarchy of directories.
--- 1352,1366 ----
   */
  #ifndef MakeScriptFromCpp
  #define MakeScriptFromCpp(name,defs)					@@\
! CppScriptTarget(name,name.cpp,defs,NullParameter)
  #endif /* MakeScriptFromCpp */
  
+ #ifndef CppFileTarget
+ #define CppFileTarget(dst,src,defs,deplist)				@@\
+ dst::  src deplist							@@\
+ 	$(RM) $@							@@\
+ 	$(CPP) defs <src | CppSedMagic >$@
+ #endif /* CppFileTarget */
  
  /*
   * MakeDirectories - generate rules to create a hierarchy of directories.
***************
*** 1294,1302 ****
  #ifndef MakeDirectories
  #define MakeDirectories(step,dirs)					@@\
  step::									@@\
! 	$(MKDIRHIER) dirs
  #endif /* MakeDirectories */
  
  /*
   * AllTarget - generate rules to build necessary things during make all.
   */
--- 1368,1495 ----
  #ifndef MakeDirectories
  #define MakeDirectories(step,dirs)					@@\
  step::									@@\
! 	@case '${MFLAGS}' in *[i]*) set +e;; esac;			@@\
! 	DirFailPrefix@for i in dirs; do if [ -d $(DESTDIR)$$i ]; then \	@@\
! 		set +x; else (set -x; $(MKDIRHIER) $(DESTDIR)$$i); fi \	@@\
! 	done
  #endif /* MakeDirectories */
  
+ 
+ /*
+  * MakeFontsDir - generate rules to build fonts.dir database.
+  */
+ #ifndef MakeFontsDir
+ #define MakeFontsDir(deplist)						@@\
+ all:: fonts.dir								@@\
+ 									@@\
+ fonts.dir:  deplist							@@\
+ 	$(MKFONTDIR) .							@@\
+ 									@@\
+ clean::									@@\
+ 	$(RM) fonts.dir
+ #endif /* MakeFontsDir */
+ 
+ 
+ /*
+  * MakeFonts - generate rules to build font database.
+  */
+ #ifndef MakeFonts
+ #define MakeFonts()							@@\
+ all::  $(OBJS)								@@\
+ 									@@\
+ MakeFontsDir($(OBJS))							@@\
+ 									@@\
+ clean::									@@\
+ 	$(RM) *.snf *.snf.Z *.pcf *.pcf.Z
+ #endif /* MakeFonts */
+ 
+ 
+ /*
+  * InstallFontObjs - generate rules to install font files
+  */
+ #ifndef InstallFontObjs
+ #define InstallFontObjs(objs,dest)					@@\
+ InstallMultipleFlags(objs,dest,$(INSTDATFLAGS))				@@\
+ 									@@\
+ install::  fonts.dir							@@\
+ 	MakeDir($(DESTDIR)dest)						@@\
+ 	$(INSTALL) -c $(INSTDATFLAGS) fonts.dir $(DESTDIR)dest
+ #endif /* InstallFontObjs */
+ 
+ 
+ /*
+  * InstallFonts - generate rules to install font files
+  */
+ #ifndef InstallFonts
+ #define InstallFonts(dest)						@@\
+ InstallFontObjs($(OBJS),dest)
+ #endif /* InstallFonts */
+ 
+ 
+ /*
+  * InstallFontAliases - generate rules to install font aliases databases. 
+  */
+ #ifndef InstallFontAliases
+ #define InstallFontAliases(dest)					@@\
+ install::  fonts.alias							@@\
+ 	MakeDir($(DESTDIR)dest)						@@\
+ 	$(INSTALL) -c $(INSTDATFLAGS) fonts.alias $(DESTDIR)dest
+ #endif /* InstallFontAliases */
+ 
+ #ifndef FontSrc
+ #define FontSrc(basename) basename.bdf
+ #endif
+ 
+ #ifndef FontBaseObj
+ #ifdef SnfFonts
+ #define FontBaseObj(basename)basename.snf
+ #else
+ #define FontBaseObj(basename)basename.pcf
+ #endif
+ #endif
+ 
+ /*
+  * InstallFontScale - generate rules to install font scale database.
+  */
+ #ifndef InstallFontScale
+ #define InstallFontScale(dest)						@@\
+ install::  fonts.scale							@@\
+ 	MakeDir($(DESTDIR)dest)						@@\
+ 	$(INSTALL) -c $(INSTDATFLAGS) fonts.scale $(DESTDIR)dest
+ #endif /* InstallFontScale */
+ 
+ /*
+  * UncompressedFontTarget
+  */
+ #ifndef UncompressedFontTarget
+ #ifdef SnfFonts
+ #define UncompressedFontTarget(basename)				@@\
+ FontBaseObj(basename):  FontSrc(basename)				@@\
+ 	$(FONTC) $(FONTCFLAGS) $? >$@
+ #else
+ #define UncompressedFontTarget(basename)				@@\
+ FontBaseObj(basename):  FontSrc(basename)				@@\
+ 	$(FONTC) $(FONTCFLAGS) $? -o $@
+ #endif
+ #endif /* CompressedFontTarget */
+ 
+ /*
+  * CompressedFontTarget
+  */
+ #ifndef CompressedFontTarget
+ #define CompressedFontTarget(basename)					@@\
+ FontBaseObj(basename).Z:  FontSrc(basename)				@@\
+ 	$(FONTC) $(FONTCFLAGS) $? | $(COMPRESS) > $@
+ #endif /* CompressedFontTarget */
+ 
+ #ifdef CompressAllFonts
+ #define FontTarget(basename) CompressedFontTarget(basename)
+ #define FontObj(basename) FontBaseObj(basename).Z
+ #else
+ #define FontTarget(basename) UncompressedFontTarget(basename)
+ #define FontObj(basename) FontBaseObj(basename)
+ #endif /* CompressAllFonts */
+ 
  /*
   * AllTarget - generate rules to build necessary things during make all.
   */
***************
*** 1304,1306 ****
--- 1497,1503 ----
  #define AllTarget(depends)						@@\
  all:: depends
  #endif /* AllTarget */
+ 
+ #ifdef DefineOldLibraryRules
+ #include <oldlib.rules>
+ #endif

*** ./config/Imake.tmpl.old	1993/02/26 22:17:57
--- ./config/Imake.tmpl	1993/02/26 22:18:21
***************
*** 2,29 ****
   * generic imake template
   */
  
! /**/# $Source$
! /**/# $Author$
! /**/# $Id$
! /**/#
! 
! /**/###########################################################################
! /**/# Makefile generated from IMAKE_TEMPLATE and INCLUDE_IMAKEFILE
! /**/# $XConsortium: Imake.tmpl,v 1.77 89/12/18 17:01:37 jim Exp $
! /**/#
! /**/# Platform-specific parameters may be set in the appropriate .cf
! /**/# configuration files.  Site-wide parameters may be set in the file
! /**/# site.def.  Full rebuilds are recommended if any parameters are changed.
! /**/#
! /**/# If your C preprocessor doesn't define any unique symbols, you'll need
! /**/# to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing
! /**/# "make Makefile", "make Makefiles", or "make World").
! /**/#
! /**/# If you absolutely can't get imake to work, you'll need to set the 
! /**/# variables at the top of each Makefile as well as the dependencies at the
! /**/# bottom (makedepend will do this automatically).
! /**/#
! 
  
  #define	YES	1
  #define NO	0
--- 2,22 ----
   * generic imake template
   */
  
! #ifndef XCOMM
! #define XCOMM #
! #endif
! XCOMM -------------------------------------------------------------------------
! XCOMM Makefile generated from IMAKE_TEMPLATE and INCLUDE_IMAKEFILE
! XCOMM $XConsortium: Imake.tmpl,v 1.139 91/09/16 08:52:48 rws Exp $
! XCOMM
! XCOMM Platform-specific parameters may be set in the appropriate <vendor>.cf
! XCOMM configuration files.  Site-specific parameters should be set in the file
! XCOMM site.def.  Full rebuilds are recommended if any parameters are changed.
! XCOMM
! XCOMM If your C preprocessor does not define any unique symbols, you will need
! XCOMM to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing
! XCOMM "make World" the first time).
! XCOMM
  
  #define	YES	1
  #define NO	0
***************
*** 33,60 ****
   * To add support for another platform:
   * 
   *     1.  Identify a machine-specific cpp symbol.  If your preprocessor 
!  *         doesn't have any built in, you'll need to add the symbol to the
!  *         cpp_argv table in config/imake.c and rebuild imake with the
   *         BOOTSTRAPCFLAGS variable set (see the macII for an example).
   *
-  *     [ignore this for now...no makedepend with Kerberos V5 (yet...)]
   *     2.  Add all machine-specific cpp symbols (either defined by you or by
   *         the preprocessor or compiler) to the predefs table in 
!  *         config/makedepend/main.c.
   *
   *     3.  But a new #ifdef block below that defines MacroIncludeFile and
   *         MacroFile for your new platform and then #undefs the machine-
   *         specific preprocessor symbols (to avoid problems with file names).
   *
!  *     4.  Create a .cf file with the name given by MacroFile.  See
!  *	   existing .cf files for examples of what to put there.
   */
  
- #ifdef tahoe
- #define TahoeArchitecture
- #endif
- 
- 
  #ifdef ultrix
  #define MacroIncludeFile <ultrix.cf>
  #define MacroFile ultrix.cf
--- 26,46 ----
   * To add support for another platform:
   * 
   *     1.  Identify a machine-specific cpp symbol.  If your preprocessor 
!  *         does not have any built in, you will need to add the symbol to the
!  *         cpp_argv table in config/imakemdep.h and rebuild imake with the
   *         BOOTSTRAPCFLAGS variable set (see the macII for an example).
   *
   *     2.  Add all machine-specific cpp symbols (either defined by you or by
   *         the preprocessor or compiler) to the predefs table in 
!  *         config/imakemdep.h.
   *
   *     3.  But a new #ifdef block below that defines MacroIncludeFile and
   *         MacroFile for your new platform and then #undefs the machine-
   *         specific preprocessor symbols (to avoid problems with file names).
   *
!  *     4.  Create a .cf file with the name given by MacroFile.
   */
  
  #ifdef ultrix
  #define MacroIncludeFile <ultrix.cf>
  #define MacroFile ultrix.cf
***************
*** 71,87 ****
  #endif
  
  #if defined(vax) && !defined(UltrixArchitecture)
! #define MacroIncludeFile <vaxbsd.cf>
! #define MacroFile vaxbsd.cf
  #undef vax
  #define VaxArchitecture
  #endif
  
- #if defined(tahoe) && !defined(SYSV)
- #define MacroIncludeFile <tahoebsd.cf>
- #define MacroFile tahoebsd.cf
- #endif
- 
  #ifdef sun
  #define MacroIncludeFile <sun.cf>
  #define MacroFile sun.cf
--- 57,68 ----
  #endif
  
  #if defined(vax) && !defined(UltrixArchitecture)
! #define MacroIncludeFile <bsd.cf>
! #define MacroFile bsd.cf
  #undef vax
  #define VaxArchitecture
  #endif
  
  #ifdef sun
  #define MacroIncludeFile <sun.cf>
  #define MacroFile sun.cf
***************
*** 114,120 ****
--- 95,116 ----
  #define MacroIncludeFile <sony.cf>
  #define MacroFile sony.cf
  #undef sony
+ #undef sony_news
  #define SonyArchitecture
+ #ifdef mc68020
+ #undef mc68020
+ #undef mc68030
+ #define Mc68020Architecture
+ #endif
+ #ifdef mips
+ #undef mips
+ #define MipsArchitecture
+ #endif
+ #if !defined(bsd43) || defined(SYSTYPE_SYSV)
+ #define SonySysvArchitecture
+ #else
+ #define SonyBsdArchitecture
+ #endif
  #endif /* sony */
  
  #ifdef M4310
***************
*** 143,149 ****
  #define MacroIncludeFile <cray.cf>
  #define MacroFile cray.cf
  #undef cray
- #undef CRAY
  #define CrayArchitecture
  #endif /* CRAY */
  
--- 139,144 ----
***************
*** 163,185 ****
  #define StellarArchitecture
  #endif
  
! 
! /*
!  * A convenience for people running on rt's since they define ibm032, and for
!  * people running AIX (note that AOS will no longer be supported by IBM).
!  */
! #if defined(ibm032) && !defined(ibm)
! #define ibm
! #endif
! 
! #if defined(aix) && !defined(ibm)
! #define ibm
! #endif
! 
! #if defined(ibm)
  #define MacroIncludeFile <ibm.cf>
  #define MacroFile ibm.cf
  #undef ibm
  #define IBMArchitecture
  #ifdef i386
  #undef i386
--- 158,169 ----
  #define StellarArchitecture
  #endif
  
! #if defined(ibm) || defined(_IBMR2) || defined(ibm032) || defined(aix)
  #define MacroIncludeFile <ibm.cf>
  #define MacroFile ibm.cf
+ #ifdef ibm
  #undef ibm
+ #endif
  #define IBMArchitecture
  #ifdef i386
  #undef i386
***************
*** 193,205 ****
  #undef aix
  #define AIXArchitecture
  #endif
  #endif /* ibm */
  
! 
  
  #ifndef MacroIncludeFile
! /**/# WARNING:  Imake.tmpl not configured; guessing at definitions!!!
! /**/# This might mean that BOOTSTRAPCFLAGS wasn't set when building imake.
  #define MacroIncludeFile <generic.cf>
  #define MacroFile generic.cf
  #endif
--- 177,260 ----
  #undef aix
  #define AIXArchitecture
  #endif
+ #ifdef _IBMR2
+ #undef _IBMR2
+ #define RsArchitecture
+ #endif
  #endif /* ibm */
  
! #ifdef luna
! #undef luna
! #define MacroIncludeFile <luna.cf>
! #define MacroFile luna.cf
! #ifdef mc68000
! #undef mc68000
! #define Mc68000Architecture
! #else
! #undef mc88000
! #define Mc88000Architecture
! #endif
! #endif
! 
! #ifdef Mips
! #  define MacroIncludeFile "Mips.cf"
! #  define MacroFile Mips.cf
! #  undef Mips
! #  if defined(SYSTYPE_BSD43) || defined(BSD) || defined(BSD43)
! #    define MipsBsdArchitecture
! #  else /* BSD */
! #    define MipsSysvArchitecture
! #  endif /* BSD */
! #endif /* Mips */
! 
! #ifdef MOTOROLA
! # define MacroIncludeFile <moto.cf>
! # define MacroFile moto.cf
! # undef MOTOROLA	
! # ifdef SYSV
! #  define MotoR3Architecture
! # endif
! # ifdef SVR4
! #  define MotoR4Architecture
! # endif
! #endif /* MOTOROLA */
! 
! #ifdef SYSV386
! # define MacroIncludeFile <x386.cf>
! # define MacroFile x386.cf
! # ifdef SVR4
! #  define i386SVR4Architecture
! # else
! #  define i386SVR3Architecture
! # endif
! #endif /* SYSV386 */
! 
! #ifdef DGUX
! #define MacroIncludeFile <DGUX.cf>
! #define MacroFile DGUX.cf
! #undef DGUX
! #define DguxArchitecture
! #endif
! 
! #ifdef __convex__
! # define MacroIncludeFile <convex.cf>
! # define MacroFile convex.cf
! # ifdef convex
! #  undef convex
! # endif
! # define ConvexArchitecture
! #endif
! 
! #ifdef NeXT
! #define MacroIncludeFile <next.cf>
! #define MacroFile next.cf
! #undef NeXT
! #define NeXTArchitecture
! #endif
  
  #ifndef MacroIncludeFile
! XCOMM WARNING:  Imake.tmpl not configured; guessing at definitions!!!
! XCOMM This might mean that BOOTSTRAPCFLAGS was not set when building imake.
  #define MacroIncludeFile <generic.cf>
  #define MacroFile generic.cf
  #endif
***************
*** 211,234 ****
   *****************************************************************************/
  
  
! /**/###########################################################################
! /**/# platform-specific configuration parameters - edit MacroFile to change
  #include MacroIncludeFile
  
! /**/###########################################################################
! /**/# site-specific configuration parameters - edit site.def to change
  #include <site.def>
  
  /*
   * defaults for various generic parameters; set in site.def if needed
   */
  
  #ifndef SystemV
! #ifdef SYSV
! #define SystemV			YES	/* need system 5 style */
! #else
! #define SystemV			NO	/* bsd */
  #endif
  #endif
  #ifndef OSMajorVersion
  #define OSMajorVersion          0
--- 266,341 ----
   *****************************************************************************/
  
  
! XCOMM -------------------------------------------------------------------------
! XCOMM site-specific configuration parameters that need to come before
! XCOMM the platform-specific parameters - edit site.def to change
! #define BeforeVendorCF
! #include <site.def>
! #undef BeforeVendorCF
! 
! XCOMM -------------------------------------------------------------------------
! XCOMM platform-specific configuration parameters - edit MacroFile to change
  #include MacroIncludeFile
  
! /* It is a kludge to put these two macros here,
!  * but Project.tmpl needs them and it is not clear there is a better place.
!  */
! 
! /*
!  * Concat - concatenates two strings.
!  */
! #ifndef Concat
! #if __STDC__ && !defined(UnixCpp)
! #define ConcatX(a,b)a##b
! #define Concat(a,b) ConcatX(a,b)
! #else
! #define Concat(a,b)a/**/b
! #endif
! #endif
! 
! /*
!  * Concat3 - concatenates three strings.
!  */
! #ifndef Concat3
! #if __STDC__ && !defined(UnixCpp)
! #define Concat3X(a,b,c)a##b##c
! #define Concat3(a,b,c) Concat3X(a,b,c)
! #else
! #define Concat3(a,b,c)a/**/b/**/c
! #endif
! #endif
! 
! /*
!  * Concat4 - concatenates four strings.
!  */
! #ifndef Concat4
! #if __STDC__ && !defined(UnixCpp)
! #define Concat4X(a,b,c,d)a##b##c##d
! #define Concat4(a,b,c,d) Concat4X(a,b,c,d)
! #else
! #define Concat4(a,b,c,d)a/**/b/**/c/**/d
! #endif
! #endif
! 
! XCOMM -------------------------------------------------------------------------
! XCOMM site-specific configuration parameters that go after
! XCOMM the platform-specific parameters - edit site.def to change
! #define AfterVendorCF
  #include <site.def>
+ #undef AfterVendorCF
  
  /*
   * defaults for various generic parameters; set in site.def if needed
   */
  
+ #ifndef HasSharedLibraries
+ #define HasSharedLibraries NO
+ #endif
  #ifndef SystemV
! #define SystemV			NO	/* SYSV (R3) */
  #endif
+ #ifndef SystemV4
+ #define SystemV4		NO	/* SVR4 */
  #endif
  #ifndef OSMajorVersion
  #define OSMajorVersion          0
***************
*** 240,246 ****
  #define UnalignedReferencesAllowed NO	/* if arbitrary deref is okay */
  #endif
  #ifndef ExecableScripts
! #ifdef SYSV
  #define ExecableScripts		NO
  #else
  #define ExecableScripts		YES	/* kernel exec() can handle #! */
--- 347,353 ----
  #define UnalignedReferencesAllowed NO	/* if arbitrary deref is okay */
  #endif
  #ifndef ExecableScripts
! #if SystemV
  #define ExecableScripts		NO
  #else
  #define ExecableScripts		YES	/* kernel exec() can handle #! */
***************
*** 262,269 ****
  #define HasLargeTmp		NO	/* be paranoid */
  #endif
  #ifndef HasSockets
! #if SystemV
! #define HasSockets		NO	/* not yet... */
  #else
  #define HasSockets		YES	/* bsd does have them */
  #endif
--- 369,376 ----
  #define HasLargeTmp		NO	/* be paranoid */
  #endif
  #ifndef HasSockets
! #if SystemV || SystemV4
! #define HasSockets		NO	/* do not assume it has them */
  #else
  #define HasSockets		YES	/* bsd does have them */
  #endif
***************
*** 279,296 ****
  #define HasPutenv		NO	/* assume not */
  #endif
  #ifndef HasVoidSignalReturn
! #if SystemV
! #define HasVoidSignalReturn	YES
! #else
! #define HasVoidSignalReturn	NO	/* may or may not be true */
! #endif
  #endif
  #ifndef HasBsearch
! #if SystemV
! #define HasBsearch		YES
! #else
! #define HasBsearch		NO	/* stupid systems */
! #endif
  #endif
  #ifndef HasSaberC
  #define HasSaberC		NO	/* for people unclear on the concept */
--- 386,395 ----
  #define HasPutenv		NO	/* assume not */
  #endif
  #ifndef HasVoidSignalReturn
! #define HasVoidSignalReturn	YES	/* assume yes */
  #endif
  #ifndef HasBsearch
! #define HasBsearch		YES	/* assume yes */
  #endif
  #ifndef HasSaberC
  #define HasSaberC		NO	/* for people unclear on the concept */
***************
*** 301,357 ****
  #ifndef HasNdbm
  #define HasNdbm			NO
  #endif
! #ifndef HasDESLibrary
! #define HasDESLibrary		NO	/* if you have any DES library */
  #endif
  #ifndef NeedFunctionPrototypes
! #define NeedFunctionPrototypes NO
  #endif
  #ifndef NeedWidePrototypes
  #define NeedWidePrototypes	YES	/* mix and match ANSI-C, non-ANSI */
  #endif
  
! #ifndef HasSunOSSharedLibraries
! #define HasSunOSSharedLibraries NO
  #endif
  
! #ifndef SharedCodeDef
! #if HasSunOSSharedLibraries
! #define SharedCodeDef -DSHAREDCODE
! #else
! #define SharedCodeDef /**/
  #endif
  #endif
- #ifndef SharedLibraryDef
- #if HasSunOSSharedLibraries
- #define SharedLibraryDef -DSUNSHLIB	/* eventually will be SVR4SHLIB... */
- #ifndef HasSharedLibraries
- #define HasSharedLibraries YES
  #endif
  #else
! #define SharedLibraryDef /**/
! #ifndef HasSharedLibraries
! #define HasSharedLibraries NO
  #endif
  #endif
! #else
! #ifndef HasSharedLibraries
! #define HasSharedLibraries NO
  #endif
  #endif
- 
- #ifndef StripInstalledPrograms
- #define StripInstalledPrograms NO	/* leave symbol table just in case */
  #endif
! 
! #ifndef DestDir
! #define DestDir /* as nothing */
  #endif
- #ifndef UsrLibDir			/* if changed under SunOS with shared */
- #define UsrLibDir $(DESTDIR)/usr/lib	/* libs, then need to run ldconfig */
- #endif					/* as root */
- #ifndef IncRoot
- #define IncRoot $(DESTDIR)/usr/include
  #endif
  #ifndef UNCOMPRESSPATH
  #define UNCOMPRESSPATH /usr/ucb/uncompress
--- 400,468 ----
  #ifndef HasNdbm
  #define HasNdbm			NO
  #endif
! #ifndef HasSecureRPC
! #define HasSecureRPC		NO	/* if you have Secure RPC */
! #endif
! #ifndef HasShm
! #if SystemV || SystemV4
! #define HasShm			YES
! #else
! #define HasShm			NO
! #endif
! #endif
! #ifndef NeedConstPrototypes
! #define NeedConstPrototypes	NO
! #endif
! #ifndef NeedVarargsPrototypes
! #define NeedVarargsPrototypes	NO
! #endif
! #ifndef NeedNestedPrototypes
! #define NeedNestedPrototypes	NO
  #endif
  #ifndef NeedFunctionPrototypes
! #define NeedFunctionPrototypes (NeedVarargsPrototypes || NeedNestedPrototypes)
  #endif
  #ifndef NeedWidePrototypes
  #define NeedWidePrototypes	YES	/* mix and match ANSI-C, non-ANSI */
  #endif
  
! #ifndef StripInstalledPrograms
! #define StripInstalledPrograms NO	/* leave symbol table just in case */
  #endif
  
! #ifndef UsrLibDir
! #ifdef ProjectRoot
! #define UsrLibDir Concat(ProjectRoot,/lib)
! #ifndef AlternateUsrLibDir
! #define AlternateUsrLibDir YES
  #endif
+ #else
+ #define UsrLibDir /usr/lib
+ #ifndef AlternateUsrLibDir
+ #define AlternateUsrLibDir NO
  #endif
  #endif
  #else
! #ifndef AlternateUsrLibDir
! #define AlternateUsrLibDir YES
  #endif
  #endif
! #ifndef IncRoot
! #ifdef ProjectRoot
! #define IncRoot Concat(ProjectRoot,/include)
! #ifndef AlternateIncRoot
! #define AlternateIncRoot YES
  #endif
+ #else
+ #define IncRoot /usr/include
+ #ifndef AlternateIncRoot
+ #define AlternateIncRoot NO
  #endif
  #endif
! #else
! #ifndef AlternateIncRoot
! #define AlternateIncRoot YES
  #endif
  #endif
  #ifndef UNCOMPRESSPATH
  #define UNCOMPRESSPATH /usr/ucb/uncompress
***************
*** 368,393 ****
  #ifndef DefaultCDebugFlags
  #define DefaultCDebugFlags OptimizedCDebugFlags
  #endif
- #ifndef LibraryCDebugFlags
- #define LibraryCDebugFlags OptimizedCDebugFlags
- #endif
  #ifndef DefaultCCOptions
  #define DefaultCCOptions /* as nothing: this is for floating point, etc. */
  #endif
- #ifndef LibraryCCOptions
- #define LibraryCCOptions DefaultCCOptions
- #endif
- #ifndef ServerCCOptions
- #define ServerCCOptions DefaultCCOptions
- #endif
- #ifndef PexCDebugFlags
- #define PexCDebugFlags -g
- #endif
  #ifndef InstPgmFlags
! #define InstPgmFlags
! #endif
! #ifndef InstScrFlags
! #define InstScrFlags
  #endif
  #ifndef InstBinFlags
  #define InstBinFlags -m 0755
--- 479,489 ----
  #ifndef DefaultCDebugFlags
  #define DefaultCDebugFlags OptimizedCDebugFlags
  #endif
  #ifndef DefaultCCOptions
  #define DefaultCCOptions /* as nothing: this is for floating point, etc. */
  #endif
  #ifndef InstPgmFlags
! #define InstPgmFlags -s
  #endif
  #ifndef InstBinFlags
  #define InstBinFlags -m 0755
***************
*** 396,402 ****
  #define InstUidFlags -m 4755
  #endif
  #ifndef InstLibFlags
! #define InstLibFlags -m 0664
  #endif
  #ifndef InstIncFlags
  #define InstIncFlags -m 0444
--- 492,498 ----
  #define InstUidFlags -m 4755
  #endif
  #ifndef InstLibFlags
! #define InstLibFlags -m 0644
  #endif
  #ifndef InstIncFlags
  #define InstIncFlags -m 0444
***************
*** 411,418 ****
  #define InstKmemFlags InstUidFlags    /* put -g kmem -m 2755 in site.def... */
  #endif
  #ifndef ArCmd
! #if HasLargeTmp
! #define ArCmd ar cq	/* use /tmp for temp files */
  #else
  #define ArCmd ar clq	/* use local dir for temp files */
  #endif
--- 507,514 ----
  #define InstKmemFlags InstUidFlags    /* put -g kmem -m 2755 in site.def... */
  #endif
  #ifndef ArCmd
! #if HasLargeTmp | SystemV4
! #define ArCmd ar cq	/* do nothing special */
  #else
  #define ArCmd ar clq	/* use local dir for temp files */
  #endif
***************
*** 420,439 ****
  #ifndef BootstrapCFlags
  #define BootstrapCFlags /**/
  #endif
- #ifndef CcCmd
- #define CcCmd cc
- #endif
  #ifndef HasGcc
  #define HasGcc NO
  #endif
! #ifndef ServerCcCmd
! #define ServerCcCmd CcCmd
  #endif
- #ifndef LibraryCcCmd
- #define LibraryCcCmd CcCmd
  #endif
  #if HasFortran
! #ifndef FortranCmd			/* for xgks */
  #define FortranCmd f77
  #endif
  #ifndef FortranFlags
--- 516,542 ----
  #ifndef BootstrapCFlags
  #define BootstrapCFlags /**/
  #endif
  #ifndef HasGcc
  #define HasGcc NO
  #endif
! #if DbmGccCompiled
! #define GccStructFlags
! #else
! #define GccStructFlags -fpcc-struct-return
! #endif
! #ifndef CcCmd
! #if HasGcc2
! #define CcCmd gcc GccStructFlags
! #else
! #if HasGcc
! #define CcCmd gcc -fstrength-reduce GccStructFlags
! #else
! #define CcCmd cc
! #endif
  #endif
  #endif
  #if HasFortran
! #ifndef FortranCmd
  #define FortranCmd f77
  #endif
  #ifndef FortranFlags
***************
*** 456,463 ****
  #define PreProcessCmd CcCmd -E
  #endif
  #ifndef InstallCmd
! #if SystemV
  #define InstallCmd $(SCRIPTSRC)/bsdinst.sh	/* hack should be in project */
  #else
  #define InstallCmd install
  #endif
--- 559,570 ----
  #define PreProcessCmd CcCmd -E
  #endif
  #ifndef InstallCmd
! #if SystemV | SystemV4
! #ifdef UseInstalled
! #define InstallCmd $(BINDIR)/bsdinst		/* hack should be in project */
! #else
  #define InstallCmd $(SCRIPTSRC)/bsdinst.sh	/* hack should be in project */
+ #endif
  #else
  #define InstallCmd install
  #endif
***************
*** 469,475 ****
  #define LintCmd lint
  #endif
  #ifndef LintLibFlag
! #if SystemV
  #define LintLibFlag -o
  #else
  #define LintLibFlag -C
--- 576,582 ----
  #define LintCmd lint
  #endif
  #ifndef LintLibFlag
! #if SystemV || SystemV4
  #define LintLibFlag -o
  #else
  #define LintLibFlag -C
***************
*** 476,482 ****
  #endif
  #endif
  #ifndef LintOpts
! #if SystemV
  #define LintOpts -ax
  #else
  #define LintOpts -axz
--- 583,589 ----
  #endif
  #endif
  #ifndef LintOpts
! #if SystemV || SystemV4
  #define LintOpts -ax
  #else
  #define LintOpts -axz
***************
*** 483,489 ****
  #endif
  #endif
  #ifndef CpCmd
! #define CpCmd cp -p
  #endif
  #ifndef LnCmd
  #if SystemV
--- 590,596 ----
  #endif
  #endif
  #ifndef CpCmd
! #define CpCmd cp
  #endif
  #ifndef LnCmd
  #if SystemV
***************
*** 498,504 ****
  #ifndef MvCmd
  #define MvCmd mv
  #endif
! #if !defined(RanlibCmd) && !SystemV
  #define RanlibCmd ranlib
  #endif
  #ifndef RanlibInstFlags
--- 605,618 ----
  #ifndef MvCmd
  #define MvCmd mv
  #endif
! #ifndef DoRanlibCmd
! #if SystemV || SystemV4
! #define DoRanlibCmd 0
! #else
! #define DoRanlibCmd 1
! #endif
! #endif
! #ifndef RanlibCmd
  #define RanlibCmd ranlib
  #endif
  #ifndef RanlibInstFlags
***************
*** 507,519 ****
  #ifndef RmCmd
  #define RmCmd rm -f
  #endif
- #ifndef StandardCppDefines
- #if SystemV
- #define StandardCppDefines -DSYSV
- #else
- #define StandardCppDefines /**/
- #endif
- #endif
  #ifndef StandardIncludes
  #define StandardIncludes /**/			/* for platform-specifics */
  #endif
--- 621,626 ----
***************
*** 521,531 ****
  #if SystemV
  #define StandardDefines -DSYSV
  #else
  #define StandardDefines /**/
  #endif
  #endif
! #ifndef SaberDefines
! #define SaberDefines /**/
  #endif
  #ifndef NdbmDefines
  #if HasNdbm
--- 628,645 ----
  #if SystemV
  #define StandardDefines -DSYSV
  #else
+ #if SystemV4
+ #define StandardDefines -DSVR4
+ #else
  #define StandardDefines /**/
  #endif
  #endif
! #endif
! #ifndef StandardCppDefines
! #define StandardCppDefines StandardDefines
! #endif
! #ifndef Malloc0ReturnsNull
! #define Malloc0ReturnsNull NO
  #endif
  #ifndef NdbmDefines
  #if HasNdbm
***************
*** 535,563 ****
  #endif
  #endif
  #ifndef ExtraLibraries
  #define ExtraLibraries /**/
  #endif
  #ifndef ExtraLoadFlags
  #define ExtraLoadFlags /**/
  #endif
  #ifndef LdCombineFlags
  #define LdCombineFlags -X -r
  #endif
- #ifndef LdLibLocations
- #define LdLibLocations /**/
- #endif
- #ifndef CompatibilityFlags
- #define CompatibilityFlags /**/
  #endif
  #ifndef TagsCmd
  #define TagsCmd ctags
  #endif
- #ifndef EtagsCmd
- #define EtagsCmd etags
- #endif
  #ifndef LoaderLibPrefix
  #define LoaderLibPrefix /**/			/* cray does -l libX11.a */
  #endif
  #ifndef TOPDIR
  #define TOPDIR .
  #endif
--- 649,702 ----
  #endif
  #endif
  #ifndef ExtraLibraries
+ #if SystemV4
+ #if HasSockets
+ #define ExtraLibraries -lsocket -lnsl
+ #else
+ #define ExtraLibraries -lnsl
+ #endif
+ #else
  #define ExtraLibraries /**/
  #endif
+ #endif
  #ifndef ExtraLoadFlags
  #define ExtraLoadFlags /**/
  #endif
  #ifndef LdCombineFlags
+ #if SystemV4
+ #define LdCombineFlags -r
+ #else
  #define LdCombineFlags -X -r
  #endif
  #endif
  #ifndef TagsCmd
  #define TagsCmd ctags
  #endif
  #ifndef LoaderLibPrefix
  #define LoaderLibPrefix /**/			/* cray does -l libX11.a */
  #endif
+ #ifndef DependFlags
+ #define DependFlags /**/
+ #endif
+ #ifndef TroffCmd
+ #define TroffCmd psroff
+ #endif
+ #ifndef MsMacros
+ #define MsMacros -ms
+ #endif
+ #ifndef TblCmd
+ #define TblCmd tbl
+ #endif
+ #ifndef EqnCmd
+ #define EqnCmd eqn
+ #endif
+ #ifndef ExpandManNames
+ #if SystemV
+ #define ExpandManNames NO
+ #else
+ #define ExpandManNames YES
+ #endif
+ #endif
  #ifndef TOPDIR
  #define TOPDIR .
  #endif
***************
*** 564,584 ****
  #ifndef CURDIR
  #define CURDIR .
  #endif
  #ifndef FilesToClean
  #define FilesToClean *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut 
  #endif
- #ifndef STDCTopIncludes
- #define STDCTopIncludes /**/  
- #endif
- #ifndef MakeDependFlags
- #define MakeDependFlags /**/  
- #endif
  
  #ifdef SourceTop
!            SRCDIR = SourceTop/CURDIR/
!             VPATH = SourceTop/CURDIR
             SRCTOP = SourceTop
!        SRCINCLUDE = -I/**/SourceTop/CURDIR
  #endif
              SHELL = BourneShell
  
--- 703,720 ----
  #ifndef CURDIR
  #define CURDIR .
  #endif
+ #ifndef ExtraFilesToClean
+ #define ExtraFilesToClean /**/
+ #endif
  #ifndef FilesToClean
  #define FilesToClean *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut 
  #endif
  
  #ifdef SourceTop
!            SRCDIR = Concat4(SourceTop,/,CURDIR,/)
!             VPATH = Concat3(SourceTop,/,CURDIR)
             SRCTOP = SourceTop
!        SRCINCLUDE = Concat4(-I,$(SRCTOP),/,CURDIR)
  #endif
              SHELL = BourneShell
  
***************
*** 586,593 ****
        CURRENT_DIR = CURDIR
  
                 AR = ArCmd
!   BOOTSTRAPCFLAGS = BootstrapCFlags	/* set if cpp doesn't have uniq sym */
                 CC = CcCmd
  #if HasFortran
                 FC = FortranCmd
        FDEBUGFLAGS = FortranDebugFlags
--- 722,730 ----
        CURRENT_DIR = CURDIR
  
                 AR = ArCmd
!   BOOTSTRAPCFLAGS = BootstrapCFlags	/* set if cpp does not have uniq sym */
                 CC = CcCmd
+                AS = AsCmd
  #if HasFortran
                 FC = FortranCmd
        FDEBUGFLAGS = FortranDebugFlags
***************
*** 598,604 ****
      PREPROCESSCMD = PreProcessCmd $(STD_CPP_DEFINES)	/* prefered; mdep */
            INSTALL = InstallCmd
                 LD = LdCmd
-       LDLOCATIONS = LdLibLocations
               LINT = LintCmd
        LINTLIBFLAG = LintLibFlag
           LINTOPTS = LintOpts
--- 735,740 ----
***************
*** 606,628 ****
               MAKE = MakeCmd
                 MV = MvCmd
                 CP = CpCmd
! #ifdef RanlibCmd
             RANLIB = RanlibCmd
- #else
-            RANLIB = \:
- #endif
    RANLIBINSTFLAGS = RanlibInstFlags
                 RM = RmCmd
       STD_INCLUDES = StandardIncludes
    STD_CPP_DEFINES = StandardCppDefines
        STD_DEFINES = StandardDefines
-     SABER_DEFINES = SaberDefines
   EXTRA_LOAD_FLAGS = ExtraLoadFlags
    EXTRA_LIBRARIES = ExtraLibraries
               TAGS = TagsCmd
-             ETAGS = EtagsCmd
- STDC_TOP_INCLUDES = STDCTopIncludes
- 
  #if ConstructMFLAGS
             MFLAGS = -$(MAKEFLAGS)
  #endif
--- 742,762 ----
               MAKE = MakeCmd
                 MV = MvCmd
                 CP = CpCmd
! #if DoRanlibCmd
             RANLIB = RanlibCmd
    RANLIBINSTFLAGS = RanlibInstFlags
+ #endif
                 RM = RmCmd
+             TROFF = TroffCmd
+          MSMACROS = MsMacros
+               TBL = TblCmd
+               EQN = EqnCmd
       STD_INCLUDES = StandardIncludes
    STD_CPP_DEFINES = StandardCppDefines
        STD_DEFINES = StandardDefines
   EXTRA_LOAD_FLAGS = ExtraLoadFlags
    EXTRA_LIBRARIES = ExtraLibraries
               TAGS = TagsCmd
  #if ConstructMFLAGS
             MFLAGS = -$(MAKEFLAGS)
  #endif
***************
*** 633,644 ****
  #if !HasVoidSignalReturn
     SIGNAL_DEFINES = -DSIGNALRETURNSINT
  #endif
  #if StripInstalledPrograms
!      INSTPGMFLAGS = InstPgmFlags -s	/* install flags for stripping */
  #else
!      INSTPGMFLAGS = InstPgmFlags	/* install flags without stripping */
  #endif
-      INSTSCRFLAGS = InstScrFlags	/* install flags without stripping */
       INSTBINFLAGS = InstBinFlags	/* install flags for programs */
       INSTUIDFLAGS = InstUidFlags	/* install flags for setuid programs */
       INSTLIBFLAGS = InstLibFlags	/* install flags for libraries */
--- 767,818 ----
  #if !HasVoidSignalReturn
     SIGNAL_DEFINES = -DSIGNALRETURNSINT
  #endif
+ /*
+  * The following supports forcing of function prototypes
+  */
+ #if NeedFunctionPrototypes && NeedVarargsPrototypes && NeedConstPrototypes && NeedNestedPrototypes
+ #define _funcprotodef -DFUNCPROTO=15
+ #else
+ #if NeedFunctionPrototypes && NeedVarargsPrototypes && NeedNestedPrototypes
+ #define _funcprotodef -DFUNCPROTO=11
+ #else
+ #if NeedFunctionPrototypes && NeedNestedPrototypes
+ #define _funcprotodef -DFUNCPROTO=9
+ #else
+ #if NeedFunctionPrototypes && NeedVarargsPrototypes && NeedConstPrototypes
+ #define _funcprotodef -DFUNCPROTO=7
+ #else
+ #if NeedFunctionPrototypes && NeedConstPrototypes
+ #define _funcprotodef -DFUNCPROTO=5
+ #else
+ #if NeedFunctionPrototypes && NeedVarargsPrototypes
+ #define _funcprotodef -DFUNCPROTO=3
+ #else
+ #if NeedFunctionPrototypes
+ #define _funcprotodef -DFUNCPROTO
+ #else
+ #define _funcprotodef /**/
+ #endif
+ #endif
+ #endif
+ #endif
+ #endif
+ #endif
+ #endif
+ #if NeedWidePrototypes
+ #define _wideprotodef /**/
+ #else
+ #define _wideprotodef -DNARROWPROTO
+ #endif
+     PROTO_DEFINES = _funcprotodef _wideprotodef 
+ #undef _funcprotodef
+ #undef _wideprotodef
+ 
  #if StripInstalledPrograms
!      INSTPGMFLAGS = InstPgmFlags	/* install flags for stripping */
  #else
!      INSTPGMFLAGS = 
  #endif
       INSTBINFLAGS = InstBinFlags	/* install flags for programs */
       INSTUIDFLAGS = InstUidFlags	/* install flags for setuid programs */
       INSTLIBFLAGS = InstLibFlags	/* install flags for libraries */
***************
*** 647,696 ****
       INSTDATFLAGS = InstDatFlags	/* install flags for data files */
      INSTKMEMFLAGS = InstKmemFlags	/* install flags for /dev/kmem progs */
  
!           DESTDIR = DestDir		/* root of install */
  #ifdef UseInstalled
       TOP_INCLUDES = -I$(INCROOT)	/* def: for alternative /usr/include */
  #else
       TOP_INCLUDES = -I$(TOP)		/* def: for builds within tree */
  #endif
        CDEBUGFLAGS = DefaultCDebugFlags
          CCOPTIONS = DefaultCCOptions	/* to distinguish from param flags */
-       COMPATFLAGS = CompatibilityFlags
  /*
   * STD_INCLUDES contains system-specific includes
   * TOP_INCLUDES specifies how to get to /usr/include or its build substitute
   * EXTRA_INCLUDES contains project-specific includes set in project incfiles
   * INCLUDES contains client-specific includes set in Imakefile
   */
!       ALLINCLUDES = $(INCLUDES) $(STD_INCLUDES) $(TOP_INCLUDES) $(EXTRA_INCLUDES) 
!        ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(PROTO_DEFINES) $(DEFINES) $(COMPATFLAGS)
             CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES)
          LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES)
             LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
!         LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(LDLOCATIONS)
     LDCOMBINEFLAGS = LdCombineFlags
!           MDFLAGS = MakeDependFlags
  
          MACROFILE = MacroFile
!            RM_CMD = $(RM) FilesToClean
  
      IMAKE_DEFINES = /* leave blank, for command line use only */
- #ifdef UseInstalled
-          IRULESRC = $(CONFIGDIR)	/* used in rules file */
-         IMAKE_CMD = $(IMAKE) -DUseInstalled -I$(IRULESRC) $(IMAKE_DEFINES)
- #else
-          IRULESRC = $(CONFIGSRC)
  #ifdef UseImakeInstalled
          IMAKE_CMD = $(IMAKE) -I$(NEWTOP)$(IRULESRC) $(IMAKE_DEFINES)
  #else
          IMAKE_CMD = $(NEWTOP)$(IMAKE) -I$(NEWTOP)$(IRULESRC) $(IMAKE_DEFINES)
  #endif
- #endif
       ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \
  			$(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \
  			$(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES)
  
- 
  /*
   * get project-specific configuration and rules
   */
--- 821,877 ----
       INSTDATFLAGS = InstDatFlags	/* install flags for data files */
      INSTKMEMFLAGS = InstKmemFlags	/* install flags for /dev/kmem progs */
  
! #ifdef ProjectRoot
!       PROJECTROOT = ProjectRoot
! #endif
  #ifdef UseInstalled
+ #if AlternateIncRoot
       TOP_INCLUDES = -I$(INCROOT)	/* def: for alternative /usr/include */
+ #endif
  #else
       TOP_INCLUDES = -I$(TOP)		/* def: for builds within tree */
  #endif
        CDEBUGFLAGS = DefaultCDebugFlags
          CCOPTIONS = DefaultCCOptions	/* to distinguish from param flags */
  /*
   * STD_INCLUDES contains system-specific includes
   * TOP_INCLUDES specifies how to get to /usr/include or its build substitute
   * EXTRA_INCLUDES contains project-specific includes set in project incfiles
   * INCLUDES contains client-specific includes set in Imakefile
+  * LOCAL_LDFLAGS contains client-specific ld flags flags set in Imakefile
   */
!       ALLINCLUDES = $(INCLUDES) $(EXTRA_INCLUDES) $(TOP_INCLUDES) $(STD_INCLUDES)
!        ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(EXTRA_DEFINES) $(PROTO_DEFINES) $(DEFINES)
             CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES)
          LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES)
+ #if AlternateUsrLibDir && !defined(UseInstalled)
+            LDLIBS = -L$(USRLIBDIR) $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
+ #else
             LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
! #endif
! #if AlternateUsrLibDir && defined(UseInstalled)
!         LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(LOCAL_LDFLAGS) -L$(USRLIBDIR)
! #else
!         LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(LOCAL_LDFLAGS)
! #endif
     LDCOMBINEFLAGS = LdCombineFlags
!       DEPENDFLAGS = DependFlags
  
          MACROFILE = MacroFile
!            RM_CMD = $(RM) FilesToClean ExtraFilesToClean
  
      IMAKE_DEFINES = /* leave blank, for command line use only */
  #ifdef UseImakeInstalled
+          IRULESRC = $(CONFIGSRC)	/* used in rules file */
          IMAKE_CMD = $(IMAKE) -I$(NEWTOP)$(IRULESRC) $(IMAKE_DEFINES)
  #else
+          IRULESRC = $(CONFIGSRC)
          IMAKE_CMD = $(NEWTOP)$(IMAKE) -I$(NEWTOP)$(IRULESRC) $(IMAKE_DEFINES)
  #endif
       ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \
  			$(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \
  			$(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES)
  
  /*
   * get project-specific configuration and rules
   */
***************
*** 697,715 ****
  
  #include <Project.tmpl>
  
- 
- 
  #include <Imake.rules>
  
! /**/###########################################################################
! /**/# start of Imakefile
  #include INCLUDE_IMAKEFILE
  
! /**/###########################################################################
! /**/# common rules for all Makefiles - do not edit
  /*
   * These need to be here so that rules in Imakefile occur first;  the blank
!  * all is to make sure that an empty Imakefile doesn't default to make clean.
   */
  emptyrule::
  
--- 878,894 ----
  
  #include <Project.tmpl>
  
  #include <Imake.rules>
  
! XCOMM -------------------------------------------------------------------------
! XCOMM start of Imakefile
  #include INCLUDE_IMAKEFILE
  
! XCOMM -------------------------------------------------------------------------
! XCOMM common rules for all Makefiles - do not edit
  /*
   * These need to be here so that rules in Imakefile occur first;  the blank
!  * all is to make sure that an empty Imakefile does not default to make clean.
   */
  emptyrule::
  
***************
*** 726,742 ****
  
  #if HasSaberC
  saber:
! 	/**/#load $(ALLDEFINES) $(SABER_DEFINES) $(SRCS)
! 	/**/#setopt load_flags $(ALLDEFINES) $(SABER_DEFINES)
  
  osaber:
! 	/**/#load $(ALLDEFINES) $(OBJS)
  #endif
  
  
  #ifdef IHaveSubdirs
! /**/###########################################################################
! /**/# rules for building in SUBDIRS - do not edit
  
  InstallSubdirs($(SUBDIRS))
  InstallManSubdirs($(SUBDIRS))
--- 905,920 ----
  
  #if HasSaberC
  saber:
! 	XCOMM load $(ALLDEFINES) $(SRCS)
  
  osaber:
! 	XCOMM load $(ALLDEFINES) $(OBJS)
  #endif
  
  
  #ifdef IHaveSubdirs
! XCOMM -------------------------------------------------------------------------
! XCOMM rules for building in SUBDIRS - do not edit
  
  InstallSubdirs($(SUBDIRS))
  InstallManSubdirs($(SUBDIRS))
***************
*** 744,754 ****
  TagSubdirs($(SUBDIRS))
  MakefileSubdirs($(SUBDIRS))
  IncludesSubdirs($(SUBDIRS))
- DependSubdirs($(SUBDIRS))
  
  #else
! /**/###########################################################################
! /**/# empty rules for directories that do not have SUBDIRS - do not edit
  
  install::
  	@echo "install in $(CURRENT_DIR) done"
--- 922,931 ----
  TagSubdirs($(SUBDIRS))
  MakefileSubdirs($(SUBDIRS))
  IncludesSubdirs($(SUBDIRS))
  
  #else
! XCOMM -------------------------------------------------------------------------
! XCOMM empty rules for directories that do not have SUBDIRS - do not edit
  
  install::
  	@echo "install in $(CURRENT_DIR) done"
***************
*** 762,766 ****
  
  #endif /* if subdirectory rules are needed */
  
! /**/###########################################################################
! /**/# dependencies generated by makedepend
--- 939,943 ----
  
  #endif /* if subdirectory rules are needed */
  
! XCOMM -------------------------------------------------------------------------
! XCOMM dependencies generated by makedepend


home help back first fref pref prev next nref lref last post