bruce.lab...@autoliv.com writes: > There are two files that need to be compiled with gcc, and five with g++.
(completely un-tested) MYFLAGS=-g -Werror -Wall -Wcast-qual CFLAGS=$(MYFLAGS) CXXFLAGS=$(MYFLAGS) # we define _XOPEN_SOURCE because.... # we define _GNU_SOURCE because .... # modify to suit to your situation CPPFLAGS=-D_XOPEN_SOURCE=500 -D_GNU_SOURCE # file1 and file2 are C files, the rest are C++ files OBJS=file1.o file2.o file3.o file4.o file5.o file6.o file7.o .PHONY: all clean war all: myproject clean: $(RM) $(OBJS) myproject.o myproject: myproject.o $(OBJS) $(CXX) $(CXXFLAGS) $+ -o $@ $(LDFLAGS) war: @echo make love not war Hope this helps, --kevin -- GnuPG ID: B280F24E God, I loved that Pontiac. alumni.unh.edu!kdc -- Tom Waits http://kdc-blog.blogspot.com/ _______________________________________________ gnhlug-discuss mailing list gnhlug-discuss@mail.gnhlug.org http://mail.gnhlug.org/mailman/listinfo/gnhlug-discuss/