use File::Spec;
use strict;
-use vars qw(@ISA @EXPORT);
+use vars qw(@ISA @EXPORT @EXPORT_OK);
require Exporter;
catdir
catfile
curdir
- devnull
rootdir
- tmpdir
updir
no_upwards
file_name_is_absolute
path
+);
+
+@EXPORT_OK = qw(
+ devnull
+ tmpdir
splitpath
splitdir
catpath
rel2abs
);
-foreach my $meth (@EXPORT) {
+foreach my $meth (@EXPORT, @EXPORT_OK) {
+ my $sub = File::Spec->can($meth);
no strict 'refs';
- *{$meth} = File::Spec->can($meth);
+ *{$meth} = sub {&$sub('File::Spec', @_)};
}
catdir
catfile
curdir
- devnull
rootdir
- tmpdir
updir
no_upwards
file_name_is_absolute
path
+
+
+The following functions are exported only by request.
+
+ devnull
+ tmpdir
splitpath
splitdir
catpath