Rev 3665 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3665 | Rev 3742 | ||
---|---|---|---|
Line 95... | Line 95... | ||
95 | 95 | ||
96 | GENERIC_OBJECTS := $(addsuffix .o,$(basename $(GENERIC_SOURCES))) |
96 | GENERIC_OBJECTS := $(addsuffix .o,$(basename $(GENERIC_SOURCES))) |
97 | ARCH_OBJECTS := $(addsuffix .o,$(basename $(ARCH_SOURCES))) |
97 | ARCH_OBJECTS := $(addsuffix .o,$(basename $(ARCH_SOURCES))) |
98 | GENARCH_OBJECTS := $(addsuffix .o,$(basename $(GENARCH_SOURCES))) |
98 | GENARCH_OBJECTS := $(addsuffix .o,$(basename $(GENARCH_SOURCES))) |
99 | 99 | ||
- | 100 | OBJECTS := $(ARCH_OBJECTS) $(GENERIC_OBJECTS) $(GENARCH_OBJECTS) |
|
- | 101 | ||
100 | .PHONY: all clean depend disasm links |
102 | .PHONY: all clean depend disasm links |
101 | 103 | ||
102 | all: links $(OUTPUT) $(OUTPUT).disasm |
104 | all: links $(OUTPUT) $(OUTPUT).disasm |
103 | 105 | ||
104 | -include Makefile.depend |
106 | -include Makefile.depend |
Line 106... | Line 108... | ||
106 | links: |
108 | links: |
107 | ln -sfn ../arch/$(ARCH)/include include/arch |
109 | ln -sfn ../arch/$(ARCH)/include include/arch |
108 | ln -sfn ../genarch/include include/genarch |
110 | ln -sfn ../genarch/include include/genarch |
109 | 111 | ||
110 | clean: |
112 | clean: |
111 | -rm -f $(OUTPUT) $(OUTPUT).map $(OUTPUT).disasm Makefile.depend include/arch include/genarch |
113 | -rm -f $(OUTPUT) $(OUTPUT).map $(OUTPUT).disasm Makefile.depend include/arch include/genarch $(OBJECTS) |
112 | 114 | ||
113 | depend: |
115 | depend: |
114 | $(CC) $(DEFS) $(CFLAGS) -M $(SOURCES) > Makefile.depend |
116 | $(CC) $(DEFS) $(CFLAGS) -M $(SOURCES) > Makefile.depend |
115 | 117 | ||
116 | $(OUTPUT): $(ARCH_OBJECTS) $(GENERIC_OBJECTS) $(GENARCH_OBJECTS) $(LIBS) |
118 | $(OUTPUT): $(OBJECTS) $(LIBS) |
117 | $(LD) -T $(LIBC_PREFIX)/arch/$(ARCH)/_link.ld $(GENERIC_OBJECTS) $(ARCH_OBJECTS) $(GENARCH_OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map |
119 | $(LD) -T $(LIBC_PREFIX)/arch/$(ARCH)/_link.ld $(OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map |
118 | 120 | ||
119 | disasm: $(OUTPUT).disasm |
121 | disasm: $(OUTPUT).disasm |
120 | 122 | ||
121 | $(OUTPUT).disasm: $(OUTPUT) |
123 | $(OUTPUT).disasm: $(OUTPUT) |
122 | $(OBJDUMP) -d $< >$@ |
124 | $(OBJDUMP) -d $< >$@ |