]>
Commit | Line | Data |
---|---|---|
14c7c974 A |
1 | |
2 | DIR = libsa | |
3 | include ../MakePaths.dir | |
4 | ||
5 | UTILDIR = ../util | |
6 | INSTALL_SA_DIR = $(DSTROOT)/System/Library/Frameworks/System.framework/Versions/B/PrivateHeaders/standalone | |
7 | INSTALL_MD_DIR = $(DSTROOT)/System/Library/Frameworks/System.framework/Versions/B/PrivateHeaders/machdep/i386 | |
8 | ||
bba600dd | 9 | OPTIM = -Os -Oz |
75b89a82 | 10 | CFLAGS = $(RC_CFLAGS) $(OPTIM) $(MORECPP) -arch i386 -g -Wmost -Werror \ |
f083c6c3 | 11 | -fno-builtin -static -fomit-frame-pointer \ |
bba600dd A |
12 | -mpreferred-stack-boundary=2 -fno-align-functions \ |
13 | -mno-sse2 -mfpmath=387 | |
14c7c974 A |
14 | |
15 | INC = -I. -I$(SYMROOT) -I$(UTILDIR) | |
16 | ifneq "" "$(wildcard /bin/mkdirs)" | |
17 | MKDIRS = /bin/mkdirs | |
18 | else | |
19 | MKDIRS = /bin/mkdir -p | |
20 | endif | |
21 | AS = as | |
22 | LD = ld | |
23 | # LIBS= -lc_static | |
24 | LIBS= | |
25 | ||
26 | VPATH = $(OBJROOT):$(SYMROOT) | |
27 | ||
28 | SA_OBJS = prf.o printf.o zalloc.o \ | |
29 | string.o strtol.o error.o \ | |
75b89a82 | 30 | setjmp.o qsort.o |
14c7c974 A |
31 | |
32 | SFILES = setjmp.s | |
33 | CFILES = prf.c printf.c zalloc.c \ | |
34 | string.c strtol.c error.c \ | |
75b89a82 | 35 | qsort.c |
14c7c974 | 36 | HFILES = memory.h |
f083c6c3 | 37 | EXPORTED_HFILES = libsa.h memory.h |
14c7c974 | 38 | INSTALLED_SA_HFILES = libsa.h |
14c7c974 A |
39 | OTHERFILES = Makefile |
40 | ALLSRC = $(SFILES) $(CFILES) $(HFILES) $(OTHERFILES) | |
41 | LIBS = libsa.a | |
42 | DIRS_NEEDED = $(OBJROOT) $(SYMROOT) | |
43 | ||
44 | all: $(DIRS_NEEDED) $(LIBS) | |
45 | ||
46 | libsa.a: $(SA_OBJS) | |
57c72a9a A |
47 | rm -f $(SYMROOT)/$(@F) |
48 | ar q $(SYMROOT)/$(@F) $^ | |
49 | ranlib $(SYMROOT)/$(@F) | |
14c7c974 A |
50 | |
51 | clean:: | |
52 | rm -rf $(SYMROOT)/libsa.a $(SYMROOT)/libsaio.a | |
53 | ||
54 | $(INSTALL_SA_DIR) $(INSTALL_MD_DIR): | |
55 | $(MKDIRS) $@ | |
56 | ||
57 | installhdrs:: $(INSTALL_SA_DIR) $(INSTALL_MD_DIR) | |
58 | cp $(INSTALLED_SA_HFILES) $(INSTALL_SA_DIR) | |
14c7c974 A |
59 | |
60 | include ../MakeInc.dir | |
61 | ||
62 | # dependencies | |
63 | -include $(OBJROOT)/Makedep |