aboutsummaryrefslogtreecommitdiff
path: root/development
diff options
context:
space:
mode:
authorAndrew Clemons <andrew.clemons@gmail.com>2022-03-21 21:50:57 +1300
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2022-03-26 01:20:16 +0700
commit47e55bfe72ab20fe971ee35d131f62973df3e12f (patch)
tree02e6223b565589aa92564d363051c937ac0b7225 /development
parent96fedf33578f725a3bc429286a1e27f8f0709bd5 (diff)
development/guile1.8: Fix build on 32 bit.
A segfault would be generated when building the docs on i586 at ../scripts/snarf-check-and-output-texi. Apply patch from gentoo which allows the build to complete. Signed-off-by: Andrew Clemons <andrew.clemons@gmail.com> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'development')
-rw-r--r--development/guile1.8/guile-1.8.8-gcc46.patch39
-rw-r--r--development/guile1.8/guile1.8.SlackBuild4
2 files changed, 42 insertions, 1 deletions
diff --git a/development/guile1.8/guile-1.8.8-gcc46.patch b/development/guile1.8/guile-1.8.8-gcc46.patch
new file mode 100644
index 0000000000000..b06a0e59eb147
--- /dev/null
+++ b/development/guile1.8/guile-1.8.8-gcc46.patch
@@ -0,0 +1,39 @@
+Backported upstream patch to fix SIGSEGV with gcc-4.6
+
+http://git.savannah.gnu.org/cgit/guile.git/commit/?h=branch_release-1-8&id=62bc1072c19e81bb0f9e42a5034e7ab8c27d3b94
+https://bugs.gentoo.org/show_bug.cgi?id=424475
+--- a/configure.in
++++ b/configure.in
+@@ -1199,23 +1199,20 @@
+ AC_RUN_IFELSE([AC_LANG_SOURCE(
+ [AC_INCLUDES_DEFAULT
+ int
+-find_stack_direction ()
++find_stack_direction (int *addr, int depth)
+ {
+- static char *addr = 0;
+- auto char dummy;
+- if (addr == 0)
+- {
+- addr = &dummy;
+- return find_stack_direction ();
+- }
+- else
+- return (&dummy > addr) ? 1 : -1;
++ int dir, dummy = 0;
++ if (! addr)
++ addr = &dummy;
++ *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
++ dir = depth ? find_stack_direction (addr, depth - 1) : 0;
++ return dir + dummy;
+ }
+
+ int
+-main ()
++main (int argc, char **argv)
+ {
+- return find_stack_direction () < 0;
++ return find_stack_direction (0, argc + !argv + 20) < 0;
+ }])],
+ [SCM_I_GSC_STACK_GROWS_UP=1],
+ [],
diff --git a/development/guile1.8/guile1.8.SlackBuild b/development/guile1.8/guile1.8.SlackBuild
index 8d569b9f39eab..43b07331f94b1 100644
--- a/development/guile1.8/guile1.8.SlackBuild
+++ b/development/guile1.8/guile1.8.SlackBuild
@@ -25,7 +25,7 @@ cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=guile1.8
SRCNAM=guile
VERSION=${VERSION:-1.8.8}
-BUILD=${BUILD:-3}
+BUILD=${BUILD:-4}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -71,6 +71,8 @@ cd $TMP
rm -rf $SRCNAM-$VERSION
tar xvf $CWD/$SRCNAM-$VERSION.tar.gz
cd $SRCNAM-$VERSION
+# fix segfault - thanks gentoo maintainers.
+patch -p1 -i $CWD/guile-1.8.8-gcc46.patch
chown -R root:root .
find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \