hi i want to do a Makefile in linux that will take all the .cpp files in the dir compile them and create one .o file that i can active how i can do it with Implicit Rules
thanks mati
hi i want to do a Makefile in linux that will take all the .cpp files in the dir compile them and create one .o file that i can active how i can do it with Implicit Rules
thanks mati
Implicit rules will help you create the object files, but combining them together will have to be done explicitly (as it is something that is rarely done).
OBJ = a.o b.o
big.o : ${OBJ}
${LD} -r -o $@ $^