This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
bleadperl DProf.xs:140: warning: `unused' attribute ignored
[perl5.git] / plan9 / genconfig.pl
index edcaf33..30f4af7 100644 (file)
@@ -82,7 +82,8 @@ eunicefix=':'
 hint='none'
 hintfile=''
 intsize='4'
-alignbytes='8'
+longsize='4'
+shortsize='2'
 shrplib='define'
 usemymalloc='n'
 usevfork='true'
@@ -117,7 +118,13 @@ EndOfIntro
 
 # Plan 9 compiler stuff
 print OUT "cc='pcc'\n";
-print OUT "d_attribut='undef'\n";
+print OUT "d_attribute_format='undef'\n";
+print OUT "d_attribute_malloc='undef'\n";
+print OUT "d_attribute_nonnull='undef'\n";
+print OUT "d_attribute_noreturn='undef'\n";
+print OUT "d_attribute_pure='undef'\n";
+print OUT "d_attribute_unused='undef'\n";
+print OUT "d_attribute_warn_unused_result='undef'\n";
 print OUT "d_socket='define'\n";
 print OUT "d_sockpair='define'\n";
 print OUT "d_sigsetjmp='define'\n";
@@ -127,24 +134,26 @@ print OUT "siglongjmp='siglongjmp(buf,retval) '\n";
 print OUT "exe_ext=''\n";
 if ($p9p_objtype eq '386') {
        $objext = '.8';
+       $alignbytes = '4';
+       $cstflags = 2;
 }
 elsif ($p9p_objtype eq '68020') {
        $objext = '.2';
+       $alignbytes = '2';
+       $cstflags = 0;
 }
 elsif ($p9p_objtype eq 'mips') {
        $objext = '.v';
+       $alignbytes = '8';
+       $cstflags = 0;
 }
 elsif ($p9p_objtype eq 'sparc') {
        $objext = '.k';
-}
-print OUT "obj_ext='$objext'\n";
-
-if ($p9p_objtype eq '386') {
-       $cstflags = 2;
-}
-else {
+       $alignbytes = '4';
        $cstflags = 0;
 }
+print OUT "obj_ext='$objext'\n";
+print OUT "alignbytes='$alignbytes'\n";
 print OUT "castflags='$cstflags'\n";
 
 $myname = $ENV{'site'} ;
@@ -258,12 +267,18 @@ foreach (sort keys %val_vars) {
 
 if (open(PL,"${outdir}patchlevel.h")) {
   while (<PL>) {
-    if    (/^#define PATCHLEVEL\s+(\S+)/) { print OUT "PATCHLEVEL='$1'\n"; }
-    elsif (/^#define SUBVERSION\s+(\S+)/) { print OUT "SUBVERSION='$1'\n"; }
+    if    (/^#define PERL_VERSION\s+(\S+)/) {
+      print OUT "PERL_VERSION='$1'\n";
+      print OUT "PATCHLEVEL='$1'\n";           # XXX compat
+    }
+    elsif (/^#define PERL_SUBVERSION\s+(\S+)/) {
+      print OUT "PERL_SUBVERSION='$1'\n";
+      print OUT "SUBVERSION='$1'\n";           # XXX compat
+    }
   }
   close PL;
 }
-else { warn "Can't read ${outdir}patchlevel.h - skipping 'PATCHLEVEL'"; }
+else { warn "Can't read ${outdir}patchlevel.h - skipping 'PERL_VERSION'"; }
 
 print OUT "pager='/bin/p'\n";