summaryrefslogtreecommitdiff
path: root/lang/parrot/patches
diff options
context:
space:
mode:
authorhe <he>2009-10-21 14:23:13 +0000
committerhe <he>2009-10-21 14:23:13 +0000
commitd1ccc0405891bde64d3a60ccba3da7ff95e6fa7a (patch)
treeb9da0e4fe716d7975d9f7a040e2321e7bb7fe33a /lang/parrot/patches
parentee69d3e5533235cdcd3cb5e976193a00de3f9a47 (diff)
downloadpkgsrc-d1ccc0405891bde64d3a60ccba3da7ff95e6fa7a.tar.gz
Update parrot from version 1.6.0 to 1.6.0nb1.
Pkgsrc changes: o Enable shared libraries for NetBSD, and deal with the resulting fallout: tests which are written in C need to point their run-path to the build version of the shared libraries. o The default is shared libs with .so, except for on Darwin, where shared libs are named differently. The Darwin part is untested.
Diffstat (limited to 'lang/parrot/patches')
-rw-r--r--lang/parrot/patches/patch-af34
-rw-r--r--lang/parrot/patches/patch-ag26
-rw-r--r--lang/parrot/patches/patch-ai62
-rw-r--r--lang/parrot/patches/patch-aj17
4 files changed, 139 insertions, 0 deletions
diff --git a/lang/parrot/patches/patch-af b/lang/parrot/patches/patch-af
new file mode 100644
index 00000000000..86b0d77df2e
--- /dev/null
+++ b/lang/parrot/patches/patch-af
@@ -0,0 +1,34 @@
+$NetBSD: patch-af,v 1.3 2009/10/21 14:23:13 he Exp $
+
+Enable shared libraries on NetBSD.
+
+--- config/init/hints/netbsd.pm (revision 41959)
++++ config/init/hints/netbsd.pm (working copy)
+@@ -9,6 +9,9 @@
+ sub runstep {
+ my ( $self, $conf ) = @_;
+
++ my $share_ext = $conf->option_or_data('share_ext');
++ my $version = $conf->option_or_data('VERSION');
++
+ my $ccflags = $conf->data->get('ccflags');
+ if ( $ccflags !~ /-pthread\b/ ) {
+ $ccflags .= ' -pthread';
+@@ -19,7 +22,16 @@
+ if ( $libs !~ /-lpthread\b/ ) {
+ $libs .= ' -lpthread';
+ }
+- $conf->data->set( libs => $libs );
++ $conf->data->set(
++ libs => $libs,
++ rpath => '-Wl,-R',
++
++ has_dynamic_linking => 1,
++ parrot_is_shared => 1,
++ libparrot_shared => "libparrot$share_ext.$version",
++ libparrot_shared_alias => "libparrot$share_ext",
++ libparrot_soname => "-Wl,-soname=libparrot$share_ext.$version",
++ );
+ }
+
+ 1;
diff --git a/lang/parrot/patches/patch-ag b/lang/parrot/patches/patch-ag
new file mode 100644
index 00000000000..17cfed25cfc
--- /dev/null
+++ b/lang/parrot/patches/patch-ag
@@ -0,0 +1,26 @@
+$NetBSD: patch-ag,v 1.3 2009/10/21 14:23:13 he Exp $
+
+This test now works in NetBSD, after we properly selected the libm
+variant in the platform startup code.
+
+--- t/op/trans.t (revision 41959)
++++ t/op/trans.t (working copy)
+@@ -387,9 +387,6 @@
+ ok 16
+ OUTPUT
+
+-TODO: {
+-local $TODO = 'fails on netbsd' if $^O =~ /netbsd/;
+-
+ pasm_output_is( <<"CODE", <<'OUTPUT', 'atan, part 2' );
+ .include 'fp_equality.pasm'
+ atan N4, -0.0, -0.0
+@@ -402,8 +399,6 @@
+ ok 1
+ OUTPUT
+
+-}
+-
+ pasm_output_is( <<"CODE", <<OUTPUT, "log2" );
+ .include 'fp_equality.pasm'
+ set N1, 10.0
diff --git a/lang/parrot/patches/patch-ai b/lang/parrot/patches/patch-ai
new file mode 100644
index 00000000000..eb5cff72092
--- /dev/null
+++ b/lang/parrot/patches/patch-ai
@@ -0,0 +1,62 @@
+$NetBSD: patch-ai,v 1.1 2009/10/21 14:23:13 he Exp $
+
+I beleive this test works for all relevant pkgsrc platforms.
+It has been similarly transformed upstream after 1.7.0 was released.
+
+--- t/op/io.t.orig 2008-12-18 06:19:20.000000000 +0100
++++ t/op/io.t
+@@ -51,28 +51,9 @@ Tests various io opcodes.
+ ok(1, 'open with null mode')
+ .end
+
+-.sub 'tt661_todo_test' :anon
+- # Checks whether the platform is linux, MSWin32, darwin: on other
+- # platforms, the following tests are todo'ed.
+- .include 'sysinfo.pasm'
+- $S0 = sysinfo .SYSINFO_PARROT_OS
+- if $S0 == 'linux' goto tt661_ok
+- if $S0 == 'MSWin32' goto tt661_ok
+- if $S0 == 'darwin' goto tt661_ok
+- if $S0 == 'openbsd' goto tt661_ok
+-
+- .return (0)
+-
+- tt661_ok:
+- .return (1)
+-.end
+-
+ .include 'iglobals.pasm'
+
+ .sub 'open_pipe_for_reading'
+- $I0 = tt661_todo_test()
+- unless $I0 goto open_pipe_for_reading_todoed
+-
+ .local pmc interp
+ interp = getinterp
+
+@@ -103,15 +84,9 @@ Tests various io opcodes.
+ open_pipe_for_reading_failed:
+ nok(1, 'open pipe for reading')
+ .return ()
+-
+- open_pipe_for_reading_todoed:
+- todo(1, 'Unimplemented in this platform, TT #661')
+ .end
+
+ .sub 'open_pipe_for_writing'
+- $I0 = tt661_todo_test()
+- unless $I0 goto open_pipe_for_writing_todoed
+-
+ .local pmc interp
+ interp = getinterp
+
+@@ -144,9 +119,6 @@ Tests various io opcodes.
+ open_pipe_for_writing_failed:
+ nok(1, 'open pipe for writing')
+ .return ()
+-
+- open_pipe_for_writing_todoed:
+- todo(1, 'Unimplemented in this platform, TT #661')
+ .end
+
+ # Local Variables:
diff --git a/lang/parrot/patches/patch-aj b/lang/parrot/patches/patch-aj
new file mode 100644
index 00000000000..ad6b581fb7d
--- /dev/null
+++ b/lang/parrot/patches/patch-aj
@@ -0,0 +1,17 @@
+$NetBSD: patch-aj,v 1.1 2009/10/21 14:23:13 he Exp $
+
+Make sure to use rpath if it's defined when linking C-language tests.
+
+--- lib/Parrot/Test.pm.orig 2009-10-20 03:09:41.000000000 +0200
++++ lib/Parrot/Test.pm
+@@ -1045,6 +1045,10 @@ sub _generate_test_functions {
+ . "$PConfig{ld_out}$exe_f "
+ . "$obj_f $cfg "
+ . "$PConfig{libparrot_linkflags} "
++ # If rpath is defined (and therefore rpath_blib), use it to get at the build libraries
++ . ( defined($PConfig{rpath_blib})
++ ? ( $PConfig{rpath_blib} . " " )
++ : "" )
+ . "$PConfig{linkflags} $PConfig{ld_debug} "
+ . "$iculibs $PConfig{libs}";
+ my $exit_code = run_command(