my $redir = '2>&1';
$redir = '' if $osname eq 'VMS';
-my $arflags = 'rv';
+# This is the value from src/default.c
+my $arflags = $ostype eq 'aix' ? '-Xany -rv' : '-rv';
my $arvar = "AR=$ar";
# Newer versions of binutils can be built with --enable-deterministic-archives
# which forces all timestamps (among other things) to always be 0, defeating
# GNU make's archive support. See if ar supports the U option to disable it.
unlink('libxx.a');
-$_ = `$ar U$arflags libxx.a a1.o $redir`;
+$_ = `$ar ${arflags}U libxx.a a1.o $redir`;
if ($? == 0) {
- $arflags = 'Urv';
+ $arflags = "${arflags}U";
$arvar = "$arvar ARFLAGS=$arflags";
}
# The number of tests in this category that have passed
$tests_passed = 0;
+$port_type = undef;
+$osname = undef;
+$vos = undef;
+$pathsep = undef;
# Yeesh. This whole test environment is such a hack!
$test_passed = 1;
{
# Set up an initial value. In perl5 we can do it the easy way.
$osname = defined($^O) ? $^O : '';
+ $vos = 0;
+ $pathsep = "/";
# find the type of the port. We do this up front to have a single
# point of change if it needs to be tweaked.
$port_type = 'UNIX';
}
- if ($osname eq 'VMS')
- {
- $vos = 0;
- $pathsep = "/";
+ if ($osname eq 'VMS') {
return;
}
$vos = 1;
$pathsep = ">";
- } else {
+ } elsif ($osname eq '') {
# the following is regrettably gnarly, but it seems to be the only way
# to not get ugly error messages if uname can't be found.
# Hmmm, BSD/OS 2.0's uname -a is excessively verbose. Let's try it
$osname = "(something posixy)";
}
}
- $vos = 0;
- $pathsep = "/";
}
if (! $short_filenames) {