#define ProjectKRB 5
+#ifndef TouchCmd
+#define TouchCmd touch
+#endif
#ifndef CompileEtCmd
#define CompileEtCmd $(ETSRC)/compile_et
#endif
#ifndef PosyCmd
#define PosyCmd $(ISODE)/@sys/bin/posy
#endif
+#ifndef ArAddCmd
+#define ArAddCmd ar cruv
+#endif
#ifndef PepyPosyRules
#define PepyPosyRules() @@\
$(PEPY) $(PYFLAGS) $<
#endif /* PepyPosyRules */
+#ifndef ErrorTableObjectRule
+
+#define ErrorTableObjectRule() @@\
+.SUFFIXES: .et @@\
+ @@\
+.et.h: @@\
+ $(COMPILE_ET) $*.et @@\
+ @@\
+.et.c: @@\
+ $(COMPILE_ET) $*.et
+
+#endif
+
+#ifndef CmdTableObjectRule
+
+#define CmdTableObjectRule() @@\
+.SUFFIXES: .ct @@\
+ @@\
+.ct.c: @@\
+ $(MK_CMDS) $*.ct
+
+#endif
+
+/*
+ * AdditiveLibraryTarget - generate rules to create a library from
+ * several directories
+ */
+#ifndef AdditiveLibraryTarget
+#define AdditiveLibraryTarget(libname,objlist) @@\
+AllTarget(lib/**/libname.a) @@\
+AllTarget(foo/**/libname) @@\
+ @@\
+foo/**/libname: objlist @@\
+ $(ARADD) lib/**/libname.a objlist @@\
+ $(TOUCH) foo/**/libname @@\
+ $(RANLIB) $@ @@\
+lib/**/libname.a: objlist @@\
+ $(ARADD) $@ objlist @@\
+ $(RANLIB) $@
+#endif /* AdditiveLibraryTarget */
+
+/*
+ * OtherdirLibraryTarget - generate rules to create a library in another
+ * directory from object files here
+ */
+#ifndef OtherdirLibraryTarget
+#define OtherdirLibraryTarget(libdir,libname,objlist) @@\
+AllTarget(libdir/lib/**/libname.a) @@\
+AllTarget(foo/**/libname) @@\
+ @@\
+foo/**/libname: objlist @@\
+ $(ARADD) libdir/lib/**/libname.a objlist @@\
+ $(TOUCH) foo/**/libname @@\
+libdir/lib/**/libname.a: @@\
+ $(ARADD) $@ objlist @@\
+ $(TOUCH) foo/**/libname
+/* The $(RANLIB) is done at the end by the directory itself */
+#endif /* OtherdirLibraryTarget */
+
/*
* Default Definitions.
*/
+ ARADD = ArAddCmd
TOP_INCLUDES = -I$(TOP)/include $(STDC_TOP_INCLUDES)
CONFIGSRC = $(TOP)/config
IMAKESRC = $(CONFIGSRC)
PYFLAGS = PepyFlags
PEPY = PepyCmd
POSY = PosyCmd
+ TOUCH = TouchCmd
ETSRC = $(TOP)/lib/comerr/compile_et
SSCMDSRC = $(TOP)/lib/ss/mk_cmds
- DEPKLIB = $(TOP)/lib/krb/libkrb.a \
- $(TOP)/lib/ccache/libcred.a \
- $(TOP)/lib/ccache/file/libfcc.a \
- $(TOP)/lib/rcache/librc.a \
- $(TOP)/lib/keytab/libkt.a \
- $(TOP)/lib/keytab/file/libktfile.a \
+ DEPKLIB = $(TOP)/lib/libkrb5.a \
$(TOP)/lib/os-4.3/libos.a \
- $(TOP)/error_tables/libkrberrs.a \
- $(TOP)/lib/cryptoconf.o \
$(TOP)/lib/des/libdes.a \
$(TOP)/lib/crc-32/libcrc32.a \
- $(TOP)/asn.1/libasn1.a \
- $(TOP)/lib/free/libkfree.a
+ $(TOP)/asn.1/libasn1.a
- KLIB = $(DEPKLIB) $(ISODE)/@sys/lib/libisode.a -ldes -lcom_err $(TOP)/lib/libsyslog.a
+ KLIB = $(DEPKLIB) $(ISODE)/@sys/lib/libisode.a -ldes -lcom_err
KDBLIB = $(TOP)/lib/kdb/libkdb.a
#ifdef UseInstalled
MK_CMDS = MkCmdsCmd
#endif
-#ifndef ErrorTableObjectRule
-
-#define ErrorTableObjectRule() @@\
-.SUFFIXES: .et @@\
- @@\
-.et.h: @@\
- $(COMPILE_ET) $*.et @@\
- @@\
-.et.c: @@\
- $(COMPILE_ET) $*.et
-
-#endif
-
-#ifndef CmdTableObjectRule
-
-#define CmdTableObjectRule() @@\
-.SUFFIXES: .ct @@\
- @@\
-.ct.c: @@\
- $(MK_CMDS) $*.ct
-
-#endif
-