1 |
commit: 222e649f1623596ab1ccafd246bba566bb2473da |
2 |
Author: Andrey Grozin <grozin <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Jan 30 15:38:47 2020 +0000 |
4 |
Commit: Andrey Grozin <grozin <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Jan 30 15:38:47 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=222e649f |
7 |
|
8 |
dev-lisp/sbcl: bump to 2.0.1 |
9 |
|
10 |
Package-Manager: Portage-2.3.85, Repoman-2.3.20 |
11 |
Signed-off-by: Andrey Grozin <grozin <AT> gentoo.org> |
12 |
|
13 |
dev-lisp/sbcl/Manifest | 2 + |
14 |
dev-lisp/sbcl/files/concurrency-test-2.0.1.patch | 12 ++ |
15 |
dev-lisp/sbcl/sbcl-2.0.1.ebuild | 246 +++++++++++++++++++++++ |
16 |
3 files changed, 260 insertions(+) |
17 |
|
18 |
diff --git a/dev-lisp/sbcl/Manifest b/dev-lisp/sbcl/Manifest |
19 |
index 9430a65a395..e645b4d96f7 100644 |
20 |
--- a/dev-lisp/sbcl/Manifest |
21 |
+++ b/dev-lisp/sbcl/Manifest |
22 |
@@ -24,3 +24,5 @@ DIST sbcl-1.5.8-source.tar.bz2 6409837 BLAKE2B cb503ee1db82f2e1a9c123b9b6b5052b2 |
23 |
DIST sbcl-1.5.8-x86-64-linux-binary.tar.bz2 10145219 BLAKE2B aeccd48a5448e334d6cf3ca4e067ac23943256c2a729ff24b6b3c332c6c70c108b68a6903193a403176d4fbf4804c9f22add615e29fa09022f84b0190a429454 SHA512 d733929775be6fe5d46fd5b11c808eae89172a5a8694f1c2a7927cc364419529292d70f6902731f4c7822c85708555382de31b605440493bb281ccef552daf6c |
24 |
DIST sbcl-2.0.0-source.tar.bz2 6457217 BLAKE2B ae09d4d80ca7100fb412be570126918612eb5a3f27a8c17ced4e0c555d105f3180999f2663ea86910dda9d812d4297cceb8d7c43d5084d20902839e1f23bc739 SHA512 e458e11af6703d8cff973cf5167866b93fe5f6e1b2df3cbf0c1beb014eef2d737d83fc9cde5745d476ef5397a2c9b4b4148d2b77ebbcec13e0f284b2e0900906 |
25 |
DIST sbcl-2.0.0-x86-64-linux-binary.tar.bz2 10196560 BLAKE2B 161d53df96817a50606ffc6a5ad502a94a1aa622e0a45c17c4ff4148deafb2e1db560aacd33b1198eb6fd3bc462b320e01d4925097bec3954f9d6ce564a2b1f5 SHA512 23d3974656a33ae0cfce340e2fbdd60a4e595353e7cc6e75dbab0242d7baaa30d677d1163d4440e953cd7f859fc737b073055b68fbeb2e57e3542a0133d7648f |
26 |
+DIST sbcl-2.0.1-source.tar.bz2 6466983 BLAKE2B f040fb288f5b7adb8a7f56aae60a37e38034c2fed958b1361f473096769367b0a10a76a0e45380e6dcf3b4bd2c1038957448f70eede38b04c228a14e3afc1fc2 SHA512 1d92589033e123c21377f820dbc22e27f2610a372c5545799bec7c247795ba4b8b65102c7fe739f4a15a84579ec72f63fb9f4b197db5c6da1f8d59bd35966bea |
27 |
+DIST sbcl-2.0.1-x86-64-linux-binary.tar.bz2 10151722 BLAKE2B 445fcaa5a6f1c2a7a7d80dd28d1126c33437af2a59dadd25cbbe9ca4e12488a985e78aa12095fda8e38e21dceca77a0e1bca0949133b0ac2666d4367bf881f68 SHA512 1d24981b42c5d91f6037ad6fed782786bbc75edcb2f125a6d5b793448d00c211af515f56b6dd70a68bd33ea7174fd1d96ef9ab353c96905835b6299dcb170f47 |
28 |
|
29 |
diff --git a/dev-lisp/sbcl/files/concurrency-test-2.0.1.patch b/dev-lisp/sbcl/files/concurrency-test-2.0.1.patch |
30 |
new file mode 100644 |
31 |
index 00000000000..e0a36a8b3a2 |
32 |
--- /dev/null |
33 |
+++ b/dev-lisp/sbcl/files/concurrency-test-2.0.1.patch |
34 |
@@ -0,0 +1,12 @@ |
35 |
+diff -r -U3 sbcl-2.0.1.orig/contrib/sb-concurrency/tests/test-frlock.lisp sbcl-2.0.1/contrib/sb-concurrency/tests/test-frlock.lisp |
36 |
+--- sbcl-2.0.1.orig/contrib/sb-concurrency/tests/test-frlock.lisp 2020-01-27 04:26:30.000000000 +0700 |
37 |
++++ sbcl-2.0.1/contrib/sb-concurrency/tests/test-frlock.lisp 2020-01-30 21:53:57.750913923 +0700 |
38 |
+@@ -88,7 +88,7 @@ |
39 |
+ #+sb-thread |
40 |
+ (deftest* (frlock.1) |
41 |
+ (handler-case |
42 |
+- (sb-ext:with-timeout 40 |
43 |
++ (sb-ext:with-timeout 240 |
44 |
+ (test-frlocks #+win32 :outer-write-pause #+win32 t )) |
45 |
+ (sb-ext:timeout (c) |
46 |
+ (error "~A" c))) |
47 |
|
48 |
diff --git a/dev-lisp/sbcl/sbcl-2.0.1.ebuild b/dev-lisp/sbcl/sbcl-2.0.1.ebuild |
49 |
new file mode 100644 |
50 |
index 00000000000..05eaaf6192e |
51 |
--- /dev/null |
52 |
+++ b/dev-lisp/sbcl/sbcl-2.0.1.ebuild |
53 |
@@ -0,0 +1,246 @@ |
54 |
+# Copyright 1999-2020 Gentoo Authors |
55 |
+# Distributed under the terms of the GNU General Public License v2 |
56 |
+ |
57 |
+EAPI=6 |
58 |
+ |
59 |
+inherit multilib eutils flag-o-matic pax-utils |
60 |
+ |
61 |
+#same order as http://www.sbcl.org/platform-table.html |
62 |
+BV_X86=1.4.3 |
63 |
+BV_AMD64=2.0.1 |
64 |
+BV_PPC=1.2.7 |
65 |
+BV_SPARC=1.0.28 |
66 |
+BV_ALPHA=1.0.28 |
67 |
+BV_ARM=1.4.11 |
68 |
+BV_ARM64=1.4.2 |
69 |
+BV_X86_MACOS=1.1.6 |
70 |
+BV_X64_MACOS=1.2.11 |
71 |
+BV_PPC_MACOS=1.0.47 |
72 |
+BV_X86_SOLARIS=1.2.7 |
73 |
+BV_X64_SOLARIS=1.2.7 |
74 |
+BV_SPARC_SOLARIS=1.0.23 |
75 |
+ |
76 |
+DESCRIPTION="Steel Bank Common Lisp (SBCL) is an implementation of ANSI Common Lisp" |
77 |
+HOMEPAGE="http://sbcl.sourceforge.net/" |
78 |
+SRC_URI="mirror://sourceforge/sbcl/${P}-source.tar.bz2 |
79 |
+ x86? ( mirror://sourceforge/sbcl/${PN}-${BV_X86}-x86-linux-binary.tar.bz2 ) |
80 |
+ amd64? ( mirror://sourceforge/sbcl/${PN}-${BV_AMD64}-x86-64-linux-binary.tar.bz2 ) |
81 |
+ ppc? ( mirror://sourceforge/sbcl/${PN}-${BV_PPC}-powerpc-linux-binary.tar.bz2 ) |
82 |
+ sparc? ( mirror://sourceforge/sbcl/${PN}-${BV_SPARC}-sparc-linux-binary.tar.bz2 ) |
83 |
+ alpha? ( mirror://sourceforge/sbcl/${PN}-${BV_ALPHA}-alpha-linux-binary.tar.bz2 ) |
84 |
+ arm? ( mirror://sourceforge/sbcl/${PN}-${BV_ARM}-armhf-linux-binary.tar.bz2 ) |
85 |
+ arm64? ( mirror://sourceforge/sbcl/${PN}-${BV_ARM64}-arm64-linux-binary.tar.bz2 ) |
86 |
+ x86-macos? ( mirror://sourceforge/sbcl/${PN}-${BV_X86_MACOS}-x86-darwin-binary.tar.bz2 ) |
87 |
+ x64-macos? ( mirror://sourceforge/sbcl/${PN}-${BV_X64_MACOS}-x86-64-darwin-binary.tar.bz2 ) |
88 |
+ ppc-macos? ( mirror://sourceforge/sbcl/${PN}-${BV_PPC_MACOS}-powerpc-darwin-binary.tar.bz2 ) |
89 |
+ x86-solaris? ( mirror://sourceforge/sbcl/${PN}-${BV_X86_SOLARIS}-x86-solaris-binary.tar.bz2 ) |
90 |
+ x64-solaris? ( mirror://sourceforge/sbcl/${PN}-${BV_X64_SOLARIS}-x86-64-solaris-binary.tar.bz2 ) |
91 |
+ sparc-solaris? ( mirror://sourceforge/sbcl/${PN}-${BV_SPARC_SOLARIS}-sparc-solaris-binary.tar.bz2 )" |
92 |
+ |
93 |
+LICENSE="MIT" |
94 |
+SLOT="0/${PV}" |
95 |
+KEYWORDS="~amd64 ~ppc ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~x86-solaris" |
96 |
+IUSE="debug doc source +threads +unicode pax_kernel zlib" |
97 |
+ |
98 |
+CDEPEND=">=dev-lisp/asdf-3.1:=" |
99 |
+DEPEND="${CDEPEND} |
100 |
+ doc? ( sys-apps/texinfo >=media-gfx/graphviz-2.26.0 ) |
101 |
+ pax_kernel? ( sys-apps/elfix )" |
102 |
+RDEPEND="${CDEPEND} |
103 |
+ !prefix? ( elibc_glibc? ( >=sys-libs/glibc-2.6 ) )" |
104 |
+ |
105 |
+# Disable warnings about executable stacks, as this won't be fixed soon by upstream |
106 |
+QA_EXECSTACK="usr/bin/sbcl" |
107 |
+ |
108 |
+CONFIG="${S}/customize-target-features.lisp" |
109 |
+ENVD="${T}/50sbcl" |
110 |
+ |
111 |
+# Prevent ASDF from using the system libraries |
112 |
+CL_SOURCE_REGISTRY="(:source-registry :ignore-inherited-configuration)" |
113 |
+ASDF_OUTPUT_TRANSLATIONS="(:output-translations :ignore-inherited-configuration)" |
114 |
+ |
115 |
+usep() { |
116 |
+ use ${1} && echo "true" || echo "false" |
117 |
+} |
118 |
+ |
119 |
+sbcl_feature() { |
120 |
+ echo "$( [[ ${1} == "true" ]] && echo "(enable ${2})" || echo "(disable ${2})")" >> "${CONFIG}" |
121 |
+} |
122 |
+ |
123 |
+sbcl_apply_features() { |
124 |
+ sed 's/^X//' > "${CONFIG}" <<-'EOF' |
125 |
+ (lambda (list) |
126 |
+ X (flet ((enable (x) (pushnew x list)) |
127 |
+ X (disable (x) (setf list (remove x list)))) |
128 |
+ EOF |
129 |
+ if use x86 || use amd64; then |
130 |
+ sbcl_feature "$(usep threads)" ":sb-thread" |
131 |
+ fi |
132 |
+ sbcl_feature "true" ":sb-ldb" |
133 |
+ sbcl_feature "false" ":sb-test" |
134 |
+ sbcl_feature "$(usep unicode)" ":sb-unicode" |
135 |
+ sbcl_feature "$(usep zlib)" ":sb-core-compression" |
136 |
+ sbcl_feature "$(usep debug)" ":sb-xref-for-internals" |
137 |
+ sed 's/^X//' >> "${CONFIG}" <<-'EOF' |
138 |
+ X ) |
139 |
+ X list) |
140 |
+ EOF |
141 |
+ cat "${CONFIG}" |
142 |
+} |
143 |
+ |
144 |
+src_unpack() { |
145 |
+ unpack ${A} |
146 |
+ mv sbcl-*-* sbcl-binary || die |
147 |
+ cd "${S}" |
148 |
+} |
149 |
+ |
150 |
+src_prepare() { |
151 |
+ # bug #468482 |
152 |
+ eapply "${FILESDIR}"/concurrency-test-2.0.1.patch |
153 |
+ # bugs #486552, #527666, #517004 |
154 |
+ eapply "${FILESDIR}"/${PN}-1.4.0-bsd-sockets-test.patch |
155 |
+ # bugs #560276, #561018 |
156 |
+ eapply "${FILESDIR}"/sb-posix-test-1.2.15.patch |
157 |
+ |
158 |
+ eapply "${FILESDIR}"/${PN}-1.2.11-solaris.patch |
159 |
+ eapply "${FILESDIR}"/${PN}-1.4.0-verbose-build.patch |
160 |
+ |
161 |
+ eapply_user |
162 |
+ |
163 |
+ # Make sure the *FLAGS variables are sane. |
164 |
+ # sbcl needs symbols in resulting binaries, so building with the -s linker flag will fail. |
165 |
+ strip-unsupported-flags |
166 |
+ filter-flags -fomit-frame-pointer -Wl,-s |
167 |
+ filter-ldflags -s |
168 |
+ |
169 |
+ # original bugs #526194, #620532 |
170 |
+ # this broke no-pie default builds, c.f. bug #632670 |
171 |
+ # Pass CFLAGS down by appending our value, to let users override |
172 |
+ # the default values. |
173 |
+ # Keep passing LDFLAGS down via the LINKFLAGS variable. |
174 |
+ sed -e "s@\(CFLAGS += -g .*\)\$@\1 ${CFLAGS}@" \ |
175 |
+ -e "s@LINKFLAGS += -g\$@LINKFLAGS += ${LDFLAGS}@" \ |
176 |
+ -i src/runtime/GNUmakefile || die |
177 |
+ |
178 |
+ sed -e "s@SBCL_PREFIX=\"/usr/local\"@SBCL_PREFIX=\"${EPREFIX}/usr\"@" \ |
179 |
+ -i make-config.sh || die |
180 |
+ |
181 |
+ # Use installed ASDF version |
182 |
+ cp "${EPREFIX}"/usr/share/common-lisp/source/asdf/build/asdf.lisp contrib/asdf/ || die |
183 |
+ # Avoid installation of ASDF info page. See bug #605752 |
184 |
+ sed '/INFOFILES/s/asdf.info//' -i doc/manual/Makefile || die |
185 |
+ |
186 |
+ use source && sed 's%"$(BUILD_ROOT)%$(MODULE).lisp "$(BUILD_ROOT)%' -i contrib/vanilla-module.mk |
187 |
+ |
188 |
+ # Some shells(such as dash) don't have "time" as builtin |
189 |
+ # and we don't want to DEPEND on sys-process/time |
190 |
+ sed "s,^time ,," -i make.sh || die |
191 |
+ sed "s,/lib,/$(get_libdir),g" -i install.sh || die |
192 |
+ # #define SBCL_HOME ... |
193 |
+ sed "s,/usr/local/lib,${EPREFIX}/usr/$(get_libdir),g" -i src/runtime/runtime.c || die |
194 |
+ # change location of /etc/sbclrc ... |
195 |
+ sed "s,/etc/sbclrc,${EPREFIX}/etc/sbclrc,g" -i src/code/toplevel.lisp || die |
196 |
+ |
197 |
+ find . -type f -name .cvsignore -delete |
198 |
+} |
199 |
+ |
200 |
+src_configure() { |
201 |
+ # customizing SBCL version as per |
202 |
+ # http://sbcl.cvs.sourceforge.net/sbcl/sbcl/doc/PACKAGING-SBCL.txt?view=markup |
203 |
+ echo -e ";;; Auto-generated by Gentoo\n\"gentoo-${PR}\"" > branch-version.lisp-expr |
204 |
+ |
205 |
+ # applying customizations |
206 |
+ sbcl_apply_features |
207 |
+} |
208 |
+ |
209 |
+src_compile() { |
210 |
+ local bindir="${WORKDIR}"/sbcl-binary |
211 |
+ |
212 |
+ if use pax_kernel ; then |
213 |
+ # To disable PaX on hardened systems |
214 |
+ pax-mark -mr "${bindir}"/src/runtime/sbcl |
215 |
+ |
216 |
+ # Hack to disable PaX on second GENESIS stage |
217 |
+ sed -i -e '/^[ \t]*echo \/\/doing warm init - compilation phase$/a\ paxmark.sh -mr \.\/src\/runtime\/sbcl' \ |
218 |
+ "${S}"/make-target-2.sh || die "Cannot disable PaX on second GENESIS runtime" |
219 |
+ fi |
220 |
+ |
221 |
+ # clear the environment to get rid of non-ASCII strings, see bug #174702 |
222 |
+ # set HOME for paludis |
223 |
+ env - HOME="${T}" PATH="${PATH}" \ |
224 |
+ CC="$(tc-getCC)" AS="$(tc-getAS)" LD="$(tc-getLD)" \ |
225 |
+ CPPFLAGS="${CPPFLAGS}" CFLAGS="${CFLAGS}" ASFLAGS="${ASFLAGS}" LDFLAGS="${LDFLAGS}" \ |
226 |
+ GNUMAKE=make ./make.sh \ |
227 |
+ "sh ${bindir}/run-sbcl.sh --no-sysinit --no-userinit --disable-debugger" \ |
228 |
+ || die "make failed" |
229 |
+ |
230 |
+ # need to set HOME because libpango(used by graphviz) complains about it |
231 |
+ if use doc; then |
232 |
+ env - HOME="${T}" PATH="${PATH}" \ |
233 |
+ CL_SOURCE_REGISTRY="(:source-registry :ignore-inherited-configuration)" \ |
234 |
+ ASDF_OUTPUT_TRANSLATIONS="(:output-translations :ignore-inherited-configuration)" \ |
235 |
+ make -C doc/manual info html || die "Cannot build manual" |
236 |
+ env - HOME="${T}" PATH="${PATH}" \ |
237 |
+ CL_SOURCE_REGISTRY="(:source-registry :ignore-inherited-configuration)" \ |
238 |
+ ASDF_OUTPUT_TRANSLATIONS="(:output-translations :ignore-inherited-configuration)" \ |
239 |
+ make -C doc/internals info html || die "Cannot build internal docs" |
240 |
+ fi |
241 |
+} |
242 |
+ |
243 |
+src_test() { |
244 |
+ ewarn "Unfortunately, it is known that some tests fail eg." |
245 |
+ ewarn "run-program.impure.lisp. This is an issue of the upstream's" |
246 |
+ ewarn "development and not of Gentoo's side. Please, before filing" |
247 |
+ ewarn "any bug(s) search for older submissions. Thank you." |
248 |
+ time ( cd tests && sh run-tests.sh ) |
249 |
+} |
250 |
+ |
251 |
+src_install() { |
252 |
+ # install system-wide initfile |
253 |
+ dodir /etc/ |
254 |
+ sed 's/^X//' > "${ED}"/etc/sbclrc <<-EOF |
255 |
+ ;;; The following is required if you want source location functions to |
256 |
+ ;;; work in SLIME, for example. |
257 |
+ X |
258 |
+ (setf (logical-pathname-translations "SYS") |
259 |
+ X '(("SYS:SRC;**;*.*.*" #p"${EPREFIX}/usr/$(get_libdir)/sbcl/src/**/*.*") |
260 |
+ X ("SYS:CONTRIB;**;*.*.*" #p"${EPREFIX}/usr/$(get_libdir)/sbcl/**/*.*"))) |
261 |
+ X |
262 |
+ ;;; Setup ASDF2 |
263 |
+ (load "${EPREFIX}/etc/common-lisp/gentoo-init.lisp") |
264 |
+ EOF |
265 |
+ |
266 |
+ # Install documentation |
267 |
+ unset SBCL_HOME |
268 |
+ INSTALL_ROOT="${ED}/usr" LIB_DIR="${EPREFIX}/usr/$(get_libdir)" DOC_DIR="${ED}/usr/share/doc/${PF}" \ |
269 |
+ sh install.sh || die "install.sh failed" |
270 |
+ |
271 |
+ # bug #517008 |
272 |
+ pax-mark -mr "${D}"/usr/bin/sbcl |
273 |
+ |
274 |
+ # rm empty directories lest paludis complain about this |
275 |
+ find "${ED}" -empty -type d -exec rmdir -v {} + |
276 |
+ |
277 |
+ if use doc; then |
278 |
+ dodoc -r doc/internals/sbcl-internals |
279 |
+ |
280 |
+ doinfo doc/manual/*.info* |
281 |
+ doinfo doc/internals/sbcl-internals.info |
282 |
+ |
283 |
+ docinto internals-notes |
284 |
+ dodoc doc/internals-notes/* |
285 |
+ else |
286 |
+ rm -Rv "${ED}/usr/share/doc/${PF}" || die |
287 |
+ fi |
288 |
+ |
289 |
+ # install the SBCL source |
290 |
+ if use source; then |
291 |
+ ./clean.sh |
292 |
+ cp -av src "${ED}/usr/$(get_libdir)/sbcl/" || die |
293 |
+ fi |
294 |
+ |
295 |
+ # necessary for running newly-saved images |
296 |
+ echo "SBCL_HOME=${EPREFIX}/usr/$(get_libdir)/${PN}" > "${ENVD}" |
297 |
+ echo "SBCL_SOURCE_ROOT=${EPREFIX}/usr/$(get_libdir)/${PN}/src" >> "${ENVD}" |
298 |
+ doenvd "${ENVD}" |
299 |
+} |