summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Rentz [dr] <daniel.rentz@oracle.com>2010-12-27 12:33:29 +0100
committerDaniel Rentz [dr] <daniel.rentz@oracle.com>2010-12-27 12:33:29 +0100
commit3cc6cf2fac4f8b045a837efed9bbc6fcf9769e60 (patch)
tree5f4384c2530f2d416d732c22275b3a943b50d179
parent81075fee2e420a6e0d654eb6936aa7b4edab1b0b (diff)
parentcd4102b0e7d51f061a341a3b48556cbd057a4cfe (diff)
dr77: rebase to DEV300m96
Notes
split repo tag: sdk_ooo/DEV300_m97 split repo tag: sdk_ooo/DEV300_m98
-rwxr-xr-xodk/configure.pl23
1 files changed, 18 insertions, 5 deletions
diff --git a/odk/configure.pl b/odk/configure.pl
index 789cfac7cd76..e1a1cfb99924 100755
--- a/odk/configure.pl
+++ b/odk/configure.pl
@@ -5,6 +5,7 @@
#
use IO::File;
+use File::Basename;
$main::hostname= $ARGV[0];
$main::sdkpath= $ARGV[1];
@@ -35,7 +36,7 @@ if ( $main::operatingSystem =~ m/darwin/ )
{
# $main::OO_SDK_URE_HOME = `cd $main::sdkpath/../ure-link && pwd`;
} else {
- $main::OO_SDK_URE_HOME = `cd $main::sdkpath/../../ure && pwd`;
+ $main::OO_SDK_URE_HOME = `cd $main::sdkpath/../ure-link && pwd`;
}
chomp($main::OO_SDK_URE_HOME);
@@ -554,15 +555,26 @@ sub resolveLink
{
my $base= shift;
my $link= shift;
- my $linktarget = readlink "$base/$link";
+
+ my $resolvedpath = "$base/$link";
+ my $linktarget = readlink "$resolvedpath";
my $resolvedlink = "";
while ( $linktarget ne "") {
- $link = $linktarget;
- $linktarget = readlink "$base/$link";
+
+ if ( $linktarget =~ m/^\/.*/ )
+ {
+ $resolvedpath = "$linktarget";
+ } else {
+ $resolvedpath = `cd $base/$linktarget; pwd`;
+ chop $resolvedpath;
}
+ $base = dirname("$resolvedpath");
- $resolvedlink = `cd $base/$link; pwd`;
+ $linktarget = readlink "$resolvedpath";
+ }
+
+ $resolvedlink = `cd $resolvedpath; pwd`;
chop $resolvedlink;
return $resolvedlink;
}
@@ -578,6 +590,7 @@ sub searchprog
{
if ( $main::operatingSystem =~ m/darwin/ ) {
$progDir = resolveLink("/System/Library/Frameworks/JavaVM.Framework/Versions", "CurrentJDK");
+
if ( -e "$progDir/$main::OO_SDK_JAVA_BIN_DIR/javac" )
{
return "$progDir/$main::OO_SDK_JAVA_BIN_DIR";