On Thu, 20 Sep 2001, Andy Dougherty wrote:
> On Thu, 20 Sep 2001, Philip Kendall wrote:
>
> > What version of Perl are we requiring to bootstrap Parrot? At the
> > moment, things fail with 5.005 because:
> >
> > 2) The use of `!' to pack() in the assembler.
>
> Oops. My fault. I forgot that was a new addition.
Here's the fix for that.
--- assemble.pl Thu Sep 20 09:35:26 2001
+++ assembple.pl.port Thu Sep 20 11:23:20 2001
@@ -49,14 +49,15 @@
# define data types
my %pack_type;
# Alas perl5.7.2 doesn't have an IV flag for pack().
-if ($PConfig{ivsize} == $PConfig{longsize}) {
+# The ! modifier only works for perl 5.6.x or greater.
+if (($] >= 5.006) && ($PConfig{ivsize} == $PConfig{longsize}) ) {
%pack_type = ('i'=>'l!','n'=>'d');
}
-elsif ($PConfig{ivsize} == 8) {
- %pack_type = ('i'=>'q','n'=>'d');
-}
elsif ($PConfig{ivsize} == 4) {
%pack_type = ('i'=>'l','n'=>'d');
+}
+elsif ($PConfig{ivsize} == 8) {
+ %pack_type = ('i'=>'q','n'=>'d');
}
else {
die("I don't know how to pack an IV!\n");
--
Andy Dougherty [EMAIL PROTECTED]
Dept. of Physics
Lafayette College, Easton PA 18042