directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r385001 - in /directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers: izpack/server.init rpm/server.init template.init
Date Sat, 11 Mar 2006 03:57:00 GMT
Author: akarasulu
Date: Fri Mar 10 19:56:57 2006
New Revision: 385001

URL: http://svn.apache.org/viewcvs?rev=385001&view=rev
Log:
making rpm and izpack installers have different scripts since their installation processes
are different

Added:
    directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/izpack/server.init
      - copied, changed from r384991, directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init
    directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/rpm/server.init
      - copied, changed from r384991, directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init
Removed:
    directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init

Copied: directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/izpack/server.init
(from r384991, directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init)
URL: http://svn.apache.org/viewcvs/directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/izpack/server.init?p2=directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/izpack/server.init&p1=directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init&r1=384991&r2=385001&rev=385001&view=diff
==============================================================================
--- directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init
(original)
+++ directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/izpack/server.init
Fri Mar 10 19:56:57 2006
@@ -33,38 +33,49 @@
 
 prog=$"${app} server"
 
+if [ -z "$JAVA_HOME" ] ; then
+  # Set the java path if no JAVA_HOME has been specified by the user
+  # for RPM this will be set to some path.  But izpack installers the
+  # plugin will set this to %JAVA_HOME izpack to change at install time
+  JAVA_HOME=${java.home.variable}
+fi
+
 # OS specific support.  $var _must_ be set to either true or false.
 cygwin=false;
 darwin=false;
 case "`uname`" in
   CYGWIN*) cygwin=true ;;
   Darwin*) darwin=true 
-           if [ -z "$JAVA_VERSION" ] ; then
-             JAVA_VERSION="CurrentJDK"
-           else
-             echo "Using Java version: $JAVA_VERSION"
-           fi
-           if [ -z "$JAVA_HOME" ] ; then
-             JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/$JAVA_VERSION/Home
-           fi
-           ;;
+    if [ -z "$JAVA_VERSION" ] ; then
+      JAVA_VERSION="CurrentJDK"
+    else
+      echo "Using Java version: $JAVA_VERSION"
+    fi
+
+    if [ -z "$JAVA_HOME" ] ; then
+      JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/$JAVA_VERSION/Home
+    fi
+    ;;
   *) 
-           if [ -z "$JAVA_HOME" ] ; then
-              # take a wild guess then the logic execute below
-              JAVA_HOME=/usr/java/j2sdk1.4.2_08
-           fi
+    if [ ! -d "$JAVA_HOME" ] ; then
+      # look for java home in /usr/java
+      if [ -d /usr/java/jre ] ; then
+        JAVA_HOME=/usr/java
+      elif [ `uname` = Linux ] ; then
+        for jdkhome in `find /usr/java/ -type d -regex '.*\/j2sdk1\.4\.2...$' | sort`; do
+          JAVA_HOME=$jdkhome;
+        done
+      fi 
+	 fi
 
-           if [ ! -d "$JAVA_HOME" ] ; then
-             # look for java home in /usr/java
-             if [ -d /usr/java/jre ] ; then
-		JAVA_HOME=/usr/java
-             elif [ `uname` = Linux ] ; then
-                for jdkhome in `find /usr/java/ -type d -regex '.*\/j2sdk1.4.2_0.$' | sort`;
do
-                   JAVA_HOME=$jdkhome;
-                done
-             fi 
-	   fi
-	   ;;
+    if [ ! -d "$JAVA_HOME" ] ; then
+      elif [ `uname` = Linux ] ; then
+        for jdkhome in `find /usr/java/ -type d -regex '.*\/jdk1\.5\.....$' | sort`; do
+          JAVA_HOME=$jdkhome;
+        done
+      fi 
+   fi
+   ;;
 esac
 
 if [ -z "$_${app.caps}_HOME" ] ; then

Copied: directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/rpm/server.init
(from r384991, directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init)
URL: http://svn.apache.org/viewcvs/directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/rpm/server.init?p2=directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/rpm/server.init&p1=directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init&r1=384991&r2=385001&rev=385001&view=diff
==============================================================================
--- directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/template.init
(original)
+++ directory/branches/daemon/1.0/plugin/src/main/resources/org/apache/directory/daemon/installers/rpm/server.init
Fri Mar 10 19:56:57 2006
@@ -33,38 +33,49 @@
 
 prog=$"${app} server"
 
+if [ -z "$JAVA_HOME" ] ; then
+  # Set the java path if no JAVA_HOME has been specified by the user
+  # for RPM this will be set to some path.  But izpack installers the
+  # plugin will set this to %JAVA_HOME izpack to change at install time
+  JAVA_HOME=${java.home.variable}
+fi
+
 # OS specific support.  $var _must_ be set to either true or false.
 cygwin=false;
 darwin=false;
 case "`uname`" in
   CYGWIN*) cygwin=true ;;
   Darwin*) darwin=true 
-           if [ -z "$JAVA_VERSION" ] ; then
-             JAVA_VERSION="CurrentJDK"
-           else
-             echo "Using Java version: $JAVA_VERSION"
-           fi
-           if [ -z "$JAVA_HOME" ] ; then
-             JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/$JAVA_VERSION/Home
-           fi
-           ;;
+    if [ -z "$JAVA_VERSION" ] ; then
+      JAVA_VERSION="CurrentJDK"
+    else
+      echo "Using Java version: $JAVA_VERSION"
+    fi
+
+    if [ -z "$JAVA_HOME" ] ; then
+      JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/$JAVA_VERSION/Home
+    fi
+    ;;
   *) 
-           if [ -z "$JAVA_HOME" ] ; then
-              # take a wild guess then the logic execute below
-              JAVA_HOME=/usr/java/j2sdk1.4.2_08
-           fi
+    if [ ! -d "$JAVA_HOME" ] ; then
+      # look for java home in /usr/java
+      if [ -d /usr/java/jre ] ; then
+        JAVA_HOME=/usr/java
+      elif [ `uname` = Linux ] ; then
+        for jdkhome in `find /usr/java/ -type d -regex '.*\/j2sdk1\.4\.2...$' | sort`; do
+          JAVA_HOME=$jdkhome;
+        done
+      fi 
+	 fi
 
-           if [ ! -d "$JAVA_HOME" ] ; then
-             # look for java home in /usr/java
-             if [ -d /usr/java/jre ] ; then
-		JAVA_HOME=/usr/java
-             elif [ `uname` = Linux ] ; then
-                for jdkhome in `find /usr/java/ -type d -regex '.*\/j2sdk1.4.2_0.$' | sort`;
do
-                   JAVA_HOME=$jdkhome;
-                done
-             fi 
-	   fi
-	   ;;
+    if [ ! -d "$JAVA_HOME" ] ; then
+      elif [ `uname` = Linux ] ; then
+        for jdkhome in `find /usr/java/ -type d -regex '.*\/jdk1\.5\.....$' | sort`; do
+          JAVA_HOME=$jdkhome;
+        done
+      fi 
+   fi
+   ;;
 esac
 
 if [ -z "$_${app.caps}_HOME" ] ; then



Mime
View raw message