Subversion Repositories HelenOS

Rev

Rev 3689 | Rev 4341 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3689 Rev 3691
Line 73... Line 73...
73
	ln -sfn ../arch/$(ARCH)/include include/arch
73
	ln -sfn ../arch/$(ARCH)/include include/arch
74
 
74
 
75
-include Makefile.depend
75
-include Makefile.depend
76
 
76
 
77
clean:
77
clean:
78
	-rm -f $(OUTPUT) $(OUTPUT).map $(OUTPUT).disasm $(OUTPUT).sections Makefile.depend *.o arch/$(ARCH)/_link.ld include/arch _link.ld
78
	-rm -f $(OUTPUT) $(OUTPUT).map $(OUTPUT).disasm $(OUTPUT).sections Makefile.depend *.o arch/$(ARCH)/_link.ld
79
	find arch/$(ARCH)/ -name '*.o' -follow -exec rm \{\} \;
79
	find arch/$(ARCH)/ -name '*.o' -follow -exec rm \{\} \;
80
 
80
 
81
depend:
81
depend:
82
	$(CC) $(DEFS) $(CFLAGS) -M $(ARCH_SOURCES) $(GENERIC_SOURCES)> Makefile.depend
82
	$(CC) $(DEFS) $(CFLAGS) -M $(ARCH_SOURCES) $(GENERIC_SOURCES)> Makefile.depend
83
 
83
 
84
$(OUTPUT): $(ARCH_OBJECTS) $(GENERIC_OBJECTS) $(LIBS) _link.ld
84
$(OUTPUT): $(ARCH_OBJECTS) $(GENERIC_OBJECTS) $(LIBS) arch/$(ARCH)/_link.ld
85
	$(LD) -T _link.ld $(ARCH_OBJECTS) $(GENERIC_OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map
85
	$(LD) -T arch/$(ARCH)/_link.ld $(ARCH_OBJECTS) $(GENERIC_OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map
86
 
86
 
87
disasm:
87
disasm:
88
	$(OBJDUMP) -d -S -s $(OUTPUT) >$(OUTPUT).disasm
88
	$(OBJDUMP) -d -S -s $(OUTPUT) >$(OUTPUT).disasm
89
 
89
 
90
sections:
90
sections:
91
	$(OBJDUMP) -h $(OUTPUT) >$(OUTPUT).sections
91
	$(OBJDUMP) -h $(OUTPUT) >$(OUTPUT).sections
92
 
92
 
93
_link.ld: _link.ld.in
93
arch/$(ARCH)/_link.ld: arch/$(ARCH)/_link.ld.in
94
	$(CC) $(DEFS) $(CFLAGS) -DLIBC_PREFIX=$(LIBC_PREFIX) -E -x c $< | grep -v "^\#" > $@
94
	$(CC) $(DEFS) $(CFLAGS) -DLIBC_PREFIX=$(LIBC_PREFIX) -E -x c $< | grep -v "^\#" > $@
95
 
95
 
96
%.o: %.S
96
%.o: %.S
97
	$(CC) $(DEFS) $(AFLAGS) $(CFLAGS) -D__ASM__ -c $< -o $@
97
	$(CC) $(DEFS) $(AFLAGS) $(CFLAGS) -D__ASM__ -c $< -o $@
98
 
98