# Generated automatically from Makefile.in by configure.
# Makefile for xwindiff
# Copyright (C) 2001 David Drysdale
#
# This file is part of XWINDIFF.
#
# XWINDIFF 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, or (at your option)
# any later version.
#
# XWINDIFF 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 XWINDIFF; see the file COPYING.  If not, write to
# the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.

#### Start of system configuration section. ####

srcdir = .

CC = gcc
INSTALL = /usr/bin/ginstall -c
INSTALL_PROGRAM = ${INSTALL}
INSTALL_DATA = ${INSTALL} -m 644

CPPFLAGS =
DEFS = -DHAVE_CONFIG_H
CFLAGS = -g -O2  -I/usr/X11R6/include
LDFLAGS =
LIBS =         -L/usr/X11R6/lib -lXawPlus -lXmu -lXpm -lX11
LIBOBJS =
#LIBS =          -L/usr/X11R6/lib -lXaw -lXmu -lXpm -lX11
#LIBOBJS =       /usr/src/XawPlus/libXawPlus.a

# Some System V machines do not come with libPW.
# If this is true for you, use the GNU alloca.o here.
ALLOCA =

prefix = /usr/local
exec_prefix = ${prefix}
edit_program_name = sed 's,x,x,'

bindir = $(exec_prefix)/bin

DEFAULT_EDITOR_PROGRAM = ed
DIFF_PROGRAM = $(bindir)/`echo xwindiff | $(edit_program_name)`
NULL_DEVICE = /dev/null
PR_PROGRAM = /bin/pr

#### End of system configuration section. ####

SHELL = /bin/sh

# The source files for all of the programs.
srcs=xwindiff.c analyze.c cmpbuf.c io.c util.c regex.c alloca.c version.c \
	DiffDisplay.c DiffDisplay.h DiffDisplayP.h cmpbuf.h diff.h icon.h \
	regex.h system.h tick.h xwindiff.h
distfiles = $(srcs) README Makefile.in config.hin configure configure.in \
	COPYING install-sh mkinstalldirs stamp-h.in

PROGRAMS = xwindiff

all: $(PROGRAMS)

COMPILE = $(CC) -c $(CPPFLAGS) $(DEFS) -I. -I$(srcdir) $(CFLAGS)

.c.o:
	$(COMPILE) $<

xwindiff_o = xwindiff.o analyze.o cmpbuf.o io.o util.o regex.o version.o \
	DiffDisplay.o $(ALLOCA) $(LIBOBJS)
xwindiff: $(xwindiff_o)
	$(CC) -o $@ $(CFLAGS) $(LDFLAGS) $(xwindiff_o) $(LIBS)
	@ls -al $@;strip $@;ls -al $@

$(xwindiff_o): diff.h system.h
xwindiff.o: DiffDisplay.h xwindiff.h icon.h tick.h cmpbuf.h

TAGS: $(srcs)
	etags $(srcs)

clean:
	rm -f *.o $(PROGRAMS) core
	rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.log
	rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs

mostlyclean: clean

distclean: clean
	rm -f Makefile config.cache config.h config.log config.status stamp-h

realclean: distclean
	rm -f TAGS

install: all installdirs
	for p in $(PROGRAMS); do \
	  $(INSTALL_PROGRAM) $$p $(bindir)/`echo $$p | $(edit_program_name)`; \
	done

installdirs:
	$(SHELL) ${srcdir}/mkinstalldirs $(bindir)

uninstall:
	for p in $(PROGRAMS); do \
	  rm -f $(bindir)/`echo $$p | $(edit_program_name)`; \
	done

configure: configure.in
	cd $(srcdir) && autoconf

# autoheader might not change config.hin.
config.hin: stamp-h.in
stamp-h.in: configure.in
	cd $(srcdir) && autoheader
	date > $(srcdir)/stamp-h.in

config.status: configure
	./config.status --recheck

# config.status might not change config.h, but it changes stamp-h.
config.h: stamp-h
stamp-h: config.hin config.status
	./config.status
Makefile: Makefile.in config.status
	./config.status

dist: $(distfiles)
	echo xwindiff-`sed -e '/version_string/!d' -e 's/[^0-9]*\([0-9a-z.]*\).*/\1/' -e q version.c` > .fname
	rm -rf `cat .fname`
	mkdir `cat .fname`
	-ln $(distfiles) `cat .fname`
	for file in $(distfiles); do \
	  [ -r `cat .fname`/$$file ] || cp -p $$file `cat .fname` || exit; \
	done
	tar -chf - `cat .fname` | gzip >`cat .fname`.tar.gz
	rm -rf `cat .fname` .fname

# Prevent GNU make v3 from overflowing arg limit on SysV.
.NOEXPORT:
