XCOMM
XCOMM $Id: Imakefile,v 1.1.1.2 2001/06/28 23:10:48 bbraun Exp $
XCOMM
XCOMM Imakefile for tcsh 6.10
XCOMM Marc Horowitz, MIT SIPB
XCOMM
/* All config options go in a separate file. */
/* This is a giant conditional block. It should be set up right for
platforms which are in here, but it may need to be changed for new
ones. Please send in your fixes and additions! */
/**** tcsh configuration defines ****/
/* specific platforms */
/* For some stupid reason makedepend on HP requires this */
DEPENDFLAGS = -o.o
CCOPTIONS=-float
/* Maybe conditional on MACH? */
SYSSRCS=mi.termios.c mi.wait.h mi.varargs.h
SYSOBJS=mi.termios.${SUF}
EXTF=ma.setp.c vms.termcap.c
/* Maybe conditional on MACH? */
SYSSRCS=ma.setp.c
SYSOBJS=ma.setp.${SUF}
EXTF=mi.termios.c mi.wait.h mi.varargs.h vms.termcap.c
/* generic os's */
/* why this as a default? Why not? */
/**** libraries ****/
defined(SQNTArchitecture) || defined(SequentArchitecture) || \
defined(MacIIArchitecture) || defined(UseLibTermcap)
LIBTERMCAP = -ltermcap
LIBTERMCAP =
LIBSQNT=-lsocket -linet -lnsl -lseq
/* This may not be good enough - I don't have access to enough systems
to really test it. */
LIBCURSES = -lcurses
LIBCURSES =
LIBNET = -lnet
LIBNET =
LIBSOCKET = -lsocket
LIBSOCKET =
LIBBSD = -lbsd
LIBBSD =
(OSMajorVersion == 3) && (OSMinorVersion == 3)) || \
defined(UseLibC_S)
LIBC_S = -lc_s
LIBC_S =
LIBSUN = -lsun
LIBSUN =
LIBCPOSIX = -lcposix
LIBCPOSIX =
LIBINET = -linet
LIBINET =
LIBDIRECT = -ldir
LIBDIRECT =
LIBX = -lx
LIBX =
LIBINTL = -lintl
LIBINTL =
LIBCRYPT = -lcrypt
LIBCRYPT =
LIBPOSIX = -lposix
LIBPOSIX =
LIBDIRECTENT = -ldirent
LIBDIRECTENT =
/* The order here is significant. Although nothing uses all of these,
some platforms which use more than one do care about the order. */
SYSLIBS = $(LIBPOSIX) $(LIBDIRECTENT) $(LIBTERMCAP) $(LIBCURSES) \
$(LIBNET) $(LIBINTL) $(LIBSOCKET) $(LIBSUN) $(LIBBSD) $(LIBCPOSIX) \
$(LIBINET) $(LIBDIRECT) $(LIBX) $(LIBC_S) $(LIBSQNT) $(LIBCRYPT)
/* Past here, nothing should need to be changed to compile on a different
platform, unless you have a really weird architecture. */
CC = MyCC
CC = gcc
CC = gcc -finline-functions -fstrength-reduce
CC = gcc -fcombine-regs -finline-functions -fstrength-reduce
CC = cc
HESLIB = -L/usr/athena/lib -lhesiod
/* it seems to me that the -I shouldn't be necessary, but there seems
to be a bug in the Imake stuff, so here it is. */
HESDEF = -DHESIOD -I/usr/athena/include
HESLIB =
HESDEF =
AFSDIR = /usr/afsws
/* Auxilliary libs needed for AFS */
/* Both HPUX and Solaris need the BSD libraries. We need -lc before
* the bsd library to avoid using any more of it than is necessary.
*/
/* This is probably a kludge, but so is imake. */
AFSLIB = -L$(AFSDIR)/lib -L$(AFSDIR)/lib/afs -lkauth -lprot -lubik\
-lauth -lrxkad -lsys -ldes -lrx -llwp -lcom_err\
$(AFSDIR)/lib/afs/util.a AFS33LIB AFSAUXLIB
AFSDEF = -DAFS -I$(AFSDIR)/include
AFSLIB =
AFSDEF =
/* This is encore specific, but I don't know what encore's and it shouldn't hurt to have it here, so here it is */
PARALLEL=12
TCSHTOP = TcshTop
MANSUFFIX = ManSuffix
PATH_TCSHELL = TcshPath
TCSHPATH = -D_PATH_TCSHELL='"$(PATH_TCSHELL)"'
TCSHPATH =
TCSH_BINDIR = DestBin
TCSH_BINDIR = $(TCSHTOP)/bin
TCSH_MANDIR = DestMan
TCSH_MANDIR = $(TCSHTOP)/man/man$(MANSUFFIX)
LOCALLIBS =
CDEBUGFLAGS = CDebugFlags
CDEBUGFLAGS = -O2
CDEBUGFLAGS = -O
HOSTTYPE=HostType
HTDEF = -DHOSTTYPE='"$(HOSTTYPE)"'
HTDEF =
DEFINES = $(TCSHPATH) $(HESDEF) $(AFSDEF) $(HTDEF) MyDefines MyCflags MyStdc
INCLUDES = -I. MyIncludes
LDLIBS = MyLibs
SUF = o
VERSION = 6.10
SHSRCS= sh.c sh.dir.c sh.dol.c sh.err.c sh.exec.c sh.char.c \
sh.exp.c sh.file.c sh.func.c sh.glob.c sh.hist.c sh.init.c \
sh.lex.c sh.misc.c sh.parse.c sh.print.c sh.proc.c sh.sem.c \
sh.set.c sh.time.c sh.char.h sh.dir.h sh.proc.h sh.h \
sh.decls.h glob.c glob.h ${SYSSRCS}
SHOBJS= sh.${SUF} sh.dir.${SUF} sh.dol.${SUF} sh.err.${SUF} sh.exec.${SUF} \
sh.char.${SUF} sh.exp.${SUF} sh.func.${SUF} sh.glob.${SUF} \
sh.hist.${SUF} sh.init.${SUF} sh.lex.${SUF} sh.misc.${SUF} \
sh.parse.${SUF} sh.print.${SUF} sh.proc.${SUF} sh.sem.${SUF} \
sh.set.${SUF} sh.time.${SUF} glob.${SUF} ${SYSOBJS}
TWSRCS= tw.decls.h tw.h tw.help.c tw.init.c tw.parse.c tw.spell.c \
tw.comp.c tw.color.c
TWOBJS= tw.help.${SUF} tw.init.${SUF} tw.parse.${SUF} tw.spell.${SUF} \
tw.comp.${SUF} tw.color.${SUF}
EDSRCS= ed.chared.c ed.decls.h ed.defns.c ed.h ed.init.c ed.inputl.c \
ed.refresh.c ed.screen.c ed.xmap.c ed.term.c ed.term.h
EDOBJS= ed.chared.${SUF} ed.refresh.${SUF} ed.screen.${SUF} ed.init.${SUF} \
ed.inputl.${SUF} ed.defns.${SUF} ed.xmap.${SUF} ed.term.${SUF}
TCSRCS= tc.alloc.c tc.bind.c tc.const.c tc.decls.h tc.disc.c \
tc.func.c tc.os.c tc.os.h tc.printf.c tc.prompt.c \
tc.sched.c tc.sig.c tc.sig.h tc.str.c sh.types.h tc.vers.c tc.wait.h \
tc.who.c tc.h
TCOBJS= tc.alloc.${SUF} tc.bind.${SUF} tc.const.${SUF} tc.defs.${SUF} \
tc.disc.${SUF} tc.func.${SUF} tc.os.${SUF} tc.printf.${SUF} \
tc.prompt.${SUF} tc.sched.${SUF} tc.sig.${SUF} tc.str.${SUF} \
tc.vers.${SUF} tc.who.${SUF}
MISCF = Makefile.std Fixes MAKEDIFFS MAKESHAR NewThings README FAQ \
WishList config_f.h eight-bit.me glob.3 patchlevel.h \
pathnames.h tcsh.man Ported src.desc Imakefile imake.config \
README.imake complete.tcsh vmsreadme.txt Makefile.vms termcap.vms \
snames.h host.defs gethost.c tcsh.man2html Makefile.in configure.in \
Makefile.win32
CONFSRCS=config/[a-z]*
SRCS = $(SHSRCS) $(TWSRCS) $(EDSRCS) $(TCSRCS)
OBJS = $(SHOBJS) $(TWOBJS) $(EDOBJS) $(TCOBJS)
ALLSRCS= $(MISCF) $(SRCS) $(EXTF)
AllTarget(tcsh)
ed.defns.h: config.h ed.defns.c
@rm -f $@
@echo '/* Do not edit this file, make creates it. */' > $@
@echo ' @echo ' egrep '[FV]_' ed.defns.c | egrep '^ @echo '
sh.err.h: config.h sh.err.c
@rm -f $@
@echo '/* Do not edit this file, make creates it. */' > $@
@echo ' @echo ' egrep 'ERR_' sh.err.c | egrep '^ @echo '
tc.const.h: config.h tc.const.c
@rm -f $@
@echo '/* Do not edit this file, make creates it. */' > $@
@echo ' @echo ' ${CC} -E $(INCLUDES) ${DEFINES} -D_h_tc_const tc.const.c | \
grep 'Char STR' | \
sed -e 's/Char \([a-zA-Z0-9_]*\)\[\].*/extern Char \1[];/' | \
sort >> $@
@echo '
config.h: config_f.h
cp config/ConfigH config.h
$(OBJS): sh.err.h tc.const.h ed.defns.h
tar.Z:
rm -f tcsh-${VERSION}.tar.Z
rm -rf tcsh-${VERSION}
mkdir tcsh-${VERSION} tcsh-${VERSION}/config
cp ${ALLSRCS} tcsh-${VERSION}
cp ${CONFSRCS} tcsh-${VERSION}/config
tar cf - nls/Makefile nls/?*/set?* | (cd tcsh-${VERSION}; tar xpf -)
tar cvf - tcsh-${VERSION} | compress > tcsh-${VERSION}.tar.Z
rm -rf tcsh-${VERSION}
tar.gz:
rm -f tcsh-${VERSION}.tar.gz
rm -rf tcsh-${VERSION}
mkdir tcsh-${VERSION} tcsh-${VERSION}/config
cp ${ALLSRCS} tcsh-${VERSION}
cp ${CONFSRCS} tcsh-${VERSION}/config
tar cf - nls/Makefile nls/?*/set?* | (cd tcsh-${VERSION}; tar xpf -)
tar cvf - tcsh-${VERSION} | gzip > tcsh-${VERSION}.tar.gz
rm -rf tcsh-${VERSION}
shar:
rm -f tcsh-*.shar
rm -rf tcsh-${VERSION}
mkdir tcsh-${VERSION} tcsh-${VERSION}/config
cp ${ALLSRCS} tcsh-${VERSION}
cp ${CONFSRCS} tcsh-${VERSION}/config
tar cf - nls/Makefile nls/?*/set?* | (cd tcsh-${VERSION}; tar xpf -)
MAKESHAR -v -n tcsh-${VERSION} tcsh-${VERSION} \
tcsh-${VERSION}/?* tcsh-${VERSION}/config/?* \
tcsh-${VERSION}/?*/set?*
rm -rf tcsh-${VERSION}
catalogs:
@(cd nls; make catalogs)
world:
$(MAKE) clean ; $(MAKE) depend ; $(MAKE) tcsh ; $(MAKE) install
clean::
rm -f ed.defns.h sh.err.h tc.const.h config.h tc.defs.*
rm -f tcsh.*.m tcsh.*.cat
depend:: config.h ed.defns.h sh.err.h tc.const.h $(SRCS) tc.defs.c
tc.defs.${SUF}: tc.defs.c sh.h
tc.defs.c: gethost host.defs
@rm -f $@
@echo "/* Do not edit this file, make creates it */" > $@
./gethost host.defs >> $@
ALIB=$(HESLIB) $(AFSLIB) $(SYSLIBS)
AINC=ed.defns.h sh.err.h tc.const.h sh.h
NormalProgramTarget(tcsh, $(OBJS), $(AINC), $(LOCALLIBS), $(ALIB))
NormalProgramTarget(gethost, gethost.${SUF}, $(AINC), $(LOCALLIBS), $(ALIB))
InstallProgram(tcsh,$(TCSH_BINDIR))
InstallManPage(tcsh,$(TCSH_MANDIR))
DependTarget()