]>
Commit | Line | Data |
---|---|---|
14c7c974 A |
1 | |
2 | # Makefile for i386 boot program | |
3 | # define FLOPPY and SMALL using DEFINES macro as necessary | |
4 | ||
5 | DIR = testmodule | |
6 | include ../MakePaths.dir | |
7 | ||
8 | DEBUG = -g | |
9 | OPTIM = -Os | |
10 | CFLAGS = $(DEBUG) $(OPTIM) $(MORECPP) -arch i386 -Wmost -DTEST_INTERNAL_USER | |
11 | DEFINES= | |
12 | CONFIG = hd | |
13 | SYMDIR = $(SYMROOT) | |
14 | LIBSADIR = ../libsa | |
15 | LIBSAIODIR = ../libsaio | |
16 | UTILDIR = ../util | |
17 | INC = -I. -I.. -I$(SYMDIR) -I$(LIBSADIR) -I$(LIBSAIODIR) -I$(UTILDIR) | |
18 | ifneq "" "$(wildcard /bin/mkdirs)" | |
19 | MKDIRS = /bin/mkdirs | |
20 | else | |
21 | MKDIRS = /bin/mkdir -p | |
22 | endif | |
23 | AS = as | |
24 | LD = ld | |
25 | ||
26 | LIBSA = $(SYMDIR)/libsa.a | |
27 | LIBSAIO = $(SYMDIR)/libsaio.a | |
28 | LIBS = $(LIBSAIO) $(LIBSA) | |
29 | ||
30 | OTHER_FILES = | |
31 | ||
32 | INSTALLDIR = $(DSTROOT)/usr/standalone/i386 | |
33 | ||
34 | VPATH = $(OBJROOT):$(SYMROOT) | |
35 | ||
36 | OBJS = test.o test_table.o | |
37 | ||
38 | UTILDIR = ../util | |
39 | SFILES = boot2.s | |
40 | CFILES = boot.c load.c stringTable.c graphics.c browser.c \ | |
41 | button.c scrollbar.c prompt.c | |
42 | HFILES = kernBootStruct.h | |
43 | OTHERFILES = Makefile machOconv.c README | |
44 | ALLSRC = $(FOREIGNSRC) $(FOREIGNBIN) $(SFILES) $(CFILES) \ | |
45 | $(HFILES) $(OTHERFILES) | |
46 | DIRS_NEEDED = $(OBJROOT) $(SYMROOT) | |
47 | BOOT2ADDR = 3000 | |
48 | ||
49 | SIG = $(SYMROOT)/sig | |
50 | GENFILES = $(SYMROOT)/install_internal.h \ | |
51 | $(SYMROOT)/install_external.h \ | |
52 | $(SYMROOT)/install_table.c \ | |
53 | $(SYMROOT)/install_defs.h | |
54 | ||
55 | all: $(DIRS_NEEDED) test_external.h test.module | |
56 | ||
57 | test.module: $(SYMROOT) $(OBJS) | |
58 | $(CC) $(COPTS) $(CFLAGS) $(RC_CFLAGS) -o $@ \ | |
59 | $(OBJS) \ | |
60 | -e _test_entry -u _test_entry \ | |
61 | -seg1addr 50000 -preload -nostdlib $(LIBS) | |
62 | ||
63 | test_internal.h: test_external.h | |
64 | test_table.c: test_external.h | |
65 | test_defs.h: test_external.h | |
66 | test_external.h: test.def | |
67 | $(SIG) -d $(SYMROOT) test.def | |
68 | ||
69 | install_i386:: all $(INSTALLDIR) | |
70 | cp $(SYMROOT)/boot $(OTHER_FILES) $(INSTALLDIR) | |
71 | cd $(INSTALLDIR); chmod u+w boot $(OTHER_FILES) | |
72 | ||
73 | clean:: | |
74 | rm -f $(SYMROOT)/boot.sys $(GENFILES) | |
75 | ||
76 | include ../MakeInc.dir | |
77 | ||
78 | #dependencies | |
79 | -include $(OBJROOT)/Makedep |