Turn on the perl use strict and use warnings options in the
make_libafs_tree script to better catch programming bugs.
Change-Id: Ide358d40eda3cde9dd0261af11993560da71143a
Reviewed-on: http://gerrit.openafs.org/2266
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
#!/usr/bin/perl
+use strict;
+use warnings;
+
$| = 1;
#
# Build the libafs_tree by reading component list files in the src dir, and copying the
my $quiet = 0;
my $showonly = 0;
+my $treedir;
+my $projdir;
+my $sysname;
+my $ostype;
+my $objdir;
while ( $_ = shift @ARGV )
{
if (m/^-q/) { $quiet = 1; next; }
if (m/^-n/) { $showonly = 1; next; }
- usage;
+ &usage;
}
if ( !$treedir || !$projdir || !$ostype || !$sysname)
{
{
my ($arg) = @_;
return $arg if ( $arg && $arg ne "" );
- usage;
+ &usage;
}
sub mkfullpath
sub copyit
{
my ( $from, $to ) = @_;
- my (@from, @new);
+ my @from;
+ my @new;
+ my @to;
@from = stat($from);
@to = stat($to);