Subversion Repositories HelenOS

Rev

Rev 3108 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3108 Rev 4377
Line 30... Line 30...
30
## Setup toolchain
30
## Setup toolchain
31
#
31
#
32
 
32
 
33
LIBC_PREFIX = ../../lib/libc
33
LIBC_PREFIX = ../../lib/libc
34
SOFTINT_PREFIX = ../../lib/softint
34
SOFTINT_PREFIX = ../../lib/softint
-
 
35
 
35
include $(LIBC_PREFIX)/Makefile.toolchain
36
include $(LIBC_PREFIX)/Makefile.toolchain
36
include arch/$(ARCH)/Makefile.inc
37
include arch/$(UARCH)/Makefile.inc
37
include genarch/Makefile.inc
38
include genarch/Makefile.inc
38
 
39
 
39
CFLAGS += -I../../srv/kbd/include -Igenarch/idec
40
CFLAGS += -I../../srv/kbd/include -Igenarch/idec
40
 
41
 
41
LIBS = $(LIBC_PREFIX)/libc.a
42
LIBS = $(LIBC_PREFIX)/libc.a
Line 56... Line 57...
56
.PHONY: all clean depend disasm inc
57
.PHONY: all clean depend disasm inc
57
 
58
 
58
all: inc $(OUTPUT) disasm
59
all: inc $(OUTPUT) disasm
59
 
60
 
60
inc:
61
inc:
61
	ln -sfn ../arch/$(ARCH)/include include/arch
62
	ln -sfn ../arch/$(UARCH)/include include/arch
62
 
63
 
63
-include Makefile.depend
64
-include Makefile.depend
64
 
65
 
65
clean:
66
clean:
66
	-rm -f $(OUTPUT) $(OUTPUT).map $(OUTPUT).disasm Makefile.depend include/arch
67
	-rm -f $(OUTPUT) $(OUTPUT).map $(OUTPUT).disasm Makefile.depend include/arch
Line 68... Line 69...
68
 
69
 
69
depend:
70
depend:
70
	$(CC) $(DEFS) $(CFLAGS) -M $(SOURCES) > Makefile.depend
71
	$(CC) $(DEFS) $(CFLAGS) -M $(SOURCES) > Makefile.depend
71
 
72
 
72
$(OUTPUT): $(OBJECTS) $(LIBS)
73
$(OUTPUT): $(OBJECTS) $(LIBS)
73
	$(LD) -T $(LIBC_PREFIX)/arch/$(ARCH)/_link.ld $(OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map
74
	$(LD) -T $(LIBC_PREFIX)/arch/$(UARCH)/_link.ld $(OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map
74
 
75
 
75
disasm:
76
disasm:
76
	$(OBJDUMP) -d $(OUTPUT) >$(OUTPUT).disasm
77
	$(OBJDUMP) -d $(OUTPUT) >$(OUTPUT).disasm
77
 
78
 
78
%.o: %.S
79
%.o: %.S