tidied up OpenBSD-vs.-FreeBSD stuff, and src/runtime/Config.x86-*
authorWilliam Harold Newman <william.newman@airmail.net>
Mon, 2 Oct 2000 17:27:10 +0000 (17:27 +0000)
committerWilliam Harold Newman <william.newman@airmail.net>
Mon, 2 Oct 2000 17:27:10 +0000 (17:27 +0000)
make-config.sh
src/cold/warm.lisp
src/runtime/Config.x86-bsd
src/runtime/Config.x86-freebsd [new file with mode: 0644]
src/runtime/Config.x86-linux
src/runtime/Config.x86-openbsd [new file with mode: 0644]
src/runtime/GNUmakefile
version.lisp-expr

index 3b112dd..85eaea1 100644 (file)
@@ -46,26 +46,29 @@ for d in src/compiler src/assembly; do
 done
 
 echo //setting up OS-dependent information
+original_dir=`pwd`
 cd src/runtime/
 rm -f Config
 if [ `uname` = Linux ]; then
     echo -n ' :linux' >> $ltf
     ln -s Config.x86-linux Config
 elif uname | grep BSD; then
+    echo -n ' :bsd' >> $ltf
     if [ `uname` = FreeBSD ]; then
        echo -n ' :freebsd' >> $ltf
+       ln -s Config.x86-freebsd Config
     elif [ `uname` = OpenBSD ]; then
        echo -n ' :openbsd' >> $ltf
+       ln -s Config.x86-openbsd Config
     else
        echo unsupported BSD variant: `uname`
        exit 1
     fi
-    echo -n ' :bsd' >> $ltf
-    ln -s Config.x86-bsd Config
 else
     echo unsupported OS type: `uname`
     exit 1
 fi
+cd $original_dir
 
 echo //finishing $ltf
 echo ')' >> $ltf
index 566fd7e..8efbc69 100644 (file)
                "src/code/inspect" ; FIXME: should be byte compiled
                "src/code/profile"
                "src/code/ntrace"
-               #+nil ; REMOVEME (for debugging 0.6.7.6 on OpenBSD only)
                "src/code/foreign"
-               #+nil ; REMOVEME (for debugging 0.6.7.6 on OpenBSD only)
                "src/code/run-program"
                ;; Code derived from PCL's pre-ANSI DESCRIBE-OBJECT
                ;; facility is still used in our ANSI DESCRIBE
index 8017592..642c8d5 100644 (file)
@@ -1,25 +1,7 @@
-CPPFLAGS = -I.
-
-CC = gcc -Wstrict-prototypes -fno-strength-reduce # -Wall
-LD = ld
-CPP = cpp
-CFLAGS =  -g -O2 -DGENCGC -DPOSIX_SIGS
-ASFLAGS = -g -DGENCGC
-LINKFLAGS = -g
-NM = nm -gp
+# stuff shared between various *BSD OSes 
 
 ASSEM_SRC = x86-assem.S 
 ARCH_SRC = x86-arch.c
 
 OS_SRC = bsd-os.c os-common.c undefineds.c
-# Until version 0.6.7.3, we used "OS_LINK_FLAGS=-static" here, which
-# worked fine for most things, but LOAD-FOREIGN & friends require
-# dlopen() etc., which in turn depend on dynamic linking of the
-# runtime.
-#for OpenBSD:
-OS_LINK_FLAGS=-static
-#for FreeBSD:
-#OS_LINK_FLAGS=-dynamic -export-dynamic
 OS_LIBS=-lm # -ldl
-
-GC_SRC= gencgc.c
diff --git a/src/runtime/Config.x86-freebsd b/src/runtime/Config.x86-freebsd
new file mode 100644 (file)
index 0000000..149a999
--- /dev/null
@@ -0,0 +1,7 @@
+include Config.x86-bsd
+
+# Until sbcl-0.6.7.3, we used "OS_LINK_FLAGS=-static" here, which
+# worked fine for most things, but LOAD-FOREIGN & friends require
+# dlopen() etc., which in turn depend on dynamic linking of the
+# runtime.
+OS_LINK_FLAGS = -dynamic -export-dynamic
index ce7bf1f..13784ff 100644 (file)
@@ -1,18 +1,8 @@
-CPPFLAGS = -I.
-
-CC = gcc -Wstrict-prototypes -O2 -fno-strength-reduce # -Wall
-LD = ld
-CPP = cpp
-CFLAGS =  -g -O2 -DGENCGC
-ASFLAGS = -g -DGENCGC
-LINKFLAGS = -g
-NM = nm -p
-
 ASSEM_SRC = x86-assem.S linux-stubs.S
 ARCH_SRC = x86-arch.c
 
 OS_SRC = linux-os.c os-common.c
-OS_LINK_FLAGS=
-OS_LIBS= -ldl
+OS_LINK_FLAGS =
+OS_LIBS = -ldl
 
 GC_SRC= gencgc.c
diff --git a/src/runtime/Config.x86-openbsd b/src/runtime/Config.x86-openbsd
new file mode 100644 (file)
index 0000000..98384cd
--- /dev/null
@@ -0,0 +1,10 @@
+include Config.x86-bsd
+
+# KLUDGE: It might seem as though dynamic libraries should work the
+# same way on both systems, but in fact gcc supports the "-export-dynamic"
+# option on FreeBSD but not on OpenBSD. The documentation I've been
+# able to find doesn't seem to begin to explain what's going on (e.g. I
+# have never found documentation for the "-export-dynamic" option),
+# so I've just punted and left link flags for OpenBSD in their
+# pre-dynamic-library-support state. -- WHN 2000-10-02
+OS_LINK_FLAGS = -static
index 9f96cd5..fcd391b 100644 (file)
 all: sbcl sbcl.nm
 .PHONY: all
 
-# defaults which might be overridden by values in the Config file
-CC = gcc
+# defaults which might be overridden or modified by values in the
+# Config file
+#
+# FIXME: The -fno-strength-reduce flag comes from before the fork
+# from CMU CL. It's presumably to work around some optimizer bug in gcc,
+# but the fork was a long time ago, and the optimizer could easily
+# have been fixed since then. Try doing without it.
+CFLAGS =  -g -Wall -O2 -fno-strength-reduce -DGENCGC
+ASFLAGS = -g -DGENCGC
 DEPEND_FLAGS =
+CPPFLAGS = -I.
 
 # The Config file is the preferred place for tweaking options which
-# are appropriate for particular setups (OS, CPU, whatever). Make
-# a Config-foo file for setup foo, then set Config to be a symlink
-# to Config-foo.
+# are appropriate for particular setups (OS, CPU, whatever). Make a
+# Config-foo file for setup foo, then arrange for Config to be a
+# symlink to Config-foo.
 include Config
 
+# Some of these things might be Config-dependent in future versions,
+# but they're not right now, i.e., they happen to be the same for
+# all supported systems.
+CPP = cpp
+GC_SRC = gencgc.c
+LD = ld
+LINKFLAGS = -g
+NM = nm -gp
+
 SRCS = alloc.c backtrace.c breakpoint.c coreparse.c \
        dynbind.c globals.c interr.c interrupt.c \
        monitor.c parse.c print.c purify.c \
index f08e56a..eae71cb 100644 (file)
@@ -15,4 +15,4 @@
 ;;; versions, and a string a la "0.6.5.12" is used for versions which
 ;;; aren't released but correspond only to CVS tags or snapshots.
 
-"0.6.7.6"
+"0.6.7.7"