summaryrefslogtreecommitdiff
path: root/configpm
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2009-09-23 11:59:31 +0100
committerNicholas Clark <nick@ccl4.org>2009-09-23 11:59:31 +0100
commit4e73d6a402bc493d66d19c409c41e1e271c6450b (patch)
tree5461d0ffa21fa7f78b7cbe387bafab9c5bc7e8b8 /configpm
parente27b5b51275a893e82bce85334679ee38d3d6bf8 (diff)
downloadperl-4e73d6a402bc493d66d19c409c41e1e271c6450b.tar.gz
Add a --chdir option to configpm, and use this in the Win32 Makfiles.
A slight Makefile simplification, and another move towards Win32 standardising on running miniperl as $(MINIPERL), which currently is ..\miniperl.exe
Diffstat (limited to 'configpm')
-rwxr-xr-xconfigpm6
1 files changed, 6 insertions, 0 deletions
diff --git a/configpm b/configpm
index 5baed2b99c..5b6a4e68e0 100755
--- a/configpm
+++ b/configpm
@@ -34,6 +34,7 @@ sub usage { die <<EOF }
usage: $0 [ options ]
--cross=PLATFORM cross-compile for a different platform
--no-glossary don't include Porting/Glossary in lib/Config.pod
+ --chdir=dir change directory before writing files
EOF
use strict;
@@ -60,6 +61,7 @@ my %Allowed_Opts = (
'cross' => '', # --cross=PLATFORM - crosscompiling for PLATFORM
'glossary' => 1, # --no-glossary - no glossary file inclusion,
# for compactness
+ 'chdir' => '', # --chdir=dir - change directory before writing files
);
sub opts {
@@ -85,6 +87,10 @@ sub opts {
my %Opts = opts();
+if ($Opts{chdir}) {
+ chdir $Opts{chdir} or die "$0: could not chdir $Opts{chdir}: $!"
+}
+
my ($Config_SH, $Config_PM, $Config_heavy, $Config_POD);
my $Glossary = 'Porting/Glossary';