INSTALL_SA_DIR = $(DSTROOT)/System/Library/Frameworks/System.framework/Versions/B/PrivateHeaders/standalone
INSTALL_MD_DIR = $(DSTROOT)/System/Library/Frameworks/System.framework/Versions/B/PrivateHeaders/machdep/i386
-OPTIM = -Os
-CFLAGS = $(RC_CFLAGS) $(OPTIM) $(MORECPP) -arch i386 -g -Wmost -Wno-precomp \
- -munaligned-text -static -traditional-cpp
+OPTIM = -Os -Oz
+CFLAGS = $(RC_CFLAGS) $(OPTIM) $(MORECPP) -arch i386 -g -Wmost -Werror \
+ -fno-builtin -static -fomit-frame-pointer \
+ -mpreferred-stack-boundary=2 -fno-align-functions \
+ -mno-sse2 -mfpmath=387
INC = -I. -I$(SYMROOT) -I$(UTILDIR)
ifneq "" "$(wildcard /bin/mkdirs)"
SA_OBJS = prf.o printf.o zalloc.o \
string.o strtol.o error.o \
- setjmp.o qsort.o bswap.o
+ setjmp.o qsort.o
SFILES = setjmp.s
CFILES = prf.c printf.c zalloc.c \
string.c strtol.c error.c \
- qsort.c bswap.c
+ qsort.c
HFILES = memory.h
-EXPORTED_HFILES = libsa.h kernBootStruct.h memory.h
+EXPORTED_HFILES = libsa.h memory.h
INSTALLED_SA_HFILES = libsa.h
-INSTALLED_MD_HFILES = kernBootStruct.h
OTHERFILES = Makefile
ALLSRC = $(SFILES) $(CFILES) $(HFILES) $(OTHERFILES)
LIBS = libsa.a
all: $(DIRS_NEEDED) $(LIBS)
libsa.a: $(SA_OBJS)
- rm -f $(SYMROOT)/libsa.a
- ar q $(SYMROOT)/libsa.a $(SA_OBJS)
- ranlib $(SYMROOT)/libsa.a
+ rm -f $(SYMROOT)/$(@F)
+ ar q $(SYMROOT)/$(@F) $^
+ ranlib $(SYMROOT)/$(@F)
clean::
rm -rf $(SYMROOT)/libsa.a $(SYMROOT)/libsaio.a
installhdrs:: $(INSTALL_SA_DIR) $(INSTALL_MD_DIR)
cp $(INSTALLED_SA_HFILES) $(INSTALL_SA_DIR)
- cp $(INSTALLED_MD_HFILES) $(INSTALL_MD_DIR)
include ../MakeInc.dir