use Config;
use File::Basename qw(&basename &dirname);
+use Cwd;
# List explicitly here the variables you want Configure to
# generate. Metaconfig only looks for shell variables, so you
# $startperl
# to ensure Configure will look for $Config{startperl}.
-$file = basename($0);
-$file =~ s/\.PL$//i;
+# This forces PL files to create target in same directory as PL file.
+# This is so that make depend always knows where to find PL derivatives.
+$origdir = cwd;
+chdir(dirname($0));
+$file = basename($0, '.PL');
$file .= '.com' if $^O eq 'VMS';
-chdir("pod") or die "Can't chdir to pod: $!";
open OUT,">$file" or die "Can't create $file: $!";
print "Extracting $file (with variable substitutions)\n";
#############################################################################
# pod2usage -- command to print usage messages from embedded pod docs
#
-# Derived from Tom Christiansen's pod2text script.
-# (with extensive modifications)
-#
-# Copyright (c) 1996 Bradford Appleton. All rights reserved.
+# Copyright (c) 1996-2000 by Bradford Appleton. All rights reserved.
# This file is part of "PodParser". PodParser is free software;
# you can redistribute it and/or modify it under the same terms
# as Perl itself.
B<pod2usage> will read the given input file looking for pod
documentation and will print the corresponding usage message.
-If no input file is specifed than standard input is read.
+If no input file is specified than standard input is read.
B<pod2usage> invokes the B<pod2usage()> function in the B<Pod::Usage>
module. Please see L<Pod::Usage/pod2usage()>.
=head1 AUTHOR
+Please report bugs using L<http://rt.cpan.org>.
+
Brad Appleton E<lt>bradapp@enteract.comE<gt>
Based on code for B<pod2text(1)> written by
close OUT or die "Can't close $file: $!";
chmod 0755, $file or die "Can't reset permissions for $file: $!\n";
exec("$Config{'eunicefix'} $file") if $Config{'eunicefix'} ne ':';
+chdir $origdir;