projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
PR: 2234
[openssl.git]
/
tools
/
c_rehash.in
diff --git
a/tools/c_rehash.in
b/tools/c_rehash.in
index 96a73aeedd835c220d41053322770e8ec2b05b3f..bfc4a69ed4bcd8cb384a9bdc1d445bfcdd9b367c 100644
(file)
--- a/
tools/c_rehash.in
+++ b/
tools/c_rehash.in
@@
-7,6
+7,7
@@
my $openssl;
my $dir;
my $openssl;
my $dir;
+my $prefix;
if(defined $ENV{OPENSSL}) {
$openssl = $ENV{OPENSSL};
if(defined $ENV{OPENSSL}) {
$openssl = $ENV{OPENSSL};
@@
-24,13
+25,14
@@
if (defined(&Cwd::getcwd)) {
}
my $path_delim = ($pwd =~ /^[a-z]\:/i) ? ';' : ':'; # DOS/Win32 or Unix delimiter?
}
my $path_delim = ($pwd =~ /^[a-z]\:/i) ? ';' : ':'; # DOS/Win32 or Unix delimiter?
-$ENV{PATH}
.= "$path_delim$dir/bin";
+$ENV{PATH}
= "$prefix/bin" . ($ENV{PATH} ? $path_delim . $ENV{PATH} : ""); # prefix our path
if(! -x $openssl) {
my $found = 0;
foreach (split /$path_delim/, $ENV{PATH}) {
if(-x "$_/$openssl") {
$found = 1;
if(! -x $openssl) {
my $found = 0;
foreach (split /$path_delim/, $ENV{PATH}) {
if(-x "$_/$openssl") {
$found = 1;
+ $openssl = "$_/$openssl";
last;
}
}
last;
}
}