compile warnings (was Re: Smoke 14756 /pro/3gl/CPAN/perl-current)
[p5sagit/p5-mst-13.2.git] / ext / Encode / Makefile.PL
index 3a26ad8..8a7458c 100644 (file)
@@ -2,7 +2,7 @@ use 5.7.2;
 use strict;
 use ExtUtils::MakeMaker;
 
-my %tables = (8859 => ['ascii.ucm', 'cp1250.ucm', 'koi8-r.ucm' ],
+my %tables = (8859 => ['ascii.ucm', 'cp1250.ucm', 'koi8-r.ucm', 'jis0201.ucm' ],
               EBCDIC  => ['cp1047.ucm','cp37.ucm','posix-bc.ucm'],
               Symbols => ['symbol.ucm','dingbats.ucm'],
              );
@@ -20,7 +20,7 @@ closedir(ENC);
 
 WriteMakefile(
              NAME              => "Encode",
-             VERSION_FROM      => 'lib/Encode.pm',
+             VERSION_FROM      => 'Encode.pm',
              OBJECT            => '$(O_FILES)',
              'dist'            => {
                  COMPRESS      => 'gzip -9f',
@@ -56,7 +56,7 @@ sub post_initialize
     my @files;
     foreach my $table (keys %tables)
     {
-       foreach my $ext (qw($(OBJ_EXT) .c .h .def .fnm))
+       foreach my $ext (qw($(OBJ_EXT) .c .h _def.h .fnm))
     {
        push (@files,$table.$ext);
     }
@@ -69,7 +69,7 @@ sub postamble
 {
     my $self = shift;
     my $dir  = $self->catdir($self->curdir,'Encode');
-    my $str  = "# Encode\$(OBJ_EXT) depends on .h and .def files not .c files - but all written by compile\n";
+    my $str  = "# Encode\$(OBJ_EXT) depends on .h and _def.h files not .c files - but all written by compile\n";
     $str  .= 'Encode$(OBJ_EXT) :';
     foreach my $table (keys %tables)
     {
@@ -93,7 +93,9 @@ sub postamble
                $continuator = '';
            }
        }
-       $str .= "\n\t\$(PERL) compile -o \$\@ -f $table.fnm\n\n";
+        $str .= $^O eq 'VMS' # In VMS quote to preserve case
+            ? qq{\n\t\$(PERL) compile -"Q" -"O" -o \$\@ -f $table.fnm\n\n}
+            : qq{\n\t\$(PERL) compile -Q -O -o \$\@ -f $table.fnm\n\n};
        open (FILELIST, ">$table.fnm")
            || die "Could not open $table.fnm: $!";
        foreach my $file (@{$tables{$table}})