summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/guile
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/guile')
-rw-r--r--meta/recipes-devtools/guile/files/arm_endianness.patch23
-rw-r--r--meta/recipes-devtools/guile/files/debian/0002-Mark-Unused-modules-are-removed-gc-test-as-unresolve.patch39
-rw-r--r--meta/recipes-devtools/guile/files/debian/0003-Mark-mutex-with-owner-not-retained-threads-test-as-u.patch33
-rw-r--r--meta/recipes-devtools/guile/files/guile_2.0.6_fix_sed_error.patch24
-rw-r--r--meta/recipes-devtools/guile/files/opensuse/guile-64bit.patch39
-rw-r--r--meta/recipes-devtools/guile/files/opensuse/guile-turn-off-gc-test.patch49
-rw-r--r--meta/recipes-devtools/guile/guile_2.0.9.bb104
7 files changed, 311 insertions, 0 deletions
diff --git a/meta/recipes-devtools/guile/files/arm_endianness.patch b/meta/recipes-devtools/guile/files/arm_endianness.patch
new file mode 100644
index 0000000000..ea4328b81d
--- /dev/null
+++ b/meta/recipes-devtools/guile/files/arm_endianness.patch
@@ -0,0 +1,23 @@
1Support form ARM endianness
2
3Fixes Yocto bug# 2729
4
5Signed-off-by: Khem Raj <raj.khem@gmail.com>
6
7Upstream-Status: Pending
8
9Index: guile-2.0.5/module/system/base/target.scm
10===================================================================
11--- guile-2.0.5.orig/module/system/base/target.scm 2012-01-24 03:06:06.000000000 -0800
12+++ guile-2.0.5/module/system/base/target.scm 2012-07-12 13:05:44.372364103 -0700
13@@ -70,7 +70,9 @@
14 ((member cpu '("sparc" "sparc64" "powerpc" "powerpc64" "spu"
15 "mips" "mips64"))
16 (endianness big))
17- ((string-match "^arm.*el" cpu)
18+ ((string-match "^arm.*eb" cpu)
19+ (endianness big))
20+ ((string-match "^arm.*" cpu)
21 (endianness little))
22 (else
23 (error "unknown CPU endianness" cpu)))))
diff --git a/meta/recipes-devtools/guile/files/debian/0002-Mark-Unused-modules-are-removed-gc-test-as-unresolve.patch b/meta/recipes-devtools/guile/files/debian/0002-Mark-Unused-modules-are-removed-gc-test-as-unresolve.patch
new file mode 100644
index 0000000000..43238a7d2e
--- /dev/null
+++ b/meta/recipes-devtools/guile/files/debian/0002-Mark-Unused-modules-are-removed-gc-test-as-unresolve.patch
@@ -0,0 +1,39 @@
1Upstream-Status: Inappropriate [debian patch]
2
3Signed-Off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
4
5From e52bfcdbaca5dce498678d8f512381e3e39a4066 Mon Sep 17 00:00:00 2001
6From: Rob Browning <rlb@defaultvalue.org>
7Date: Sun, 18 Mar 2012 11:40:55 -0500
8Subject: Mark "Unused modules are removed" gc test as unresolved.
9
10As per discussion with upstream, mark this test as unresolved since it
11may produce false negatives, depending on the behavior/timing of the
12garbage collector.
13---
14 test-suite/tests/gc.test | 11 ++++++-----
15 1 files changed, 6 insertions(+), 5 deletions(-)
16
17diff --git a/test-suite/tests/gc.test b/test-suite/tests/gc.test
18index a969752..8c8e13e 100644
19--- a/test-suite/tests/gc.test
20+++ b/test-suite/tests/gc.test
21@@ -84,11 +84,13 @@
22 ;; one gc round. not sure why.
23
24 (maybe-gc-flakiness
25- (= (let lp ((i 0))
26- (if (guard)
27- (lp (1+ i))
28- i))
29- total))))
30+ (or (= (let lp ((i 0))
31+ (if (guard)
32+ (lp (1+ i))
33+ i))
34+ total)
35+ (throw 'unresolved)))))
36+
37
38 (pass-if "Lexical vars are collectable"
39 (let ((l (compile
diff --git a/meta/recipes-devtools/guile/files/debian/0003-Mark-mutex-with-owner-not-retained-threads-test-as-u.patch b/meta/recipes-devtools/guile/files/debian/0003-Mark-mutex-with-owner-not-retained-threads-test-as-u.patch
new file mode 100644
index 0000000000..34be3b96e7
--- /dev/null
+++ b/meta/recipes-devtools/guile/files/debian/0003-Mark-mutex-with-owner-not-retained-threads-test-as-u.patch
@@ -0,0 +1,33 @@
1Upstream-Status: Inappropriate [debian patch]
2
3Signed-Off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
4
5From 848543091d55dddb54a85612155964506d712852 Mon Sep 17 00:00:00 2001
6From: Rob Browning <rlb@defaultvalue.org>
7Date: Sun, 18 Mar 2012 13:28:24 -0500
8Subject: Mark "mutex with owner not retained" threads test as unresolved.
9
10As per discussion with upstream, mark this test as unresolved since it
11may produce false negatives, depending on the behavior/timing of the
12garbage collector.
13---
14 test-suite/tests/threads.test | 6 ++++--
15 1 files changed, 4 insertions(+), 2 deletions(-)
16
17diff --git a/test-suite/tests/threads.test b/test-suite/tests/threads.test
18index 85a7c38..50899cb 100644
19--- a/test-suite/tests/threads.test
20+++ b/test-suite/tests/threads.test
21@@ -414,8 +414,10 @@
22
23 (gc) (gc)
24 (let ((m (g)))
25- (and (mutex? m)
26- (eq? (mutex-owner m) (current-thread)))))))
27+ (or
28+ (and (mutex? m)
29+ (eq? (mutex-owner m) (current-thread)))
30+ (throw 'unresolved))))))
31
32 ;;
33 ;; mutex lock levels
diff --git a/meta/recipes-devtools/guile/files/guile_2.0.6_fix_sed_error.patch b/meta/recipes-devtools/guile/files/guile_2.0.6_fix_sed_error.patch
new file mode 100644
index 0000000000..e5dc226370
--- /dev/null
+++ b/meta/recipes-devtools/guile/files/guile_2.0.6_fix_sed_error.patch
@@ -0,0 +1,24 @@
1Upstream-Status: Pending
2
3This fixes sed issue when prefix has / in it, like /usr/local
4
5autoreconf error avoided:
6| sed: -e expression #1, char 9: unknown option to `s'
7| configure.ac:39: error: AC_INIT should be called with package and version arguments
8
9Signed-Off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
102012/05/01
11
12Index: guile-2.0.5/build-aux/git-version-gen
13===================================================================
14--- guile-2.0.5.orig/build-aux/git-version-gen
15+++ guile-2.0.5/build-aux/git-version-gen
16@@ -187,7 +187,7 @@ else
17 v=UNKNOWN
18 fi
19
20-v=`echo "$v" |sed "s/^$prefix//"`
21+v=`echo "$v" |sed "s#^$prefix##"`
22
23 # Test whether to append the "-dirty" suffix only if the version
24 # string we're using came from git. I.e., skip the test if it's "UNKNOWN"
diff --git a/meta/recipes-devtools/guile/files/opensuse/guile-64bit.patch b/meta/recipes-devtools/guile/files/opensuse/guile-64bit.patch
new file mode 100644
index 0000000000..d3e312f770
--- /dev/null
+++ b/meta/recipes-devtools/guile/files/opensuse/guile-64bit.patch
@@ -0,0 +1,39 @@
1Upstream-Status: Inappropriate [opensuse patch]
2
3Signed-Off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
4
5Index: guile-2.0.3/libguile/hash.c
6===================================================================
7--- guile-2.0.3.orig/libguile/hash.c 2011-07-06 15:49:59.000000000 -0700
8+++ guile-2.0.3/libguile/hash.c 2012-01-13 21:49:43.332844884 -0800
9@@ -270,7 +270,7 @@ scm_hasher(SCM obj, unsigned long n, siz
10 unsigned long
11 scm_ihashq (SCM obj, unsigned long n)
12 {
13- return (SCM_UNPACK (obj) >> 1) % n;
14+ return ((unsigned long) SCM_UNPACK (obj) >> 1) % n;
15 }
16
17
18@@ -306,7 +306,7 @@ scm_ihashv (SCM obj, unsigned long n)
19 if (SCM_NUMP(obj))
20 return (unsigned long) scm_hasher(obj, n, 10);
21 else
22- return SCM_UNPACK (obj) % n;
23+ return (unsigned long) SCM_UNPACK (obj) % n;
24 }
25
26
27Index: guile-2.0.3/libguile/struct.c
28===================================================================
29--- guile-2.0.3.orig/libguile/struct.c 2011-07-06 15:50:00.000000000 -0700
30+++ guile-2.0.3/libguile/struct.c 2012-01-13 21:49:43.332844884 -0800
31@@ -942,7 +942,7 @@ scm_struct_ihashq (SCM obj, unsigned lon
32 {
33 /* The length of the hash table should be a relative prime it's not
34 necessary to shift down the address. */
35- return SCM_UNPACK (obj) % n;
36+ return (unsigned long) SCM_UNPACK (obj) % n;
37 }
38
39 SCM_DEFINE (scm_struct_vtable_name, "struct-vtable-name", 1, 0, 0,
diff --git a/meta/recipes-devtools/guile/files/opensuse/guile-turn-off-gc-test.patch b/meta/recipes-devtools/guile/files/opensuse/guile-turn-off-gc-test.patch
new file mode 100644
index 0000000000..e201486284
--- /dev/null
+++ b/meta/recipes-devtools/guile/files/opensuse/guile-turn-off-gc-test.patch
@@ -0,0 +1,49 @@
1Upstream-Status: Inappropriate [opensuse patch]
2
3Signed-Off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
4
5See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10096
6why this test is turned off.
7Index: guile-2.0.3/test-suite/tests/gc.test
8===================================================================
9--- guile-2.0.3.orig/test-suite/tests/gc.test 2011-10-15 09:34:40.000000000 -0700
10+++ guile-2.0.3/test-suite/tests/gc.test 2012-01-13 21:52:10.282540355 -0800
11@@ -65,23 +65,23 @@
12 foo)))
13
14
15-(with-test-prefix "gc"
16- (pass-if "Unused modules are removed"
17- (let* ((guard (make-guardian))
18- (total 1000))
19-
20- (for-each (lambda (x) (guard (make-module))) (iota total))
21+;;(with-test-prefix "gc"
22+;; (pass-if "Unused modules are removed"
23+;; (let* ((guard (make-guardian))
24+;; (total 1000))
25+;;
26+;; (for-each (lambda (x) (guard (make-module))) (iota total))
27
28 ;; Avoid false references to the modules on the stack.
29- (stack-cleanup 20)
30+;; (stack-cleanup 20)
31
32- (gc)
33- (gc) ;; twice: have to kill the weak vectors.
34- (gc) ;; thrice: because the test doesn't succeed with only
35+;; (gc)
36+;; (gc) ;; twice: have to kill the weak vectors.
37+;; (gc) ;; thrice: because the test doesn't succeed with only
38 ;; one gc round. not sure why.
39
40- (= (let lp ((i 0))
41- (if (guard)
42- (lp (1+ i))
43- i))
44- total))))
45+;; (= (let lp ((i 0))
46+;; (if (guard)
47+;; (lp (1+ i))
48+;; i))
49+;; total))))
diff --git a/meta/recipes-devtools/guile/guile_2.0.9.bb b/meta/recipes-devtools/guile/guile_2.0.9.bb
new file mode 100644
index 0000000000..0dd61ff2a2
--- /dev/null
+++ b/meta/recipes-devtools/guile/guile_2.0.9.bb
@@ -0,0 +1,104 @@
1SUMMARY = "Guile is the GNU Ubiquitous Intelligent Language for Extensions."
2DESCRIPTION = "Guile is the GNU Ubiquitous Intelligent Language for Extensions,\
3 the official extension language for the GNU operating system.\
4 Guile is a library designed to help programmers create flexible applications.\
5 Using Guile in an application allows the application's functionality to be\
6 extended by users or other programmers with plug-ins, modules, or scripts.\
7 Guile provides what might be described as 'practical software freedom,'\
8 making it possible for users to customize an application to meet their\
9 needs without digging into the application's internals."
10
11HOMEPAGE = "http://www.gnu.org/software/guile/"
12SECTION = "devel"
13LICENSE = "GPLv3"
14LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
15
16SRC_URI = "${GNU_MIRROR}/guile/guile-${PV}.tar.xz \
17 file://debian/0002-Mark-Unused-modules-are-removed-gc-test-as-unresolve.patch \
18 file://debian/0003-Mark-mutex-with-owner-not-retained-threads-test-as-u.patch \
19 file://opensuse/guile-64bit.patch \
20 file://guile_2.0.6_fix_sed_error.patch \
21 file://arm_endianness.patch \
22 "
23
24# file://debian/0001-Change-guile-to-guile-X.Y-for-info-pages.patch
25# file://opensuse/guile-turn-off-gc-test.patch
26
27SRC_URI[md5sum] = "a69b575d4a633bdd9118f3a4a1e97766"
28SRC_URI[sha256sum] = "f70a38c8d9751f442679bfe61852bba8545af4d4355d037630997c2f37f2895b"
29
30PR = "r0"
31
32inherit autotools gettext
33BBCLASSEXTEND = "native"
34
35DEPENDS = "libunistring bdwgc gmp libtool libffi"
36# add guile-native only to the target recipe's DEPENDS
37DEPENDS += "${@['guile-native libatomics-ops', ''][d.getVar('PN', True) != 'guile']}"
38
39RDEPENDS_${PN}_append_libc-glibc_class-target = "glibc-gconv-iso8859-1"
40
41EXTRA_OECONF += "${@['--without-libltdl-prefix --without-libgmp-prefix --without-libreadline-prefix', ''][bb.data.inherits_class('native',d)]}"
42
43do_configure_prepend() {
44 mkdir -p po
45}
46
47export GUILE_FOR_BUILD="${BUILD_SYS}-guile"
48
49do_compile_append() {
50 # just for target recipe
51 if [ "${PN}" = "guile" ]
52 then
53 sed -i -e s:${STAGING_DIR_TARGET}::g \
54 -e s:/${TARGET_SYS}::g \
55 -e s:-L/usr/lib::g \
56 -e s:-isystem/usr/include::g \
57 -e s:,/usr/lib:,\$\{libdir\}:g \
58 meta/guile-2.0.pc
59 fi
60}
61
62do_install_append_class-native() {
63 install -m 0755 ${D}${bindir}/guile ${D}${bindir}/${HOST_SYS}-guile
64
65 create_wrapper ${D}/${bindir}/guile \
66 GUILE_LOAD_PATH=${STAGING_DATADIR_NATIVE}/guile/2.0 \
67 GUILE_LOAD_COMPILED_PATH=${STAGING_LIBDIR_NATIVE}/guile/2.0/ccache
68 create_wrapper ${D}${bindir}/${HOST_SYS}-guile \
69 GUILE_LOAD_PATH=${STAGING_DATADIR_NATIVE}/guile/2.0 \
70 GUILE_LOAD_COMPILED_PATH=${STAGING_LIBDIR_NATIVE}/guile/2.0/ccache
71}
72
73SYSROOT_PREPROCESS_FUNCS = "guile_cross_config"
74
75guile_cross_config() {
76 # this is only for target recipe
77 if [ "${PN}" = "guile" ]
78 then
79 # Create guile-config returning target values instead of native values
80 install -d ${SYSROOT_DESTDIR}${STAGING_BINDIR_CROSS}
81 echo '#!'`which ${BUILD_SYS}-guile`$' \\\n--no-auto-compile -e main -s\n!#\n(define %guile-build-info '\'\( \
82 > guile-config.cross
83 sed -n -e 's:^[ \t]*{[ \t]*": (:' \
84 -e 's:",[ \t]*": . ":' \
85 -e 's:" *}, *\\:"):' \
86 -e 's:^.*cachedir.*$::' \
87 -e '/^ (/p' \
88 < libguile/libpath.h >> guile-config.cross
89 echo '))' >> guile-config.cross
90 cat meta/guile-config >> guile-config.cross
91 install guile-config.cross ${STAGING_BINDIR_CROSS}/guile-config
92 fi
93}
94
95# Guile needs the compiled files to be newer than the source, and it won't
96# auto-compile into the prefix even if it can write there, so touch them here as
97# sysroot is managed.
98SSTATEPOSTINSTFUNCS += "guile_sstate_postinst"
99guile_sstate_postinst() {
100 if [ "${BB_CURRENTTASK}" = "populate_sysroot" -o "${BB_CURRENTTASK}" = "populate_sysroot_setscene" ]
101 then
102 find ${STAGING_DIR_TARGET}/${libdir}/guile/2.0/ccache -type f | xargs touch
103 fi
104}