From 8aaffb9f459333e1de483ab2fc32e8e8b891b28a Mon Sep 17 00:00:00 2001 From: Brian Fraser Date: Tue, 12 Nov 2013 01:54:48 -0300 Subject: Remove old cross-compilation model --- configpm | 54 ++++-------------------------------------------------- 1 file changed, 4 insertions(+), 50 deletions(-) (limited to 'configpm') diff --git a/configpm b/configpm index 048da37fa3..5484b188a8 100755 --- a/configpm +++ b/configpm @@ -128,19 +128,10 @@ if ($Opts{chdir}) { my ($Config_SH, $Config_PM, $Config_heavy, $Config_POD); my $Glossary = 'Porting/Glossary'; -if ($Opts{cross}) { - # creating cross-platform config file - mkdir "xlib"; - mkdir "xlib/$Opts{cross}"; - $Config_PM = "xlib/$Opts{cross}/Config.pm"; - $Config_POD = "xlib/$Opts{cross}/Config.pod"; - $Config_SH = "Cross/config-$Opts{cross}.sh"; -} -else { - $Config_PM = "lib/Config.pm"; - $Config_POD = "lib/Config.pod"; - $Config_SH = "config.sh"; -} +$Config_PM = "lib/Config.pm"; +$Config_POD = "lib/Config.pod"; +$Config_SH = "config.sh"; + ($Config_heavy = $Config_PM) =~ s/\.pm$/_heavy.pl/; die "Can't automatically determine name for Config_heavy.pl from '$Config_PM'" if $Config_heavy eq $Config_PM; @@ -1103,43 +1094,6 @@ if ($orig_config_txt ne $config_txt or $orig_heavy_txt ne $heavy_txt) { print "updated $Config_heavy\n"; } - -# Now create Cross.pm if needed -if ($Opts{cross}) { - open CROSS, ">lib/Cross.pm" or die "Can not open >lib/Cross.pm: $!"; - my $cross = <<'EOS'; -# typical invocation: -# perl -MCross Makefile.PL -# perl -MCross=wince -V:cc -package Cross; - -sub import { - my ($package,$platform) = @_; - unless (defined $platform) { - # if $platform is not specified, then use last one when - # 'configpm; was invoked with --cross option - $platform = '***replace-marker***'; - } - #a Perl debugger can load a bunch of modules before -MCross with PERL5DB env - #var, stopping a cross compile Config.pm from being loaded because the native - #Config.pm was already use'd - if(exists $INC{'Config.pm'}) { - warn "Cross.pm found Config.pm is already loaded, reload required, will delete from %INC"; - delete $INC{'Config.pm'}; - } - @INC = map {/\blib\b/?(do{local $_=$_;s/\blib\b/xlib\/$platform/;$_},$_):($_)} @INC; - $::Cross::platform = $platform; -} - -1; -EOS - $cross =~ s/\*\*\*replace-marker\*\*\*/$Opts{cross}/g; - print CROSS $cross; - close CROSS; - print "written lib/Cross.pm\n"; - unshift(@INC,"xlib/$Opts{cross}"); -} - # Now do some simple tests on the Config.pm file we have created unshift(@INC,'lib'); unshift(@INC,'xlib/symbian') if $Opts{cross}; -- cgit v1.2.1