diff --git a/Configure b/Configure index d7f5ef8ce3..cbba1749b5 100755 --- a/Configure +++ b/Configure @@ -980,8 +980,6 @@ while (@argvcopy) if (/^--prefix=(.*)$/) { $config{prefix}=$1; - die "Directory given with --prefix MUST be absolute\n" - unless file_name_is_absolute($config{prefix}); } elsif (/^--api=(.*)$/) { @@ -1440,6 +1438,11 @@ foreach (keys %useradd) { # At this point, we can forget everything about %user and %useradd, # because it's now all been merged into the corresponding $config entry +if ($config{prefix} && !$config{CROSS_COMPILE}) { + die "Directory given with --prefix MUST be absolute\n" + unless file_name_is_absolute($config{prefix}); +} + if (grep { $_ =~ /(?:^|\s)-static(?:\s|$)/ } @{$config{LDFLAGS}}) { disable('static', 'pic', 'threads'); }