# Makefile generated by imake - do not edit!
# $XConsortium: imake.c,v 1.74 92/12/02 21:32:49 rws Exp $

SHELL=/bin/sh
MAKESHELL=/bin/sh

TOP = ../.
CWD = ./src
CONFIGSRC = /source/config
DESTDIR=

IRULESRC = $(CONFIGSRC)

IMAKE= imake
IFLAGS= -I$(IRULESRC) -DTOPDIR=/source
XIFLAGS= -I$(ATHXLIBDIR)/X11/config -DUseInstalled

ICONFIGFILE = ${IRULESRC}/Imake.tmpl ${IRULESRC}/Imake.rules \
	${IRULESRC}/site.def Imakefile
MKDIRHIER= sh $(IRULESRC)/mkdirhier.sh

ATHVERS = ${IRULESRC}/update.conf

ATHBASEDIR=/usr/athena

ATHLIBDIR=$(ATHBASEDIR)/lib
ATHBINDIR=$(ATHBASEDIR)/bin
ATHINCDIR=$(ATHBASEDIR)/include
ATHETCDIR=$(ATHBASEDIR)/etc
ATHCONFDIR=/etc/athena
ATHMANDIR=$(ATHBASEDIR)/man
ATHRBINDIR=/bin/athena
ATHRETCDIR=/etc/athena

ATHNEWDIR=$(ATHBINDIR)

ATHXAPPDIR=/usr/athena/lib/X11/app-defaults
ATHXBITDIR=/usr/athena/lib/X11/bitmaps
ATHXINCDIR=/usr/athena/include
ATHXLIBDIR=/usr/athena/lib

AFSDIR=/mit/afsuser/@sys

LINTCFLAG=-C
LINTFLAGS=$(DEFINES) -I/usr/athena/include

INSTALL=install -c
RANLIB=ranlib
CC=cc
LD=cc
AS=as
RM=rm -f
CDEBUG=-O

CFLAGS=$(CDEBUG)  $(DEFINES) -I/usr/athena/include
LDFLAGS= $(LDDEFS)
LDPATH=-L$(ATHLIBDIR)
LDLIBS=

all::
install:: install_dirs
install_dirs::
install::
install.man::

clean::
depend::

FRC::

###########################################################################
# Project inclusion
###########################################################################

###########################################################################
# start of Imakefile
###########################################################################

# Makefile for NCSA Mosaic for the X Window System.
# Copyright 1993 National Center for Supercomputing Applications

# ----------------------------------------------------------------------------
# For normal machines with normal compilers:
# CC = cc
# For Sun's and other non-at-least-pseudo-ANSI-C platforms:
CC = gcc -DMOTIF1_2
# For stupid Ultrix:
# CC = cc -DSTUPID_ULTRIX
# For HP-UX 8.00:
# CC = cc -Aa -D_HPUX_SOURCE -I/usr/include/Motif1.1 -I/usr/include/X11R4
# For NeXT:
# CC = cc -DNEXT -I/usr/include/X11
# For Dell SVR4:
# CC = cc -DSVR4
# ----------------------------------------------------------------------------

# ----------------------------------------------------------------------------

XCFLAGS = -DNOSTDHDRS

# ----------------------------------------------------------------------------

# ----------------------------------------------------------------------------
# For SGI's only:
# X_LIBS = -lXm_s -lXmu -lXt_s -lX11_s
# For HP-UX 8.00:
# X_LIBS = -L/usr/lib/Motif1.1 -lXm -L/usr/lib/X11R4 -lXmu -lXt -lX11
# For NeXT:
# X_LIBS = -L/usr/lib/X11 -lXm -lXmu -lXt -lX11
# For nearly everyone else:
# X_LIBS = -lXm -lXmu -lXt -lX11
# For Sun's (at least running X/Motif as installed on our machines):
# X_LIBS = /usr/lib/libXm.a /usr/lib/libXmu.a /usr/lib/libXt.a /usr/lib/libXext.a /usr/lib/libX11.a -lm
# For Dell SVR4:
# X_LIBS = -L/usr/X5/lib -lXm -lXmu -lXt -lXext -lX11
X_LIBS = -L/mit/motif/`machtype`lib -lXm -lXmu -lXt -lXext -lX11
# ----------------------------------------------------------------------------

# ----------------------------------------------------------------------------
# For SGI's only:
# SYS_LIBS = -lPW -lsun -lmalloc
# For most other Motif platforms:
# SYS_LIBS = -lPW
# For SCO ODT:
# SYS_LIBS = -lPW -lsocket -lmalloc
# For Sun's and Ultrix:
# SYS_LIBS =
# For Sun's with no DNS:
# SYS_LIBS = -lresolv
# For Dell SVR4:
# SYS_LIBS = -lnsl -lsocket -lc -lucb

# ----------------------------------------------------------------------------

# ----------------------------------------------------------------------------
# If you want to compile DTM support in, use these lines...
# DTMSRCS = net.c netdata.c list.c mesg.c
# DTMOBJS = net.o netdata.o list.o mesg.o
# DTM_FLAGS = -DHAVE_DTM -DHAVE_DMF -I..
# DTM_LIBS = ../libdtm/libdtm.a ../libdmf/libdmf.a
# Else use these lines...
# DTMSRCS =
# DTMOBJS =
# DTM_FLAGS =
# DTM_LIBS =
# See the toplevel Mosaic README for more information on DTM.
# ----------------------------------------------------------------------------

# ----------------------------------------------------------------------------
# If you want Mosaic to come up with monochrome colors by default,
# use this line:
# COLOR_FLAGS = -DMONO_DEFAULT
# Else use this line:
COLOR_FLAGS =
# ----------------------------------------------------------------------------

# You shouldn't need to edit below here.
# ^ So sue me.

all: xmosaic

LIBWWW_DIR = ../libwww
LIBWWW_INC = ../libwww
HTMLW_LIBDIR = ../libhtmlw

XINCLUDES = -I/mit/motif/include -I/usr/athena/include

INCLUDES = -I.. -I$(LIBWWW_INC) $(XINCLUDES)
OPTS = -g -O
# Do NOT compile with -DINSTRUMENT, please please please.
# OPTS = -g -DINSTRUMENT
PROFILE_FLAGS =
CFLAGS = $(OPTS) $(INCLUDES) $(DTM_FLAGS) $(COLOR_FLAGS) $(XCFLAGS)

PROGRAM_LIBS = $(HTMLW_LIBDIR)/libhtmlw.a $(LIBWWW_DIR)/libwww.a
LIBS = $(PROGRAM_LIBS) $(X_LIBS) $(DTM_LIBS) $(SYS_LIBS)

XOBJS = strstr.o

CFILES = main.c gui.c gui2.c mo-www.c mo-dtm.c hotlist.c whine.c history.c\
  annotate.c pan.c grpan.c grpan-www.c audan.c mo-dmf.c globalhist.c img.c\
  instrument.c startup.c
OBJS = main.o gui.o gui2.o mo-www.o mo-dtm.o hotlist.o whine.o history.o\
  annotate.o pan.o grpan.o grpan-www.o audan.o mo-dmf.o globalhist.o img.o\
  instrument.o startup.o $(XOBJS)

AUXCFILES = Xmx.c Xmx2.c picread.c gifread.c medcut.c
AUXOBJS = Xmx.o Xmx2.o picread.o gifread.o medcut.o

Xmx.o: Xmx.c
	$(CC) -c $(CFLAGS) $(AUX_CFLAGS) Xmx.c
Xmx2.o: Xmx2.c
	$(CC) -c $(CFLAGS) $(AUX_CFLAGS) Xmx2.c
picread.o: picread.c
	$(CC) -c $(CFLAGS) $(AUX_CFLAGS) picread.c
gifread.o: gifread.c
	$(CC) -c $(CFLAGS) $(AUX_CFLAGS) gifread.c
medcut.o: medcut.c
	$(CC) -c $(CFLAGS) $(AUX_CFLAGS) medcut.c

xmosaic: $(OBJS) $(AUXOBJS) $(DTMOBJS) $(PROGRAM_LIBS)
	$(CC) $(PROFILE_FLAGS) -o xmosaic $(OBJS) $(AUXOBJS) $(DTMOBJS) $(LIBS)

HFILES = mosaic.h
$(OBJS): $(HFILES)
gui.o: xresources.h

wipe:
	-rm xmosaic $(OBJS)
clean:
	-rm xmosaic *.o
tags:
	etags -t *.[ch]

Makefile:: $(ICONFIGFILE)
	-@if [ -f Makefile ]; then \
        	echo "  $(RM) Makefile.bak; mv Makefile Makefile.bak"; \
		$(RM) Makefile.bak; mv Makefile Makefile.bak; \
        else exit 0; fi
	$(IMAKE) $(IFLAGS) $(IPROJ) -DNEWTOP=$(TOP) -DNEWCWD=$(CWD)

XMakefile::
	-@if [ -f Makefile ]; then \
        	echo "  $(RM) Makefile.bak; mv Makefile Makefile.bak"; \
		$(RM) Makefile.bak; mv Makefile Makefile.bak; \
        else exit 0; fi
	$(IMAKE) $(XIFLAGS)

clean::
	rm -f *~ *.o *.a core a.out

Makefiles::

###########################################################################
# dependencies generated by makedepend

