Subversion Repositories HelenOS

Rev

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

Rev 471 Rev 472
Line 138... Line 138...
138
ARCH_OBJECTS := $(addsuffix .o,$(basename $(ARCH_SOURCES)))
138
ARCH_OBJECTS := $(addsuffix .o,$(basename $(ARCH_SOURCES)))
139
GENARCH_OBJECTS := $(addsuffix .o,$(basename $(GENARCH_SOURCES)))
139
GENARCH_OBJECTS := $(addsuffix .o,$(basename $(GENARCH_SOURCES)))
140
 
140
 
141
.PHONY: all clean config depend boot
141
.PHONY: all clean config depend boot
142
 
142
 
143
all: kernel.bin boot
143
all: kernel.bin boot disasm
144
 
144
 
145
-include Makefile.depend
145
-include Makefile.depend
146
 
146
 
147
clean:
147
clean:
148
	-rm -f kernel.bin kernel.raw kernel.map kernel.map.pre kernel.objdump generic/src/debug/real_map.bin Makefile.depend generic/include/arch generic/include/genarch arch/$(ARCH)/_link.ld
148
	-rm -f kernel.bin kernel.raw kernel.map kernel.map.pre kernel.objdump kernel.disasm generic/src/debug/real_map.bin Makefile.depend generic/include/arch generic/include/genarch arch/$(ARCH)/_link.ld
149
	find generic/src/ arch/$(ARCH)/src/ genarch/src/ -name '*.o' -exec rm \{\} \;
149
	find generic/src/ arch/$(ARCH)/src/ genarch/src/ -name '*.o' -exec rm \{\} \;
150
	$(MAKE) -C arch/$(ARCH)/boot clean
150
	$(MAKE) -C arch/$(ARCH)/boot clean
151
 
151
 
152
config:
152
config:
153
	ln -sfn ../../arch/$(ARCH)/include/ generic/include/arch
153
	ln -sfn ../../arch/$(ARCH)/include/ generic/include/arch
Line 175... Line 175...
175
	$(OBJCOPY) -O $(BFD) kernel.raw kernel.bin
175
	$(OBJCOPY) -O $(BFD) kernel.raw kernel.bin
176
 
176
 
177
boot: kernel.bin
177
boot: kernel.bin
178
	$(MAKE) -C arch/$(ARCH)/boot build KERNEL_SIZE="`cat kernel.bin | wc -c`" CC=$(CC) AS=$(AS) LD=$(LD)
178
	$(MAKE) -C arch/$(ARCH)/boot build KERNEL_SIZE="`cat kernel.bin | wc -c`" CC=$(CC) AS=$(AS) LD=$(LD)
179
 
179
 
-
 
180
disasm: kernel.raw
-
 
181
	$(OBJDUMP) -d kernel.raw > kernel.disasm
-
 
182
 
180
%.o: %.S
183
%.o: %.S
181
	$(CC) $(DEFS) $(AFLAGS) $(CFLAGS) -c $< -o $@
184
	$(CC) $(DEFS) $(AFLAGS) $(CFLAGS) -D__ASM__ -c $< -o $@
182
 
185
 
183
%.o: %.s
186
%.o: %.s
184
	$(AS) $(AFLAGS) $< -o $@
187
	$(AS) $(AFLAGS) $< -o $@
185
 
188
 
186
%.o: %.c
189
%.o: %.c