httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject [PATCH] yet another Makefile tweak
Date Thu, 11 Sep 1997 19:19:24 GMT
With the current CVS image I experience a few Makefile problems: 

- regex is always rebuilt

- os/unix doesn't clean up for itself, instead relies on the top level to
  clean up. 

- the top level should clean itself only and recurse, not delete lower
  level objects.

The following has been tested with gnu make (including make -j), and with
BSD make (pmake under linux).

Dean

Index: Makefile.tmpl
===================================================================
RCS file: /export/home/cvs/apachen/src/Makefile.tmpl,v
retrieving revision 1.63
diff -u -r1.63 Makefile.tmpl
--- Makefile.tmpl	1997/09/06 23:38:40	1.63
+++ Makefile.tmpl	1997/09/11 19:15:13
@@ -43,8 +43,8 @@
 	cd support; $(MAKE) CC='$(CC)' AUX_CFLAGS='$(CFLAGS)' RANLIB='$(RANLIB)'
 
 clean:
-	rm -f httpd *.o $(OBJS) 
-	for i in $(SUBDIRS) regex; do \
+	rm -f httpd *.o
+	for i in $(SUBDIRS); do \
 		( cd $$i; $(MAKE) $@ ) \
 	done
 
Index: os/unix/Makefile.tmpl
===================================================================
RCS file: /export/home/cvs/apachen/src/os/unix/Makefile.tmpl,v
retrieving revision 1.4
diff -u -r1.4 Makefile.tmpl
--- Makefile.tmpl	1997/09/10 20:05:39	1.4
+++ Makefile.tmpl	1997/09/11 19:15:13
@@ -19,7 +19,7 @@
 	$(CC) -c $(INCLUDES) $(CFLAGS) $(SPACER) $<
 
 clean:
-	rm -f $(OBJS)
+	rm -f $(OBJS) $(LIB)
 
 $(OBJS): Makefile
 
Index: regex/Makefile
===================================================================
RCS file: /export/home/cvs/apachen/src/regex/Makefile,v
retrieving revision 1.7
diff -u -r1.7 Makefile
--- Makefile	1997/09/10 20:05:40	1.7
+++ Makefile	1997/09/11 19:15:13
@@ -35,7 +35,9 @@
 .c.ih:
 	sh ./mkh $(MKHFLAGS) -p $< >$@
 
-all lib:	purge $(OBJPRODN)
+all lib: libregex.a
+
+libregex.a: $(OBJPRODN)
 	rm -f libregex.a
 	ar cr libregex.a $(OBJPRODN)
 	$(RANLIB) libregex.a
@@ -49,9 +51,9 @@
 REGEXH=regex.h
 REGEXHSRC=regex2.h $(REGSRC)
 $(REGEXH):	$(REGEXHSRC) mkh
-	sh ./mkh $(MKHFLAGS) -i _REGEX_H_ $(REGEXHSRC) >regex.tmp
-	cmp -s regex.tmp regex.h 2>/dev/null || cp regex.tmp regex.h
-	rm -f regex.tmp
+	sh ./mkh $(MKHFLAGS) -i _REGEX_H_ $(REGEXHSRC) >regex.h
+	#cmp -s regex.tmp regex.h 2>/dev/null || cp regex.tmp regex.h
+	#rm -f regex.tmp
 
 # dependencies
 $(OBJPRODN) debug.o:	utils.h regex.h regex2.h


Mime
View raw message