%% Russell <[EMAIL PROTECTED]> writes: r> SUBDIRS= analog r> .PHONY: $(SUBDIRS) clean proj
r> proj: $(SUBDIRS) r> cd objs \ r> avr-ld -o proj.o -Map proj.map $(addsuffix .o,$(SUBDIRS)) \ r> avr-objcopy -O ihex -R .eeprom -g proj.o proj.hex This syntax is wrong. You must separate your commands with ";" if you connect them all with backslashes. Remember the backslash/newline pairs are removed, so your command above really is interpreted as: cd objs avr-ld -o proj.o -Map proj.map $(addsuffix .o,$(SUBDIRS)) avr-objcopy -O ihex -R .eeprom -g proj.o proj.hex which I feel confident is not what you want. r> In the submake below, make is executed in a subdirectory. r> How can i access the name of the subdirectory in this r> submake? r> $(SUBDIRS): r> $(MAKE) -C $@ Look in the GNU make manual for the CURDIR variable. -- ------------------------------------------------------------------------------- Paul D. Smith <[EMAIL PROTECTED]> Find some GNU make tips at: http://www.gnu.org http://make.paulandlesley.org "Please remain calm...I may be mad, but I am a professional." --Mad Scientist _______________________________________________ Help-make mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/help-make
