#
# This file is part of the OLH system
# Imakefile for top level directory.
#
# Copyright (C) 1990 by the Massachusetts Institute of Technology.
# For copying and distribution information, see the file "mit-copyright.h."
#
#       $Source: /afs/athena.mit.edu/astaff/project/olhdev/src/RCS/Imakefile,v $
#       $Id: Imakefile,v 1.13 92/06/03 08:25:51 lwvanels Exp $
#       $Author: lwvanels $
#


#define IHaveSubdirs
#if HaveMotif
SUBDIRS= libmenu logger ascii motif
#else
SUBDIRS= libmenu logger ascii
#endif

all::

world::
	make ${MFLAGS} Makefile
	@make ${MFLAGS} -f Makefile world2

world2:
	make ${MFLAGS} Makefiles
	make ${MFLAGS} depend
	make ${MFLAGS} all
mytags::
	make ${MFLAGS} olh_ascii_tags olh_motif_tags

olh_motif_tags::
	$(TAGS) ../src/libmenu//**/*.[ch] ../src/motif//**/*.[ch]
	$(MV) TAGS ../src/TAGS.motif

olh_ascii_tags::
	$(TAGS) ../src/libmenu//**/*.[ch] ../src/ascii//**/*.[ch]
	$(MV) TAGS ../src/TAGS.ascii

#ifdef InstallAltLoc
#if HaveMotif
InstallScript(olh,$(DESTDIR)/usr/athena/bin)
#else
install::
	$(RM) $(DESTDIR)/usr/athena/bin/olh
	$(LN) $(DESTDIR)/usr/athena/bin/olh_ascii $(DESTDIR)/usr/athena/bin/olh
#endif
InstallNonExec(help.1,$(DESTDIR)/usr/athena/man/man1)
InstallNonExec(olh.1,$(DESTDIR)/usr/athena/man/man1)
#else
#if HaveMotif
InstallScript(olh,$(DESTDIR)/usr/athena)
#else
install::
	$(RM) $(DESTDIR)/usr/athena/bin/olh
	$(LN) $(DESTDIR)/usr/athena/olh_ascii $(DESTDIR)/usr/athena/olh
#endif
InstallNonExec(help.1,$(DESTDIR)/usr/man/man1)
InstallNonExec(olh.1,$(DESTDIR)/usr/man/man1)
#endif
