Permalink
Browse files

Update lisp install

Removed two bug work-arounds because associated
sbcl bug has been fixed.
  • Loading branch information...
1 parent ed054cc commit 620c09176c120a87b7acd531395d2472da00d1fb @bvds committed Dec 17, 2013
@@ -16,74 +16,84 @@ ifeq ($(shell uname),Darwin)
ifeq ($(shell uname -p),powerpc)
binary-release = sbcl-1.0.47-powerpc-darwin-binary.tar.bz2
endif
+ifeq ($(shell uname -m),x86_64)
+ binary-release = sbcl-1.1.8-x86-64-darwin-binary.tar.bz2
+ binary-dir = sbcl-1.1.8-x86-64-darwin
+else
ifeq ($(shell uname -p),i386)
binary-release = sbcl-1.0.55-x86-darwin-binary.tar.bz2
# work-around for bug in make-config.sh which guesses the wrong platform
# on OSX 10.4.11, MacBook Pro.
platform = SBCL_ARCH=x86; export SBCL_ARCH;
endif
-ifeq ($(shell uname -p),x86_64)
- binary-release = sbcl-1.0.55-x86-64-darwin-binary.tar.bz2
endif
endif
ifeq ($(shell uname),Linux)
ifeq ($(shell uname -p),i686)
- binary-release = sbcl-1.0.55-x86-linux-binary.tar.bz2
+ binary-release = sbcl-1.0.58-x86-linux-binary.tar.bz2
+ binary-dir = sbcl-1.0.58-x86-linux
endif
ifeq ($(shell uname -m),i686)
- binary-release = sbcl-1.0.55-x86-linux-binary.tar.bz2
+ binary-release = sbcl-1.0.58-x86-linux-binary.tar.bz2
+ binary-dir = sbcl-1.0.58-x86-linux
endif
ifeq ($(shell uname -p),pentium4) # Andrew linux at CMU
- binary-release = sbcl-1.0.55-x86-linux-binary.tar.bz2
+ binary-release = sbcl-1.0.58-x86-linux-binary.tar.bz2
+ binary-dir = sbcl-1.0.58-x86-linux
endif
ifeq ($(shell uname -p),x86_64)
- binary-release = sbcl-1.0.55-x86-64-linux-binary.tar.bz2
+ binary-release = sbcl-1.1.14-x86-64-linux-binary.tar.bz2
+ binary-dir = sbcl-1.1.14-x86-64-linux
endif
ifeq ($(shell uname -m),x86_64)
- binary-release = sbcl-1.0.55-x86-64-linux-binary.tar.bz2
+ binary-release = sbcl-1.1.14-x86-64-linux-binary.tar.bz2
+ binary-dir = sbcl-1.1.14-x86-64-linux
endif
endif
ifndef binary-release
$(error "Unknown architecture")
endif
-binary-dir = head -n 1 lisp-binary-dir-files|grep -o "^[^/]*"
# RedHat custom wget returns an error if file exists
get-binary:
- -wget -nc http://downloads.sourceforge.net/sbcl/$(binary-release)
- tar jxvf $(binary-release) > lisp-binary-dir-files
- @echo "changing to directory `$(binary-dir)`:"
- cd `$(binary-dir)`; chmod u+x run-sbcl.sh
+ifeq ($(shell uname),Darwin)
+ -curl -L http://prdownloads.sourceforge.net/sbcl/$(binary-release) -O
+else
+ -wget -nc http://prdownloads.sourceforge.net/sbcl/$(binary-release)
+endif
+ tar jxf $(binary-release)
+ @echo "changing to directory $(binary-dir):"
+ cd $(binary-dir); chmod u+x run-sbcl.sh
# The binary version of sbcl should not be used
# to run the Andes help server. Use the custom version below.
binary-install:
@echo "Needs superuser privileges for install into /usr/local"
- cd `$(binary-dir)`; sh install.sh
+ cd $(binary-dir); sh install.sh
thread-test:
- cd `$(binary-dir)`; echo '(format t "Threading is~:[ not~;~] supported on binary release.~%" (find :sb-thread *features*)) (quit)' | ./run-sbcl.sh --noinform --noprint
+ cd $(binary-dir); echo '(format t "Threading is~:[ not~;~] supported on binary release.~%" (find :sb-thread *features*)) (quit)' | ./run-sbcl.sh --noinform --noprint
-source-dir = sbcl-1.0.55
+source-dir = sbcl-1.1.14
source-release = $(source-dir)-source.tar.bz2
get-source:
+ifeq ($(shell uname),Darwin)
+ -curl -L http://prdownloads.sourceforge.net/sbcl/$(source-release) -O
+else
-wget -nc http://prdownloads.sourceforge.net/sbcl/$(source-release)
+endif
tar jxf $(source-release)
# enable thread support (for OS X) and :sb-hash-table-debug
cp customize-target-features.lisp $(source-dir)
+ # Use "diff -u old-file new-file" to create patch
patch -p 1 -d $(source-dir) < backend-parms.lisp-x86-1.0.55-patch
- patch -p 1 -d $(source-dir) < backend-parms.lisp-x86_64-1.0.55-patch
+ patch -p 1 -d $(source-dir) < backend-parms.lisp-x86_64-1.1.14-patch
patch -p 1 -d $(source-dir) < parms.lisp-1.0.55-patch
- # See https://bugs.launchpad.net/sbcl/+bug/720940
- patch -p 1 -d $(source-dir) < sb-introspect-1.0.55-patch
- # Won't compile on OS X 10.4.11
- # See https://bugs.launchpad.net/sbcl/+bug/957385
- cp unix-foreign-load.lisp $(source-dir)/src/code/
ifdef INSTALL_ROOT
- $(platform) cd $(source-dir); sh make.sh --prefix ${INSTALL_ROOT} $(shell echo "../`$(binary-dir)`/run-sbcl.sh")
+ $(platform) cd $(source-dir); sh make.sh --prefix ${INSTALL_ROOT} $(shell echo "../$(binary-dir)/run-sbcl.sh")
@echo "Install directory ${INSTALL_ROOT}"
else
- $(platform) cd $(source-dir); sh make.sh $(shell echo "../`$(binary-dir)`/run-sbcl.sh")
+ $(platform) cd $(source-dir); sh make.sh $(shell echo "../$(binary-dir)/run-sbcl.sh")
endif
ifdef SUDO_USER
@@ -113,7 +123,11 @@ sbclrc: quicklisp.lisp
cat sbclrc-sample-end >> ~/.sbclrc
quicklisp.lisp:
+ifeq ($(shell uname),Darwin)
+ curl -L http://beta.quicklisp.org/quicklisp.lisp -O
+else
wget -nc http://beta.quicklisp.org/quicklisp.lisp
+endif
# A good version test is to see if sbcl is using ASDF version 2.
update:
@@ -1,8 +0,0 @@
---- sbcl-1.0.55/src/compiler/x86-64/backend-parms.lisp-original 2012-03-07 12:33:10.000000000 -0700
-+++ sbcl-1.0.55/src/compiler/x86-64/backend-parms.lisp 2012-03-07 12:32:48.000000000 -0700
-@@ -46,4 +46,4 @@
- (def!constant gencgc-alloc-granularity 0)
- ;;; The minimum size at which we release address ranges to the OS.
- ;;; This must be a multiple of the OS page size.
--(def!constant gencgc-release-granularity *backend-page-bytes*)
-+(def!constant gencgc-release-granularity (* 8 *backend-page-bytes*))
@@ -1,11 +0,0 @@
---- sbcl-1.0.55/contrib/sb-introspect/test-driver.lisp-original 2012-03-07 12:37:03.000000000 -0700
-+++ sbcl-1.0.55/contrib/sb-introspect/test-driver.lisp 2012-03-07 12:37:26.000000000 -0700
-@@ -300,7 +300,7 @@
- (tai #'cons :heap
- ;; FIXME: This is the canonical GENCGC result. On PPC we sometimes get
- ;; :LARGE T, which doesn't seem right -- but ignore that for now.
-- '(:space :dynamic :generation 6 :write-protected t :boxed t :pinned nil :large nil)
-+ `(:space :dynamic :generation ,sb-vm:+pseudo-static-generation+ :write-protected t :boxed t :pinned nil :large nil)
- :ignore (list :page #+ppc :large))
- #-gencgc
- (tai :cons :heap
@@ -1,85 +0,0 @@
-;;;; Loading shared object files, Unix specifics
-
-;;;; 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.
-
-(in-package "SB!ALIEN")
-
-(define-alien-routine dlopen system-area-pointer
- (file c-string) (mode int))
-
-(define-alien-routine dlclose int
- (handle system-area-pointer))
-
-(define-alien-routine dlerror c-string)
-
-(define-alien-routine
- #!-openbsd dlsym
- #!+openbsd ("os_dlsym" dlsym)
- system-area-pointer
- (handle system-area-pointer)
- (symbol c-string))
-
-(defun dlopen-or-lose (&optional (obj nil objp))
- (when objp
- (dlclose-or-lose obj))
- (dlerror) ; clear errors
- (let* ((namestring (and obj (shared-object-namestring obj)))
- (sap (dlopen namestring (logior rtld-global rtld-now))))
- (when (zerop (sap-int sap))
- (if objp
- (setf (shared-object-handle obj) nil)
- (setf *runtime-dlhandle* nil))
- (error "Error opening ~:[runtime~;shared object ~:*~S~]:~% ~A."
- namestring (dlerror)))
- (when objp
- (setf (shared-object-handle obj) sap))
- sap))
-
-(defun dlclose-or-lose (&optional (obj nil objp))
- (dlerror)
- (let (dlerror)
- (cond ((and (not objp) *runtime-dlhandle*)
- ;; CLH: if we're on darwin/ppc we can't close
- ;; *runtime-dlhandle* for some reason, so don't.
- #!-darwin
- (dlclose *runtime-dlhandle*)
- (setf dlerror (dlerror)
- *runtime-dlhandle* nil))
- ((and objp (shared-object-handle obj))
- (dlclose (shared-object-handle obj))
- (setf dlerror (dlerror)
- (shared-object-handle obj) nil)))
- (when dlerror
- (cerror "Ignore the error and continue as if closing succeeded."
- "dlerror() returned an error while trying to close ~
- ~:[runtime~;shared object ~:*~S~]: ~S"
- (when obj (shared-object-namestring obj))
- dlerror))))
-
-(defun find-dynamic-foreign-symbol-address (symbol)
- (dlerror) ; clear old errors
- (unless *runtime-dlhandle*
- (bug "Cannot resolve foreign symbol: lost *runtime-dlhandle*"))
- ;; On real ELF & dlsym platforms the EXTERN-ALIEN-NAME is a no-op,
- ;; but on platforms where dlsym is simulated we use the mangled name.
- (let* ((extern (extern-alien-name symbol))
- (result (sap-int (dlsym *runtime-dlhandle* extern)))
- (err (dlerror)))
- (if (or (not (zerop result)) (not err))
- result
- (dolist (obj *shared-objects*)
- (let ((sap (shared-object-handle obj)))
- (when sap
- (setf result (sap-int (dlsym sap extern))
- err (dlerror))
- (when (or (not (zerop result)) (not err))
- (return result))))))))
-
-

0 comments on commit 620c091

Please sign in to comment.