# $OpenBSD: patch-aa,v 1.5 2000/04/01 17:23:54 form Exp $

--- Makefile.orig	Sun Apr  2 00:32:47 2000
+++ Makefile	Sun Apr  2 00:35:40 2000
@@ -1,8 +1,8 @@
 # Makefile for analog 4.1
 # Please read docs/Readme.html, or http://www.analog.cx/
-CC = gcc           # which compiler to use: eg cc, acc, gcc. NB Different
+#CC = gcc           # which compiler to use: eg cc, acc, gcc. NB Different
 #                    compilers need different CFLAGS, e.g., -O instead of -O2.
-CEXTRAFLAGS = -O2  # options, e.g. for optimisation or ANSI compilation.
+#CEXTRAFLAGS = -O2  # options, e.g. for optimisation or ANSI compilation.
 #                    HP/UX cc requires CEXTRAFLAGS = -Aa (HP/UX 9) or ...
 #                    -Ae (HP/UX 10);       BS2000/OSD requires -XLLML -XLLMK;
 #                    NeXTSTEP apparently needs...
@@ -29,7 +29,9 @@
 	input.o macinput.o macstuff.o output.o output2.o pcre.o process.o \
 	settings.o sort.o tree.o utils.o win32.o
 HEADERS = anlghead.h anlghea2.h anlghea3.h anlghea4.h macdir.h pcre.h
-CFLAGS = $(CEXTRAFLAGS) $(DEFS) -D$(OS)
+CFLAGS += $(CEXTRAFLAGS) $(DEFS) -D$(OS)
+
+all:	$(PROGRAM)
 
 $(PROGRAM): $(OBJS) $(HEADERS) Makefile
 	$(CC) $(CEXTRAFLAGS) $(OBJS) -o $(PROGRAM) $(LIBS)
@@ -39,64 +41,64 @@
 
 # There doesn't seem to be a good way to write all these rules in a generic
 # form that works for all "make" programs
-alias.o: alias.c $(HEADERS) Makefile
+alias.o: alias.c $(HEADERS)
 	$(CC) $(CFLAGS) -c alias.c
 
-analog.o: analog.c $(HEADERS) Makefile
+analog.o: analog.c $(HEADERS)
 	$(CC) $(CFLAGS) -c analog.c
 
-cache.o: cache.c $(HEADERS) Makefile
+cache.o: cache.c $(HEADERS)
 	$(CC) $(CFLAGS) -c cache.c
 
-dates.o: dates.c $(HEADERS) Makefile
+dates.o: dates.c $(HEADERS)
 	$(CC) $(CFLAGS) -c dates.c
 
-globals.o: globals.c $(HEADERS) Makefile
+globals.o: globals.c $(HEADERS)
 	$(CC) $(CFLAGS) -c globals.c
 
-hash.o: hash.c $(HEADERS) Makefile
+hash.o: hash.c $(HEADERS)
 	$(CC) $(CFLAGS) -c hash.c
 
-init.o: init.c $(HEADERS) Makefile
+init.o: init.c $(HEADERS)
 	$(CC) $(CFLAGS) -c init.c
 
-init2.o: init2.c $(HEADERS) Makefile
+init2.o: init2.c $(HEADERS)
 	$(CC) $(CFLAGS) -c init2.c
 
-input.o: input.c $(HEADERS) Makefile
+input.o: input.c $(HEADERS)
 	$(CC) $(CFLAGS) -c input.c
 
-macinput.o: macinput.c $(HEADERS) Makefile
+macinput.o: macinput.c $(HEADERS)
 	$(CC) $(CFLAGS) -c macinput.c
 
-macstuff.o: macstuff.c $(HEADERS) Makefile
+macstuff.o: macstuff.c $(HEADERS)
 	$(CC) $(CFLAGS) -c macstuff.c
 
-output.o: output.c $(HEADERS) Makefile
+output.o: output.c $(HEADERS)
 	$(CC) $(CFLAGS) -c output.c
 
-output2.o: output2.c $(HEADERS) Makefile
+output2.o: output2.c $(HEADERS)
 	$(CC) $(CFLAGS) -c output2.c
 
-pcre.o: pcre.c pcre.h pcrechar.c pcreintl.h Makefile
+pcre.o: pcre.c pcre.h pcrechar.c pcreintl.h
 	$(CC) $(CFLAGS) -c pcre.c
 
-process.o: process.c $(HEADERS) Makefile
+process.o: process.c $(HEADERS)
 	$(CC) $(CFLAGS) -c process.c
 
-settings.o: settings.c $(HEADERS) Makefile
+settings.o: settings.c $(HEADERS)
 	$(CC) $(CFLAGS) -c settings.c
 
-sort.o: sort.c $(HEADERS) Makefile
+sort.o: sort.c $(HEADERS)
 	$(CC) $(CFLAGS) -c sort.c
 
-tree.o: tree.c $(HEADERS) Makefile
+tree.o: tree.c $(HEADERS)
 	$(CC) $(CFLAGS) -c tree.c
 
-utils.o: utils.c $(HEADERS) Makefile
+utils.o: utils.c $(HEADERS)
 	$(CC) $(CFLAGS) -c utils.c
 
-win32.o: win32.c $(HEADERS) Makefile
+win32.o: win32.c $(HEADERS)
 	$(CC) $(CFLAGS) -c win32.c
 
 force:
