#
-use Config;
+BEGIN { warn "Running ".__FILE__."\n" };
+BEGIN
+ {
+ require "../lib/Config.pm";
+ die "../Config.pm:$@" if $@;
+ Config::->import;
+ }
use File::Compare qw(compare);
use File::Copy qw(copy);
-my $OBJ = 1 if $Config{'ccflags'} =~ /PERL_OBJECT/i;
my $name = $0;
$name =~ s#^(.*)\.PL$#../$1.SH#;
my %opt;
$opt{CONFIG_H} ||= 'config.h';
+warn "Writing $opt{CONFIG_H}\n";
+
my $patchlevel = $opt{INST_VER};
$patchlevel =~ s|^[\\/]||;
$patchlevel =~ s|~VERSION~|$Config{version}|g;
copy("$file.new","../lib/CORE/config.h") || die "Cannot copy:$!";
chmod(0444,"../lib/CORE/config.h");
-if (!$OBJ && compare("$file.new",$file))
+if (compare("$file.new",$file))
{
warn "$file has changed\n";
chmod(0666,$file);