Xref: news-dnh.mv.net comp.os.msdos.djgpp:2120 Path: news-dnh.mv.net!mv!news.sprintlink.net!news.uoregon.edu!vixen.cso.uiuc.edu!howland.reston.ans.net!swrinde!cs.utexas.edu!uunet!in1.uu.net!newsfeed.ACO.net!alijku06!news From: Roland Exler Newsgroups: comp.os.msdos.djgpp Subject: Re: Help: Make with auto-dependencies Date: 21 Sep 1995 06:43:15 GMT Organization: Institute for el. Measurement, University of Linz, Austria Lines: 57 References: Nntp-Posting-Host: sensor4.emt.uni-linz.ac.at To: djgpp AT sun DOT soe DOT clarkson DOT edu Dj-Gateway: from newsgroup comp.os.msdos.djgpp This is a multi-part message in MIME format. ---------------------------------2657629415157 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii I use the following makefile for creation of an library, it's easy to change it to compile and link and exe instead. The -MM flag controls which header-files to search. -MM searches only files included with "file", -M would search files included with too. See the manual of gcc for more information. Hope this helps, Roland +---------------------------------------+---------------------------+ I Roland Exler I EMAIL: I I Universitaet Linz I R DOT Exler AT jk DOT uni-linz DOT ac DOT at I I Institut fuer Elektrische Messtechnik I I I Altenbergerstr. 69 I Phone: I I A-4040 Linz, AUSTRIA I + 43 732 2468 9205 I +---------------------------------------+---------------------------+ ---------------------------------2657629415157 Content-Transfer-Encoding: 7bit Content-Type: text/plain SOURCES=DvAxBas DvAxis DvDataVc DvGraph DvGraphO DvMath DvPlot DvPoint \ DvPoints DvScale DvData DvList CXXFLAGS=-Wall -O2 TARGET_ARCH=-m486 LDLIBS= -lgrx -lpc -lm %.d: %.cc $(CC) -MM $(CPPFLAGS) $< | SED 's/$*.o/& $@/g' > $@ %.exe: % strip $< coff2exe $< libplot.a: $(SOURCES:=.o) ar -rs $@ $^ ranlib $@.a include $(SOURCES:=.d) # clear Directory clear: del *.d del *.o ---------------------------------2657629415157--