summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrey Grozin <grozin@gentoo.org>2011-04-28 20:21:33 +0000
committerAndrey Grozin <grozin@gentoo.org>2011-04-28 20:21:33 +0000
commitc45805bd11a22913b5c811478e235a52a8b73832 (patch)
treecdc7912ac9451ba2698f70df533775d3adff6bbe /dev-lisp
parent[media-libs/herqq] added multilib support (fixes bug #365155) (diff)
downloadgentoo-2-c45805bd11a22913b5c811478e235a52a8b73832.tar.gz
gentoo-2-c45805bd11a22913b5c811478e235a52a8b73832.tar.bz2
gentoo-2-c45805bd11a22913b5c811478e235a52a8b73832.zip
Version bump from the lisp overlay
(Portage version: 2.2.0_alpha30/cvs/Linux i686)
Diffstat (limited to 'dev-lisp')
-rw-r--r--dev-lisp/cmucl/ChangeLog13
-rw-r--r--dev-lisp/cmucl/cmucl-20b_p001.ebuild89
-rw-r--r--dev-lisp/cmucl/files/20b-customize-lisp-implementation-version.patch16
-rw-r--r--dev-lisp/cmucl/files/20b-execstack-fixes.patch118
-rw-r--r--dev-lisp/cmucl/files/20b-nositeinit-build.patch18
-rw-r--r--dev-lisp/cmucl/files/20b-patch001.patch119
-rw-r--r--dev-lisp/cmucl/files/site-init.lisp.in4
-rw-r--r--dev-lisp/cmucl/metadata.xml5
8 files changed, 376 insertions, 6 deletions
diff --git a/dev-lisp/cmucl/ChangeLog b/dev-lisp/cmucl/ChangeLog
index 4063600242d9..bce9d164c9c1 100644
--- a/dev-lisp/cmucl/ChangeLog
+++ b/dev-lisp/cmucl/ChangeLog
@@ -1,6 +1,15 @@
# ChangeLog for dev-lisp/cmucl
-# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lisp/cmucl/ChangeLog,v 1.35 2010/12/17 20:17:43 ulm Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lisp/cmucl/ChangeLog,v 1.36 2011/04/28 20:21:33 grozin Exp $
+
+*cmucl-20b_p001 (29 Apr 2011)
+
+ 29 Apr 2011; Andrey Grozin <grozin@gentoo.org>
+ +files/20b-customize-lisp-implementation-version.patch,
+ +cmucl-20b_p001.ebuild, +files/20b-execstack-fixes.patch,
+ +files/20b-nositeinit-build.patch, +files/20b-patch001.patch,
+ files/site-init.lisp.in, metadata.xml:
+ Version bump from the lisp overlay
17 Dec 2010; Ulrich Mueller <ulm@gentoo.org> cmucl-19c.ebuild,
cmucl-19d_p2.ebuild, cmucl-20a.ebuild:
diff --git a/dev-lisp/cmucl/cmucl-20b_p001.ebuild b/dev-lisp/cmucl/cmucl-20b_p001.ebuild
new file mode 100644
index 000000000000..b4c2a53f7658
--- /dev/null
+++ b/dev-lisp/cmucl/cmucl-20b_p001.ebuild
@@ -0,0 +1,89 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lisp/cmucl/cmucl-20b_p001.ebuild,v 1.1 2011/04/28 20:21:33 grozin Exp $
+
+EAPI=3
+inherit eutils toolchain-funcs
+
+MY_PV=${PV:0:3}
+
+DESCRIPTION="CMU Common Lisp is an implementation of ANSI Common Lisp"
+HOMEPAGE="http://www.cons.org/cmucl/"
+SRC_URI="http://common-lisp.net/project/cmucl/downloads/release/${MY_PV}/cmucl-src-${MY_PV}.tar.bz2
+ http://common-lisp.net/project/cmucl/downloads/release/${MY_PV}/cmucl-${MY_PV}-x86-linux.tar.bz2"
+
+LICENSE="public-domain"
+SLOT="0"
+KEYWORDS="~x86"
+IUSE="X source sse2"
+
+RDEPEND="x11-libs/openmotif"
+DEPEND="${RDEPEND}
+ sys-devel/bc"
+PDEPEND="dev-lisp/gentoo-init"
+
+S="${WORKDIR}"
+
+# glo_usev flagname [<if_yes> [<if_no>]]
+# If $(use FLAGNAME) return true, echo IF_YES to standard output,
+# otherwise echo IF_NO. IF_YES defaults to FLAGNAME if not specified
+glo_usev() {
+ if [[ $# < 1 || $# > 3 ]]; then
+ echo "Usage: ${0} flag [if_yes [if_no]]"
+ die "${0}: wrong number of arguments: $#"
+ fi
+ local if_yes="${2:-${1}}" if_no="${3}"
+ if useq ${1} ; then
+ printf "%s" "${if_yes}"
+ return 0
+ else
+ printf "%s" "${if_no}"
+ return 1
+ fi
+}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${MY_PV}-patch001.patch
+ epatch "${FILESDIR}"/fix-man-and-doc-installation.patch
+ epatch "${FILESDIR}"/${MY_PV}-execstack-fixes.patch
+ epatch "${FILESDIR}"/${MY_PV}-customize-lisp-implementation-version.patch
+ epatch "${FILESDIR}"/${MY_PV}-nositeinit-build.patch
+}
+
+src_compile() {
+ local cmufpu=$(glo_usev sse2 sse2 x87)
+ local cmuopts="$(glo_usev !X -u) -f ${cmufpu}"
+ local buildimage="bin/lisp -core lib/cmucl/lib/lisp-${cmufpu}.core -noinit -nositeinit -batch"
+ env CC="$(tc-getCC)" src/tools/build.sh -v "-gentoo-${PR}" -C "" -o "${buildimage}" ${cmuopts} || die "Cannot build the compiler"
+}
+
+src_install() {
+ env MANDIR=share/man/man1 DOCDIR=share/doc/${PF} \
+ src/tools/make-dist.sh -S -g -G root -O root build-4 ${MY_PV} x86 linux \
+ || die "Cannot build installation archive"
+ # Necessary otherwise tar will fail
+ dodir /usr
+ pushd "${D}"/usr
+ tar xzpf "${WORKDIR}"/cmucl-${MY_PV}-x86-linux.tar.gz \
+ || die "Cannot install main system"
+ if use X ; then
+ tar xzpf "${WORKDIR}"/cmucl-${MY_PV}-x86-linux.extra.tar.gz \
+ || die "Cannot install extra files"
+ fi
+ if use source; then
+ # Necessary otherwise tar will fail
+ dodir /usr/share/common-lisp/source/${PN}
+ cd "${D}"/usr/share/common-lisp/source/${PN}
+ tar --strip-components 1 -xzpf "${WORKDIR}"/cmucl-src-${MY_PV}.tar.gz \
+ || die "Cannot install sources"
+ fi
+ popd
+
+ # Install site config file
+ sed "s,@PF@,${PF},g ; s,@VERSION@,$(date +%F),g" \
+ < "${FILESDIR}"/site-init.lisp.in \
+ > "${D}"/usr/$(get_libdir)/cmucl/site-init.lisp \
+ || die "Cannot fix site-init.lisp"
+ insinto /etc
+ doins "${FILESDIR}"/cmuclrc || die "Failed to install cmuclrc"
+}
diff --git a/dev-lisp/cmucl/files/20b-customize-lisp-implementation-version.patch b/dev-lisp/cmucl/files/20b-customize-lisp-implementation-version.patch
new file mode 100644
index 000000000000..41da86d014ff
--- /dev/null
+++ b/dev-lisp/cmucl/files/20b-customize-lisp-implementation-version.patch
@@ -0,0 +1,16 @@
+diff -ur cmucl.orig/src/code/misc.lisp cmucl/src/code/misc.lisp
+--- cmucl.orig/src/code/misc.lisp 2010-04-20 19:57:45.000000000 +0200
++++ cmucl/src/code/misc.lisp 2010-10-15 02:15:53.064623104 +0200
+@@ -181,8 +181,10 @@
+
+ (defun lisp-implementation-version ()
+ "Returns a string describing the implementation version."
+- (format nil "~A (~X~A)" *lisp-implementation-version* c:byte-fasl-file-version
+- #+unicode (intl:gettext " Unicode") #-unicode ""))
++ (format nil "~X~A~A"
++ c:byte-fasl-file-version
++ #+unicode "-unicode" #-unicode ""
++ *lisp-implementation-version*))
+
+ (defun machine-instance ()
+ "Returns a string giving the name of the local machine."
diff --git a/dev-lisp/cmucl/files/20b-execstack-fixes.patch b/dev-lisp/cmucl/files/20b-execstack-fixes.patch
new file mode 100644
index 000000000000..034848d64a26
--- /dev/null
+++ b/dev-lisp/cmucl/files/20b-execstack-fixes.patch
@@ -0,0 +1,118 @@
+diff -Naur work.old/src/lisp/alpha-assem.S work/src/lisp/alpha-assem.S
+--- work.old/src/lisp/alpha-assem.S 2003-03-06 11:13:09.000000000 -0300
++++ work/src/lisp/alpha-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -297,3 +297,7 @@
+ function_end_breakpoint_end:
+
+
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/amd64-assem.S work/src/lisp/amd64-assem.S
+--- work.old/src/lisp/amd64-assem.S 2004-07-27 19:03:53.000000000 -0300
++++ work/src/lisp/amd64-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -1051,3 +1051,7 @@
+ .end
+
+ #endif /* LINKAGE_TABLE */
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/backtrace.c work/src/lisp/backtrace.c
+--- work.old/src/lisp/backtrace.c 2009-06-11 13:04:01.000000000 -0300
++++ work/src/lisp/backtrace.c 2010-05-10 00:06:22.000000000 -0300
+@@ -3,6 +3,8 @@
+ * Simple backtrace facility. More or less from Rob's lisp version.
+ */
+
++#include "os-common.h"
++
+ #include <stdio.h>
+ #include <signal.h>
+ #include "lisp.h"
+diff -Naur work.old/src/lisp/hppa-assem.S work/src/lisp/hppa-assem.S
+--- work.old/src/lisp/hppa-assem.S 2002-08-23 14:05:35.000000000 -0300
++++ work/src/lisp/hppa-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -460,3 +460,7 @@
+
+ .export function_end_breakpoint_end
+ function_end_breakpoint_end
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/linux-stubs.S work/src/lisp/linux-stubs.S
+--- work.old/src/lisp/linux-stubs.S 2005-08-17 00:40:16.000000000 -0300
++++ work/src/lisp/linux-stubs.S 2010-05-10 00:06:34.000000000 -0300
+@@ -995,3 +995,7 @@
+ /* doe(yperr_string) */
+ /* doe(ypprot_err) */
+ #endif /* defined(LINKAGE_TABLE) && !defined(__FreeBSD__) */
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/lisp.c work/src/lisp/lisp.c
+--- work.old/src/lisp/lisp.c 2009-07-13 16:41:54.000000000 -0300
++++ work/src/lisp/lisp.c 2010-05-10 00:05:55.000000000 -0300
+@@ -5,6 +5,9 @@
+ *
+ */
+
++#include "os-common.h"
++#include <time.h>
++
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <limits.h>
+diff -Naur work.old/src/lisp/mips-assem.S work/src/lisp/mips-assem.S
+--- work.old/src/lisp/mips-assem.S 2002-08-23 14:01:02.000000000 -0300
++++ work/src/lisp/mips-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -402,3 +402,7 @@
+ move v0, a1
+ j _restore_state
+ .end save_state
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/os-common.h work/src/lisp/os-common.h
+--- work.old/src/lisp/os-common.h 1969-12-31 21:00:00.000000000 -0300
++++ work/src/lisp/os-common.h 2010-05-10 00:06:22.000000000 -0300
+@@ -0,0 +1 @@
++char* convert_lisp_string(char *c_string, void *lisp_string, int len);
+diff -Naur work.old/src/lisp/ppc-assem.S work/src/lisp/ppc-assem.S
+--- work.old/src/lisp/ppc-assem.S 2006-02-25 01:35:58.000000000 -0300
++++ work/src/lisp/ppc-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -721,3 +721,7 @@
+ SET_SIZE(fpu_restore)
+
+ #endif
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/sparc-assem.S work/src/lisp/sparc-assem.S
+--- work.old/src/lisp/sparc-assem.S 2003-10-23 23:57:00.000000000 -0300
++++ work/src/lisp/sparc-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -837,3 +837,7 @@
+ * End:
+ */
+
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
+diff -Naur work.old/src/lisp/x86-assem.S work/src/lisp/x86-assem.S
+--- work.old/src/lisp/x86-assem.S 2008-12-24 02:36:40.000000000 -0200
++++ work/src/lisp/x86-assem.S 2010-05-10 00:06:34.000000000 -0300
+@@ -798,3 +798,7 @@
+ ENDFUNC(undefined_foreign_symbol_trap)
+
+ #endif /* LINKAGE_TABLE */
++
++#if defined(__linux__) && defined(__ELF__)
++.section .note.GNU-stack,"",%progbits
++#endif
diff --git a/dev-lisp/cmucl/files/20b-nositeinit-build.patch b/dev-lisp/cmucl/files/20b-nositeinit-build.patch
new file mode 100644
index 000000000000..3aea006d159d
--- /dev/null
+++ b/dev-lisp/cmucl/files/20b-nositeinit-build.patch
@@ -0,0 +1,18 @@
+Author: Stelian Ionescu <sionescu@cddr.org>
+Date: 2010-11-03
+Status: Upstream
+Description: Avoids loading the site init during build
+
+diff -ur cmucl.orig//src/tools/build.sh cmucl/src/tools/build.sh
+--- cmucl.orig//src/tools/build.sh 2010-09-02 18:16:18.000000000 +0200
++++ cmucl/src/tools/build.sh 2010-11-03 15:57:06.615611658 +0100
+@@ -126,7 +126,8 @@
+ fi
+ $TOOLDIR/load-world.sh $TARGET "$VERSION" || { echo "Failed: $TOOLDIR/load-world.sh"; exit 1; }
+
+- $TARGET/lisp/lisp -batch -noinit $FPU_MODE < /dev/null || { echo "Failed: $TARGET/lisp/lisp -batch -noinit $FPU_MODE"; exit 1; }
++ $TARGET/lisp/lisp -batch -noinit -nositeinit $FPU_MODE < /dev/null || \
++ { echo "Failed: $TARGET/lisp/lisp -batch -noinit $FPU_MODE"; exit 1; }
+ return 0;
+ fi
+ }
diff --git a/dev-lisp/cmucl/files/20b-patch001.patch b/dev-lisp/cmucl/files/20b-patch001.patch
new file mode 100644
index 000000000000..f9464221e365
--- /dev/null
+++ b/dev-lisp/cmucl/files/20b-patch001.patch
@@ -0,0 +1,119 @@
+Author: Raymond Toy <rtoy@common-lisp.net>
+Date: 2010-11-02
+Status: Upstream
+Description: Fixes bug in SSE2 VOP for COMPLEX arrays
+
+diff -ru cmucl.orig//src/compiler/x86/float-sse2.lisp cmucl/src/compiler/x86/float-sse2.lisp
+--- cmucl.orig//src/compiler/x86/float-sse2.lisp 2010-08-15 17:09:41.000000000 +0200
++++ cmucl/src/compiler/x86/float-sse2.lisp 2010-11-01 13:41:54.860889371 +0100
+@@ -7,7 +7,7 @@
+ ;;; Scott Fahlman or slisp-group@cs.cmu.edu.
+ ;;;
+ (ext:file-comment
+- "$Header: /var/cvsroot/gentoo-x86/dev-lisp/cmucl/files/20b-patch001.patch,v 1.1 2011/04/28 20:21:33 grozin Exp $")
++ "$Header: /var/cvsroot/gentoo-x86/dev-lisp/cmucl/files/20b-patch001.patch,v 1.1 2011/04/28 20:21:33 grozin Exp $")
+ ;;;
+ ;;; **********************************************************************
+ ;;;
+@@ -1390,13 +1390,19 @@
+ (:arg-types complex-single-float)
+ (:results (r :scs (single-reg)))
+ (:result-types single-float)
++ (:temporary (:sc single-reg) temp)
+ (:policy :fast-safe)
+ (:note _N"complex float realpart")
+ (:generator 3
+ (sc-case x
+ (complex-single-reg
+- (inst xorps r r) ; temp = 0|0|0|0
+- (inst movss r x)) ; r = 0|0|0|x
++ (cond ((location= r x)
++ (inst xorps temp temp) ; temp = 0|0|0|0
++ (inst movss temp x) ; temp = 0|0|0|x
++ (inst movss r temp)) ; r = temp
++ (t
++ (inst xorps r r) ; temp = 0|0|0|0
++ (inst movss r x)))) ; r = 0|0|0|x
+ (complex-single-stack
+ (inst movss r (ea-for-csf-real-stack x)))
+ (descriptor-reg
+@@ -1408,13 +1414,19 @@
+ (:arg-types complex-double-float)
+ (:results (r :scs (double-reg)))
+ (:result-types double-float)
++ (:temporary (:sc double-reg) temp)
+ (:policy :fast-safe)
+- (:note _N"complex float realpart")
++ (:note "complex float realpart")
+ (:generator 3
+ (sc-case x
+ (complex-double-reg
+- (inst xorpd r r) ; temp = 0|0
+- (inst movsd r x)) ; r = 0|x
++ (cond ((location= r x)
++ (inst xorpd temp temp) ; temp = 0|0
++ (inst movsd temp x) ; temp = 0|x
++ (inst movsd r temp)) ; r = temp
++ (t
++ (inst xorpd r r) ; r = 0|0
++ (inst movsd r x)))) ; r = 0|x
+ (complex-double-stack
+ (inst movsd r (ea-for-cdf-real-stack x)))
+ (descriptor-reg
+@@ -1457,8 +1469,13 @@
+ (:generator 3
+ (sc-case x
+ (complex-double-reg
+- (inst xorpd r r) ; r = 0|0
+- (inst movhlps r x)) ; r = 0|b
++ (cond ((location= r x)
++ (inst xorpd temp temp) ; temp = 0|0
++ (inst movhlps temp x) ; temp = 0|b
++ (inst movsd r temp)) ; r = temp
++ (t
++ (inst xorpd r r) ; r = 0|0
++ (inst movhlps r x)))) ; r = 0|b
+ (complex-double-stack
+ (inst movsd r (ea-for-cdf-imag-stack x)))
+ (descriptor-reg
+@@ -1835,7 +1852,7 @@
+ (convert-complex %complex-single-float cvtpd2ps complex-single complex-double))
+
+ (macrolet
+- ((convert-complex (trans op base-ea to from)
++ ((convert-complex (trans op base-ea to from movinst)
+ (let ((name (symbolicate to "/" from))
+ (from-sc (symbolicate from "-REG"))
+ (from-sc-stack (symbolicate from "-STACK"))
+@@ -1849,21 +1866,27 @@
+ (:arg-types ,from-type)
+ (:results (r :scs (,to-sc)))
+ (:result-types ,to-type)
++ (:temporary (:sc ,to-sc) temp)
+ (:policy :fast-safe)
+ (:generator 1
+ (sc-case x
+ (,from-sc
+ ;; Need to make sure the imaginary part is zero
+- (inst xorps r r)
+- (inst ,op r x))
++ (cond ((location= x r)
++ (inst xorps temp temp)
++ (inst ,op temp x)
++ (inst ,movinst r temp))
++ (t
++ (inst xorps r r)
++ (inst ,op r x))))
+ (,from-sc-stack
+ (inst xorps r r)
+ (inst ,op r (,(symbolicate "EA-FOR-" base-ea "-STACK") x)))
+ (descriptor-reg
+ (inst xorps r r)
+ (inst ,op r (,(symbolicate "EA-FOR-" base-ea "-DESC") x)))))))))
+- (convert-complex %complex-double-float cvtss2sd sf complex-double single)
+- (convert-complex %complex-single-float cvtsd2ss df complex-single double))
++ (convert-complex %complex-double-float cvtss2sd sf complex-double single movapd)
++ (convert-complex %complex-single-float cvtsd2ss df complex-single double movaps))
+
+ ;; Add and subtract for two complex arguments
+ (macrolet
diff --git a/dev-lisp/cmucl/files/site-init.lisp.in b/dev-lisp/cmucl/files/site-init.lisp.in
index 7a1010102003..1b232166c889 100644
--- a/dev-lisp/cmucl/files/site-init.lisp.in
+++ b/dev-lisp/cmucl/files/site-init.lisp.in
@@ -12,10 +12,6 @@
(in-package "SYSTEM")
-(ext:without-package-locks
- (defun lisp-implementation-version ()
- (format nil "~X-~A" c:byte-fasl-file-version "@VERSION@")))
-
(if (probe-file "/etc/cmuclrc")
(load "/etc/cmuclrc")
(format t "~%;;; Warning: There is no /etc/cmuclrc file (which should have been created during emerge"))
diff --git a/dev-lisp/cmucl/metadata.xml b/dev-lisp/cmucl/metadata.xml
index 495851f3f501..87a6440bc0e3 100644
--- a/dev-lisp/cmucl/metadata.xml
+++ b/dev-lisp/cmucl/metadata.xml
@@ -1,6 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
+<maintainer>
+<email>grozin@gentoo.org</email>
+<name>Andrey Grozin</name>
+</maintainer>
<herd>common-lisp</herd>
<longdescription>
CMUCL is a free implementation of the Common Lisp programming language
@@ -28,5 +32,6 @@ ANSI Common Lisp standard. Here is a summary of its main features:
</longdescription>
<use>
<flag name='nosource'>Don't include source code for CMUCL in installation</flag>
+<flag name='source'>Include source code for CMUCL in installation</flag>
</use>
</pkgmetadata>