Rev 3555 | Rev 3557 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3555 | Rev 3556 | ||
---|---|---|---|
Line 31... | Line 31... | ||
31 | 31 | ||
32 | ## Setup toolchain |
32 | ## Setup toolchain |
33 | # |
33 | # |
34 | 34 | ||
35 | LIBC_PREFIX = ../../lib/libc |
35 | LIBC_PREFIX = ../../lib/libc |
36 | LIBCS_PREFIX = ../../lib/libc-shared |
36 | LIBCS_PREFIX = ../../lib/libc/shared |
37 | SOFTINT_PREFIX = ../../lib/softint |
37 | SOFTINT_PREFIX = ../../lib/softint |
38 | RTLD_PREFIX = ../../lib/rtld |
38 | RTLD_PREFIX = ../../lib/rtld |
39 | include $(LIBC_PREFIX)/Makefile.toolchain |
39 | include $(LIBC_PREFIX)/Makefile.toolchain |
40 | 40 | ||
41 | CFLAGS += -I../../lib/libc -O0 |
41 | CFLAGS += -I../../lib/libc -O0 |
42 | LFLAGS := -Bdynamic -I/lib/rtld -rpath-link $(RTLD_PREFIX) |
42 | LFLAGS := -Bdynamic -I/lib/rtld -rpath-link $(RTLD_PREFIX) |
43 | 43 | ||
44 | # LIBS = $(LIBC_PREFIX)/libc.a |
- | |
45 | LIBS = ../../lib/libc-shared/libc.so.0 |
44 | LIBS = ../../lib/libc/shared/libc.so.0 |
46 | DEFS += -DRELEASE=\"$(RELEASE)\" |
- | |
47 | - | ||
48 | ifdef REVISION |
- | |
49 | DEFS += "-DREVISION=\"$(REVISION)\"" |
- | |
50 | endif |
- | |
51 | - | ||
52 | ifdef TIMESTAMP |
- | |
53 | DEFS += "-DTIMESTAMP=\"$(TIMESTAMP)\"" |
- | |
54 | endif |
- | |
55 | 45 | ||
56 | ## Sources |
46 | ## Sources |
57 | # |
47 | # |
58 | 48 | ||
59 | OUTPUT = dltest |
49 | OUTPUT = dltest |
Line 78... | Line 68... | ||
78 | $(LD) -T $(LIBCS_PREFIX)/arch/$(ARCH)/_link.ld $(OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map |
68 | $(LD) -T $(LIBCS_PREFIX)/arch/$(ARCH)/_link.ld $(OBJECTS) $(LIBS) $(LFLAGS) -o $@ -Map $(OUTPUT).map |
79 | 69 | ||
80 | disasm: |
70 | disasm: |
81 | $(OBJDUMP) -d $(OUTPUT) >$(OUTPUT).disasm |
71 | $(OBJDUMP) -d $(OUTPUT) >$(OUTPUT).disasm |
82 | 72 | ||
83 | #arch/$(ARCH)/_link.ld: arch/$(ARCH)/_link.ld.in |
- | |
84 | # $(CC) $(DEFS) $(CFLAGS) -DLIBC_PREFIX=$(LIBC_PREFIX) -E -x c $< | grep -v "^\#" > $@ |
- | |
85 | - | ||
86 | %.o: %.S |
73 | %.o: %.S |
87 | $(CC) $(DEFS) $(AFLAGS) $(CFLAGS) -D__ASM__ -c $< -o $@ |
74 | $(CC) $(DEFS) $(AFLAGS) $(CFLAGS) -D__ASM__ -c $< -o $@ |
88 | 75 | ||
89 | %.o: %.s |
76 | %.o: %.s |
90 | $(AS) $(AFLAGS) $< -o $@ |
77 | $(AS) $(AFLAGS) $< -o $@ |