From 54f4b7bc0dde6bf61874eba9a569eefce82ff07a Mon Sep 17 00:00:00 2001
From: Michael Hanson <hansonorders@verizon.net>
Date: Sat, 20 Nov 2010 03:48:28 +0000
Subject: guile: upgrade

---
 abs/extra/guile/PKGBUILD          | 29 +++++++++++++++++++----------
 abs/extra/guile/guile-snarf.patch |  9 +++++++++
 2 files changed, 28 insertions(+), 10 deletions(-)
 create mode 100644 abs/extra/guile/guile-snarf.patch

diff --git a/abs/extra/guile/PKGBUILD b/abs/extra/guile/PKGBUILD
index 3721e3f..265139a 100644
--- a/abs/extra/guile/PKGBUILD
+++ b/abs/extra/guile/PKGBUILD
@@ -1,26 +1,35 @@
-# $Id: PKGBUILD 23033 2009-01-01 17:11:52Z jgc $
+# $Id: PKGBUILD 72807 2010-03-20 04:06:14Z allan $
 # Contributor: Tom Newsom <Jeepster@gmx.co.uk>
 # Maintainer: Jan de Groot <jgc@archlinux.org>
 
 pkgname=guile
-pkgver=1.8.6
-pkgrel=1
+pkgver=1.8.7
+pkgrel=2
 pkgdesc="Guile is a portable, embeddable Scheme implementation written in C"
 url="http://www.gnu.org/software/guile/"
-arch=(i686 x86_64)
+arch=('i686' 'x86_64')
 license=('GPL')
-depends=('gmp' 'libtool' 'ncurses>=5.6-7' 'texinfo')
+depends=('gmp' 'libtool' 'ncurses>=5.7' 'texinfo')
 install=guile.install
-source=(ftp://ftp.gnu.org/pub/gnu/${pkgname}/${pkgname}-${pkgver}.tar.gz)
-options=('!libtool')
-md5sums=('9e23d3dbea0e89bab8a9acc6880150de')
+source=(ftp://ftp.gnu.org/pub/gnu/${pkgname}/${pkgname}-${pkgver}.tar.gz
+        guile-snarf.patch)
+options=('!libtool' '!makeflags')
 
 build() {
   cd "${srcdir}/${pkgname}-${pkgver}"
-  ./configure --prefix=/usr --disable-networking \
-    --disable-error-on-warning || return 1
+
+  # Fix build failure without -P
+  # http://old.nabble.com/build-failure-just-trying-to-build-guile-1.8.7-natively-td26411839.html
+  patch -Np1 < ${srcdir}/guile-snarf.patch || return 1
+
+  ./configure --prefix=/usr --disable-error-on-warning || return 1
   make LDFLAGS+="-lpthread" || return 1
+}
+package() {
+  cd "${srcdir}/${pkgname}-${pkgver}"
   make DESTDIR="${pkgdir}" install || return 1
   rm -f "${pkgdir}/usr/share/info/dir"
   gzip "${pkgdir}/usr/share/info"/* || return 1
 }
+md5sums=('991b5b3efcbbc3f7507d05bc42f80a5e'
+         'c11264d2a80858ab2ea1af761a6f6e65')
diff --git a/abs/extra/guile/guile-snarf.patch b/abs/extra/guile/guile-snarf.patch
new file mode 100644
index 0000000..42f2c66
--- /dev/null
+++ b/abs/extra/guile/guile-snarf.patch
@@ -0,0 +1,9 @@
+diff -Nur guile-1.8.7.orig/libguile/guile-snarf-docs.in guile-1.8.7/libguile/guile-snarf-docs.in
+--- guile-1.8.7.orig/libguile/guile-snarf-docs.in 2009-07-03 18:19:00.000000000 -0400
++++ guile-1.8.7/libguile/guile-snarf-docs.in 2009-11-19 12:55:32.487266268 -0500
+@@ -23,4 +23,4 @@
+ ## Let the user override the preprocessor autoconf found.
+ test -n "${CPP+set}" || CPP="@CPP@"
+
+-${CPP} -DSCM_MAGIC_SNARF_DOCS "$@"
++${CPP} -P -DSCM_MAGIC_SNARF_DOCS "$@" 
-- 
cgit v0.12

