X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2FConfig.ppc-darwin;h=c7d0dec626a0e42268f68ef49251afce767e8271;hb=88cc2f72774202503588331fddd1592ae8546de1;hp=a208c5d11f9758fbcff1cd037bd3a572b8b28fa6;hpb=b7cfa0e5e726c2037ba2c6cb32406ff7e9764dd2;p=sbcl.git diff --git a/src/runtime/Config.ppc-darwin b/src/runtime/Config.ppc-darwin index a208c5d..c7d0dec 100644 --- a/src/runtime/Config.ppc-darwin +++ b/src/runtime/Config.ppc-darwin @@ -1,17 +1,58 @@ -# -*- makefile -*- -CFLAGS = -DDARWIN -Dppc -g -Wall -O3 -no-cpp-precomp -OS_SRC = bsd-os.c os-common.c ppc-darwin-os.c ppc-darwin-dlshim.c -OS_LIBS = -lSystem -lc -lm +# -*- makefile -*- for the C-level run-time support for SBCL -# Avoid the dreaded gcc 3.3 prerelease tarpit of death! -CC = gcc3 +# This software is part of the SBCL system. See the README file for +# more information. +# +# This software is derived from the CMU CL system, which was +# written at Carnegie Mellon University and released into the +# public domain. The software is in the public domain and is +# provided with absolutely no warranty. See the COPYING and CREDITS +# files for more information. + +CFLAGS = -g -Wall -O2 -fdollars-in-identifiers +OS_SRC = bsd-os.c darwin-os.c ppc-darwin-os.c ppc-darwin-dlshim.c ppc-darwin-langinfo.c +OS_LIBS = -lSystem -lc +OS_OBJS = ppc-darwin-rospace.o + +CC = gcc ASSEM_SRC = ppc-assem.S ldso-stubs.S ARCH_SRC = ppc-arch.c -CPP = cpp -no-cpp-precomp +CPPFLAGS += -no-cpp-precomp + +# KLUDGE: in OS X 10.3, Apple started putting the heap right where we +# expect our read-only space mapped. This hack causes the linker to +# place a zero-fill-on-demand segment in the same place and size as +# read-only-space, which is the only thing capable of keeping malloc +# out of this range. +LINKFLAGS += -dynamic `cat ppc-darwin-link-flags` -twolevel_namespace -bind_at_load + +GC_SRC = $(shell if grep LISP_FEATURE_GENCGC genesis/config.h \ + > /dev/null 2>&1; \ + then echo "gencgc.c"; \ + else echo "cheneygc.c" ; fi) + +OS_CLEAN_FILES += ppc-darwin-mkrospace ppc-darwin-fix-rospace ppc-darwin-link-flags + +ppc-darwin-mkrospace: ppc-darwin-mkrospace.c + $(CC) -g -Wall -pedantic -o $@ $< + +ppc-darwin-fix-rospace: ppc-darwin-fix-rospace.c + $(CC) -g -Wall -pedantic -o $@ $< + +ppc-darwin-rospace.o ppc-darwin-link-flags: ppc-darwin-mkrospace + ./ppc-darwin-mkrospace > ppc-darwin-link-flags -OS_LINK_FLAGS = -dynamic -L$(HOME)/local/lib -L/sw/lib -L/opt/local/lib -L/usr/local/lib +.PHONY: after-grovel-headers -GC_SRC= cheneygc.c +# Fix the sbcl runtime to avoid Panther placing the heap where +# it wants read only space (in the first 32 megabytes, where it +# can be absolute-branched to with BA.) Must be done after +# grovel-headers, because Apple's nm is broken. +after-grovel-headers: ppc-darwin-fix-rospace + ./ppc-darwin-fix-rospace +# Fortunatly make-target-1.sh does a make clean all the time. +# Otherwise we would have to make sure that sbcl gets rebuilt without +# the readonlyspace hack before groveling headers again.