cvsuser 04/07/30 06:16:44
Modified: config/init/hints dec_osf.pl irix.pl
include/parrot parrot.h
src string.c
Log:
[perl #30878] [PATCH] tru64 aio detection
-laio needed.
[perl #30879] [PATCH] IRIX offsetof
Some compilers of IRIX seem to have a quite broken definition of
offsetof. Hand-roll our own if such a compiler is detected.
[perl #30880] [PATCH] const* vs non compiler silencing
[perl #30882] [PATCH] IRIX 64-bit compilation
If the compiler is 64-bit (cc -64 has been used) also the cxx, ld, and
link need to be set accordingly.
All
Courtesy of Jarkko Hietaniemi <[EMAIL PROTECTED]>
Revision Changes Path
1.8 +3 -0 parrot/config/init/hints/dec_osf.pl
Index: dec_osf.pl
===================================================================
RCS file: /cvs/public/parrot/config/init/hints/dec_osf.pl,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -w -r1.7 -r1.8
--- dec_osf.pl 10 Apr 2004 11:51:43 -0000 1.7
+++ dec_osf.pl 30 Jul 2004 13:16:37 -0000 1.8
@@ -11,6 +11,9 @@
if ( $libs !~ /-lpthread/ ) {
$libs .= ' -lpthread';
}
+if ( $libs !~ /-laio/ ) {
+ $libs .= ' -laio';
+}
Configure::Data->set(
libs => $libs,
);
1.3 +15 -0 parrot/config/init/hints/irix.pl
Index: irix.pl
===================================================================
RCS file: /cvs/public/parrot/config/init/hints/irix.pl,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -w -r1.2 -r1.3
--- irix.pl 23 Feb 2004 12:22:51 -0000 1.2
+++ irix.pl 30 Jul 2004 13:16:37 -0000 1.3
@@ -16,3 +16,18 @@
Configure::Data->set(
libs => $libs,
);
+
+my $cc = Configure::Data->get('cc');
+my $cxx = Configure::Data->get('cxx');
+my $ld = Configure::Data->get('ld');
+my $link = Configure::Data->get('link');
+if ( $cc =~ /cc -64/ ) {
+ $cxx = 'CC -64';
+ $ld = 'ld -64';
+ $link = 'CC -64';
+ Configure::Data->set(
+ cxx => $cxx,
+ ld => $ld,
+ link => $link,
+ );
+}
1.99 +8 -1 parrot/include/parrot/parrot.h
Index: parrot.h
===================================================================
RCS file: /cvs/public/parrot/include/parrot/parrot.h,v
retrieving revision 1.98
retrieving revision 1.99
diff -u -w -r1.98 -r1.99
--- parrot.h 13 Jul 2004 14:09:17 -0000 1.98
+++ parrot.h 30 Jul 2004 13:16:40 -0000 1.99
@@ -1,7 +1,7 @@
/* parrot.h
* Copyright: 2001-2003 The Perl Foundation. All Rights Reserved.
* CVS Info
- * $Id: parrot.h,v 1.98 2004/07/13 14:09:17 leo Exp $
+ * $Id: parrot.h,v 1.99 2004/07/30 13:16:40 leo Exp $
* Overview:
* General header file includes for the parrot interpreter
* Data Structure and Algorithms:
@@ -179,6 +179,13 @@
#endif /* __GCC__ */
+/* some SGI compilers have an offsetof()
+ * definition that doesn't work for us. */
+#if defined(__sgi) && defined(_COMPILER_VERSION) && (_COMPILER_VERSION >= 400)
+#undef offsetof
+#define offsetof(s, m) (size_t)(&(((s *)0)->m))
+#endif
+
/* work around warning:
* cast discards qualifiers from pointer target type
* for usage grep e.g. in string.c
1.212 +2 -2 parrot/src/string.c
Index: string.c
===================================================================
RCS file: /cvs/public/parrot/src/string.c,v
retrieving revision 1.211
retrieving revision 1.212
diff -u -w -r1.211 -r1.212
--- string.c 29 Jul 2004 06:56:35 -0000 1.211
+++ string.c 30 Jul 2004 13:16:43 -0000 1.212
@@ -1,6 +1,6 @@
/*
Copyright: 2001-2003 The Perl Foundation. All Rights Reserved.
-$Id: string.c,v 1.211 2004/07/29 06:56:35 leo Exp $
+$Id: string.c,v 1.212 2004/07/30 13:16:43 leo Exp $
=head1 NAME
@@ -258,7 +258,7 @@
data_dir = const_cast(DEFAULT_ICU_DATA_DIR);
string_set_data_directory(data_dir);
if (free_data_dir)
- mem_sys_free(data_dir);
+ mem_sys_free((void*)data_dir); /* cast away the constness */
/*
encoding_init();
chartype_init();