From c19cbcc5427fd73ab88442724aad2015904d45ac Mon Sep 17 00:00:00 2001 From: David Woodhouse Date: Apr 30 2007 12:03:07 +0000 Subject: fix stack size, restore ppc build --- diff --git a/clisp-config-stacksize.patch b/clisp-config-stacksize.patch new file mode 100644 index 0000000..5d8aae1 --- /dev/null +++ b/clisp-config-stacksize.patch @@ -0,0 +1,51 @@ +--- configure 2006/10/18 01:36:48 1.104 ++++ configure 2007/01/02 21:51:40 1.105 +@@ -718,6 +718,17 @@ + fi + fi + ++# CLISP needs a lot of stack space for bootstrapping, ++# and insufficient stack space manifests itself via arbitrary GC errors. ++# it was believed that 8192 is enough until power5 came along: ++# https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=166347 ++STACK_LIMIT=16384 ++stacksizelimit=`ulimit -s 2>/dev/null || :` # cygwin /bin/sh ulimit is broken ++# need 3 separate test calls because of "integer expression expected" errors ++# when $stacksizelimit is "" or "unlimited" (no short-circuiting!) ++test -z "$stacksizelimit" || { test "$stacksizelimit" != unlimited && test "$stacksizelimit" -lt ${STACK_LIMIT}; } ++STACK_TOO_SMALL=$? # 0=true => need to reset; 1=false => big enough ++ + if test -z "$do_build"; then + + echo +@@ -729,13 +740,12 @@ + echo " ./makemake $makemake_args > Makefile" + echo " make config.lisp" + echo " ${EDITOR:-vi} config.lisp" +- stacksizelimit=`ulimit -s 2>/dev/null || :` # cygwin /bin/sh ulimit is broken +- if test -z "$stacksizelimit" || { test "$stacksizelimit" != unlimited && test "$stacksizelimit" -lt 8192; }; then ++ if [ "${STACK_TOO_SMALL}" = 0 ]; then + cat </dev/null; set -e; ++ if [ "${STACK_TOO_SMALL}" = 0 ]; then ++ set +e; ulimit -s ${STACK_LIMIT} 2>/dev/null; set -e; ++ fi + make + make check + cd .. diff --git a/clisp.spec b/clisp.spec index d9d6b0d..41b4492 100644 --- a/clisp.spec +++ b/clisp.spec @@ -1,12 +1,13 @@ Name: clisp Summary: Common Lisp (ANSI CL) implementation Version: 2.41 -Release: 3%{?dist} +Release: 4%{?dist} Group: Development/Languages License: GPL URL: http://clisp.cons.org Source: http://download.sourceforge.net/clisp/clisp-2.41.tar.bz2 +Patch: clisp-config-stacksize.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: readline-devel BuildRequires: gettext @@ -26,7 +27,6 @@ BuildRequires: libXmu-devel BuildRequires: libXrender-devel BuildRequires: libXt-devel BuildRequires: imake -ExcludeArch: ppc ppc64 %description @@ -37,7 +37,7 @@ in Germany. It mostly supports the Lisp described in the ANSI Common Lisp standard. It runs on most Unix workstations (GNU/Linux, FreeBSD, NetBSD, OpenBSD, Solaris, Tru64, HP-UX, BeOS, NeXTstep, IRIX, AIX and others) and on other systems (Windows NT/2000/XP, Windows 95/98/ME) -and needs only 4 MB of RAM. +and needs only 4 MiB of RAM. It is Free Software and may be distributed under the terms of GNU GPL, while it is possible to distribute commercial proprietary applications @@ -62,6 +62,7 @@ Files necessary for linking CLISP. %prep %setup -q +%patch -p0 # enforced stack size seems to be too small sed -i "s|ulimit -s 8192|ulimit -s unlimited|" configure @@ -138,6 +139,9 @@ rm -fr $RPM_BUILD_ROOT %changelog +* Mon Apr 30 2007 David Woodhouse - 2.41-4 +- Fix stack size in configure, restore ppc build + * Sat Dec 9 2006 Gerard Milmeister - 2.41-3 - rebuild without berkeley-db for now