| @@ -1,74 +1,75 @@ | | | @@ -1,74 +1,75 @@ |
1 | # $NetBSD: Makefile,v 1.33 2011/06/02 18:53:00 dsl Exp $ | | 1 | # $NetBSD: Makefile,v 1.34 2011/06/07 20:05:46 joerg Exp $ |
2 | | | 2 | |
3 | S?= ${.CURDIR}/../../../.. | | 3 | S?= ${.CURDIR}/../../../.. |
4 | | | 4 | |
5 | LIB= i386 | | 5 | LIB= i386 |
6 | NOPIC=# defined | | 6 | NOPIC=# defined |
7 | NOPROFILE=# defined | | 7 | NOPROFILE=# defined |
8 | | | 8 | |
9 | I386_INCLUDE_DISK?= yes | | 9 | I386_INCLUDE_DISK?= yes |
10 | I386_INCLUDE_DOS?= no | | 10 | I386_INCLUDE_DOS?= no |
11 | I386_INCLUDE_BUS?= no | | 11 | I386_INCLUDE_BUS?= no |
12 | I386_INCLUDE_PS2?= yes | | 12 | I386_INCLUDE_PS2?= yes |
13 | | | 13 | |
14 | AFLAGS.biosdelay.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 14 | AFLAGS.biosdelay.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
15 | AFLAGS.biosgetrtc.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 15 | AFLAGS.biosgetrtc.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
16 | AFLAGS.biosgetsystime.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 16 | AFLAGS.biosgetsystime.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
17 | AFLAGS.biosmca.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 17 | AFLAGS.biosmca.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
18 | AFLAGS.biosmemps2.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 18 | AFLAGS.biosmemps2.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
19 | AFLAGS.biosmem.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 19 | AFLAGS.biosmem.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
20 | AFLAGS.biosmemx.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 20 | AFLAGS.biosmemx.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
21 | AFLAGS.biosreboot.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 21 | AFLAGS.biosreboot.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
22 | AFLAGS.biosvbe.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 22 | AFLAGS.biosvbe.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
23 | AFLAGS.biosvideomode.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 23 | AFLAGS.biosvideomode.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
24 | AFLAGS.bios_disk.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 24 | AFLAGS.bios_disk.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
25 | AFLAGS.bios_pci.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 25 | AFLAGS.bios_pci.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
26 | AFLAGS.comio.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 26 | AFLAGS.comio.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
27 | AFLAGS.conio.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 27 | AFLAGS.conio.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
28 | AFLAGS.dos_file.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 28 | AFLAGS.dos_file.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
29 | AFLAGS.dump_eax.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 29 | AFLAGS.dump_eax.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
30 | AFLAGS.message.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 30 | AFLAGS.message.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
31 | AFLAGS.message32.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 31 | AFLAGS.message32.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
32 | AFLAGS.pvcopy.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 32 | AFLAGS.pvcopy.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
33 | AFLAGS.putstr.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 33 | AFLAGS.putstr.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
| | | 34 | AFLAGS.putstr32.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
34 | AFLAGS.realprot.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} | | 35 | AFLAGS.realprot.S= ${${ACTIVE_CC} == "clang":?-no-integrated-as:} |
35 | | | 36 | |
36 | CPPFLAGS= -I$S/lib/libsa ${I386CPPFLAGS} ${I386MISCCPPFLAGS} | | 37 | CPPFLAGS= -I$S/lib/libsa ${I386CPPFLAGS} ${I386MISCCPPFLAGS} |
37 | #CPPFLAGS+= -DDISK_DEBUG | | 38 | #CPPFLAGS+= -DDISK_DEBUG |
38 | #CPPFLAGS+= -DNO_DISKLABEL | | 39 | #CPPFLAGS+= -DNO_DISKLABEL |
39 | #CPPFLAGS+= -DNO_GPT | | 40 | #CPPFLAGS+= -DNO_GPT |
40 | #CPPFLAGS+= -DSAVE_MEMORY | | 41 | #CPPFLAGS+= -DSAVE_MEMORY |
41 | | | 42 | |
42 | SRCS= pcio.c conio.S comio.S comio_direct.c biosvideomode.S | | 43 | SRCS= pcio.c conio.S comio.S comio_direct.c biosvideomode.S |
43 | SRCS+= getsecs.c biosgetrtc.S biosdelay.S biosreboot.S gatea20.c | | 44 | SRCS+= getsecs.c biosgetrtc.S biosdelay.S biosreboot.S gatea20.c |
44 | SRCS+= biosmem.S getextmemx.c biosmemx.S printmemlist.c | | 45 | SRCS+= biosmem.S getextmemx.c biosmemx.S printmemlist.c |
45 | SRCS+= pread.c menuutils.c parseutils.c | | 46 | SRCS+= pread.c menuutils.c parseutils.c |
46 | SRCS+= bootinfo.c bootinfo_biosgeom.c bootinfo_memmap.c | | 47 | SRCS+= bootinfo.c bootinfo_biosgeom.c bootinfo_memmap.c |
47 | SRCS+= startprog.S multiboot.S | | 48 | SRCS+= startprog.S multiboot.S |
48 | SRCS+= biosgetsystime.S cpufunc.S bootmenu.c | | 49 | SRCS+= biosgetsystime.S cpufunc.S bootmenu.c |
49 | SRCS+= realprot.S message.S message32.S dump_eax.S pvcopy.S putstr.S putstr32.S | | 50 | SRCS+= realprot.S message.S message32.S dump_eax.S pvcopy.S putstr.S putstr32.S |
50 | SRCS+= rasops.c vbe.c biosvbe.S | | 51 | SRCS+= rasops.c vbe.c biosvbe.S |
51 | .if (${I386_INCLUDE_DISK} == "yes") | | 52 | .if (${I386_INCLUDE_DISK} == "yes") |
52 | SRCS+= biosdisk.c biosdisk_ll.c bios_disk.S | | 53 | SRCS+= biosdisk.c biosdisk_ll.c bios_disk.S |
53 | .endif | | 54 | .endif |
54 | .if (${I386_INCLUDE_DOS} == "yes") | | 55 | .if (${I386_INCLUDE_DOS} == "yes") |
55 | SRCS+= dosfile.c dos_file.S | | 56 | SRCS+= dosfile.c dos_file.S |
56 | .endif | | 57 | .endif |
57 | .if (${I386_INCLUDE_DISK} == "yes") || (${I386_INCLUDE_DOS} == "yes") | | 58 | .if (${I386_INCLUDE_DISK} == "yes") || (${I386_INCLUDE_DOS} == "yes") |
58 | SRCS+= diskbuf.c | | 59 | SRCS+= diskbuf.c |
59 | .endif | | 60 | .endif |
60 | .if (${I386_INCLUDE_BUS} == "yes") | | 61 | .if (${I386_INCLUDE_BUS} == "yes") |
61 | SRCS+= biospci.c bios_pci.S isapnp.c isadma.c | | 62 | SRCS+= biospci.c bios_pci.S isapnp.c isadma.c |
62 | .endif | | 63 | .endif |
63 | .if (${I386_INCLUDE_PS2} == "yes") | | 64 | .if (${I386_INCLUDE_PS2} == "yes") |
64 | SRCS+= biosmca.S biosmemps2.S | | 65 | SRCS+= biosmca.S biosmemps2.S |
65 | .endif | | 66 | .endif |
66 | | | 67 | |
67 | .include <bsd.own.mk> | | 68 | .include <bsd.own.mk> |
68 | .undef DESTDIR | | 69 | .undef DESTDIR |
69 | .include <bsd.lib.mk> | | 70 | .include <bsd.lib.mk> |
70 | | | 71 | |
71 | lib${LIB}.o:: ${OBJS} | | 72 | lib${LIB}.o:: ${OBJS} |
72 | @echo building standard ${LIB} library | | 73 | @echo building standard ${LIB} library |
73 | @rm -f lib${LIB}.o | | 74 | @rm -f lib${LIB}.o |
74 | @${LD} -r -o lib${LIB}.o `lorder ${OBJS} | tsort` | | 75 | @${LD} -r -o lib${LIB}.o `lorder ${OBJS} | tsort` |