[EMAIL PROTECTED] wrote: > I suppose I have to move the object file at the end of target "%.o" to > the "build" directory, but I don't know how.
Try # ============ # Variables # ============ PROGRAM = program.bin CXX = c++ SOURCES = $(shell ls src/*.cpp) OBJECTS = $(SOURCES:src/%.cpp=build/%.o) INCS = -Iinclude -Igfx LIBS = -L/app/glib/1.2.10/lib -L/app/gtk+/1.2.10/lib # ============ # Targets # ============ $(PROGRAM): $(OBJECTS) $(CXX) -o $(PROGRAM) $(OBJECTS) $(LIBS) build/%.o : src/%.cpp $(CXX) -c $(INCS) -o $@ $< clean: \rm src/*.o $(PROGRAM) Andre' _______________________________________________ help-gnu-utils mailing list help-gnu-utils@gnu.org http://lists.gnu.org/mailman/listinfo/help-gnu-utils