#;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
#;;;
#;;; LUSH Lisp Universal Shell
#;;;   Copyright (C) 2002 Leon Bottou, Yann Le Cun, AT&T Corp, NECI.
#;;; Includes parts of TL3:
#;;;   Copyright (C) 1987-1999 Leon Bottou and Neuristique.
#;;; Includes selected parts of SN3.2:
#;;;   Copyright (C) 1991-2001 AT&T Corp.
#;;;
#;;; This program is free software; you can redistribute it and/or modify
#;;; it under the terms of the GNU General Public License as published by
#;;; the Free Software Foundation; either version 2 of the License, or
#;;; (at your option) any later version.
#;;;
#;;; This program is distributed in the hope that it will be useful,
#;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
#;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#;;; GNU General Public License for more details.
#;;;
#;;; You should have received a copy of the GNU General Public License
#;;; along with this program; if not, write to the Free Software
#;;; Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA
#;;;
#;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

#;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
#;;; $Id: Makefile.in,v 1.25 2006/03/29 15:15:21 leonb Exp $
#;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;


SHELL = /bin/sh

srcdir = .
top_srcdir = ..
top_builddir = ..

OPTS = -DNO_DEBUG   -fno-strict-aliasing
DEFS = -DHAVE_CONFIG_H
LDFLAGS = 
LIBS = -liconv -lreadline -lcurses -lutil -lm  -pthread -lintl -L/usr/local/lib
host = amd64-portbld-freebsd8.0
CPP = cpp
CPPFLAGS =  -I/usr/local/include
CC = cc
CC = cc
GCC = yes
CFLAGS =  -pipe -fno-strict-aliasing
CXX = c++
CXXFLAGS = -O2 -pipe -fno-strict-aliasing
F77 = 
FFLAGS = 
LDCC = c++
LDFLAGS = 
PTHREAD_FLAGS = -D_THREAD_SAFE 
PTHREAD_LIBS = 
AR = /usr/bin/ar
MV = /bin/mv
CP = /bin/cp
RM = /bin/rm
LN_S = ln -s
TOUCH = /usr/bin/touch
RANLIB = ranlib
INSTALL = /usr/bin/install -c -o root -g wheel
X_LIBS =  -L/usr/local/lib -lXft -lXrender -lfontconfig -lfreetype -lX11 -lSM -lICE
X_CFLAGS =  -I/usr/local/include -D_THREAD_SAFE -I/usr/local/include/freetype2
CC_PIC_FLAG = -fPIC
CC_EXP_FLAG = 
MAKESO = c++ -shared -o
EXEEXT = 
OBJEXT = o
SOEXT = so

#;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

LUSH=lush

INCS=-I${top_srcdir}/include

OBJS1=allocate.o at.o binary.o calls.o arith.o check_func.o \
      classify.o date.o dump.o dz.o eval.o fileio.o \
      fltlib.o function.o event.o graphics.o htable.o \
      idx1.o idx2.o idx3.o idx4.o index.o io.o \
      dh.o lisp_c.o main.o module.o nan.o oostruct.o \
      ps_driver.o comdraw_driver.o lisp_driver.o \
      storage.o string.o symbol.o toplevel.o user.o

OBJS3=unix.o
OBJS2=x11_driver.o
#OBJS3=win32.o win_driver.o
#OBJS4=dldbfd.o

LUSHFLAGS = ${DEFS} ${OPTS} ${INCS} ${PTHREAD_FLAGS} ${X_CFLAGS}
LUSHLIBS = ${X_LIBS} ${LIBS} ${PTHREAD_LIBS}
LUSHOBJS=${OBJS1} ${OBJS2} ${OBJS3} ${OBJS4}
LDCCFLAGS= ${LDFLAGS} ${LUSHFLAGS} ${CC_EXP_FLAG}

all: ${LUSH}

lush: ${LUSHOBJS}
	${LDCC} ${LDCCFLAGS} -o $@ ${LUSHOBJS} ${LUSHLIBS}

depend: FORCE
	-@test x${GCC} = xyes && ${MAKE} depend-gcc

depend-gcc: 
	@echo "Computing dependencies." 
	@echo '### DEPENDENCIES' > Makefile.dep
	@${CC} -MM -DMAKEDEPEND ${CPPFLAGS} ${CFLAGS} ${INCS} ${DEFS} \
	   `echo ${LUSHOBJS} | sed -e 's:\.o:.c:g'` >> Makefile.dep
	@echo "Updating Makefile." ;\
	 ( sed -e '/^### DEPENDENCIES$$/,$$d' Makefile;\
	   cat  Makefile.dep ) > Makefile.new ;\
	 ${MV} Makefile.new Makefile
	@if test -w Makefile.in ; then echo "Updating Makefile.in." ;\
	 ( sed -e '/^### DEPENDENCIES$$/,$$d' Makefile.in;\
	   sed -e 's:/usr/include/[^ ]*::g' Makefile.dep ) > Makefile.new ;\
	 ${MV} Makefile.new Makefile.in ; fi ; true

clean: FORCE
	-${RM} 2>/dev/null Makefile.dep 
	-${RM} 2>/dev/null ${LUSH}
	-${RM} 2>/dev/null ${LUSHOBJS}

distclean: clean FORCE
	-${RM} 2>/dev/null Makefile

FORCE:

.PHONY: FORCE

.SUFFIXES: .c

.c.o:
	${CC} ${CPPFLAGS} ${CFLAGS} ${LUSHFLAGS} -c $<

${LUSHOBJS}: Makefile


### DEPENDENCIES
allocate.o: allocate.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
at.o: at.c ../include/header.h ../include/define.h ../include/lushconf.h \
  ../include/fltlib.h ../include/check_func.h
binary.o: binary.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
calls.o: calls.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
arith.o: arith.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
check_func.o: check_func.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/idxmac.h ../include/idxops.h ../include/dh.h
classify.o: classify.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
date.o: date.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
dump.o: dump.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
dz.o: dz.c ../include/header.h ../include/define.h ../include/lushconf.h \
  ../include/fltlib.h ../include/check_func.h
eval.o: eval.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
fileio.o: fileio.c ../include/lushconf.h ../include/header.h \
  ../include/define.h ../include/lushconf.h ../include/fltlib.h \
  ../include/check_func.h
fltlib.o: fltlib.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
function.o: function.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
event.o: event.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/graphics.h
graphics.o: graphics.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/graphics.h
htable.o: htable.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
idx1.o: idx1.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/idxmac.h ../include/idxops.h ../include/idx.h
idx2.o: idx2.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/idxmac.h ../include/idxops.h ../include/idx.h
idx3.o: idx3.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/idxmac.h ../include/idxops.h ../include/idx.h
idx4.o: idx4.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/idxmac.h ../include/idxops.h ../include/idx.h
index.o: index.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
io.o: io.c ../include/header.h ../include/define.h ../include/lushconf.h \
  ../include/fltlib.h ../include/check_func.h
dh.o: dh.c ../include/header.h ../include/define.h ../include/lushconf.h \
  ../include/fltlib.h ../include/check_func.h ../include/dh.h \
  ../include/idxmac.h ../include/idxops.h
lisp_c.o: lisp_c.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/dh.h ../include/idxmac.h ../include/idxops.h
main.o: main.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
module.o: module.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/dh.h ../include/idxmac.h ../include/idxops.h \
  ../include/dldbfd.h
nan.o: nan.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
oostruct.o: oostruct.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/dh.h ../include/idxmac.h ../include/idxops.h
ps_driver.o: ps_driver.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/graphics.h
comdraw_driver.o: comdraw_driver.c ../include/header.h \
  ../include/define.h ../include/lushconf.h ../include/fltlib.h \
  ../include/check_func.h ../include/graphics.h
lisp_driver.o: lisp_driver.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h \
  ../include/graphics.h
storage.o: storage.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
string.o: string.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
symbol.o: symbol.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
toplevel.o: toplevel.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
user.o: user.c ../include/header.h ../include/define.h \
  ../include/lushconf.h ../include/fltlib.h ../include/check_func.h
x11_driver.o: x11_driver.c ../include/lushconf.h ../include/header.h \
  ../include/define.h ../include/lushconf.h ../include/fltlib.h \
  ../include/check_func.h ../include/graphics.h
unix.o: unix.c ../include/lushconf.h ../include/header.h \
  ../include/define.h ../include/lushconf.h ../include/fltlib.h \
  ../include/check_func.h ../include/lushmake.h
dldbfd.o: dldbfd.c ../include/lushconf.h ../include/dldbfd.h
