- DBGKD_WAIT_STATE_CHANGE64 is used in KD protocol 5, not number 6 that we use. Proto...
[reactos.git] / reactos / lib / ppcmmu / ppcmmu.mak
1 O=$(INTERMEDIATE)/lib/ppcmmu
2 S=lib/ppcmmu
3 CC=powerpc-unknown-elf-gcc -I$T/include/reactos/ppcmmu
4 AR=powerpc-unknown-elf-ar
5 CFLAGS=-Iinclude/reactos/libs -Iinclude/crt -Iinclude/reactos -D__cdecl__=
6 OBJCOPY=powerpc-unknown-elf-objcopy
7 LDSCRIPT=-Wl,-T,$S/ldscript
8 PPCMMU_TARGETS=$O/libppcmmu_code.a
9 MMUOBJECT_OBJS=$O/devint.o $O/mmuobject.o $O/mmuutil_object.o $O/mmutest.o $O/gdblib.o
10
11 mkdir_ppcmmu:
12 -mkdir -p $O
13
14 $O/mmuutil_object.o: $S/mmuutil.c | mkdir_ppcmmu
15 $(CC) $(CFLAGS) -g -c -o $@ $S/mmuutil.c
16
17 $O/libppcmmu_code.a: $(MMUOBJECT_OBJS)
18 $(CC) -Wl,-N -nostartfiles -nostdlib -o $O/mmuobject -Ttext=0x10000 $(LDSCRIPT) -Wl,-u,mmumain -Wl,-u,data_miss_start -Wl,-u,data_miss_end $(MMUOBJECT_OBJS)
19 $(OBJCOPY) -O binary $O/mmuobject mmucode
20 $(OBJCOPY) -I binary -O elf32-powerpc -B powerpc:common mmucode $O/mmucode.o
21 mkdir -p `dirname $@`
22 $(AR) cr $@ $O/mmucode.o
23
24 $O/gdblib.o: $S/gdblib.c | mkdir_ppcmmu
25 $(CC) $(CFLAGS) -g -c -o $@ $S/gdblib.c
26
27 $O/devint.o: $S/devint.s | mkdir_ppcmmu
28 $(CC) $(CFLAGS) -g -c -o $@ $S/devint.s
29
30 $O/mmuobject.o: $S/mmuobject.c $S/mmuobject.h | mkdir_ppcmmu
31 $(CC) $(CFLAGS) -g -c -o $@ $S/mmuobject.c
32
33 $O/mmutest.o: $S/mmutest.c $S/mmuobject.h | mkdir_ppcmmu
34 $(CC) $(CFLAGS) -g -c -o $@ $S/mmutest.c
35
36 ppcmmuobject_clean:
37 rm -f $O/*.o $O/*.a mmucode $O/mmuobject