uninstall.bat revision 9da44d3de0a7180285a77b7e8d2426a72aca249e
3112N/A
3112N/A@echo off
3112N/Arem CDDL HEADER START
3112N/Arem
3112N/Arem The contents of this file are subject to the terms of the
3112N/Arem Common Development and Distribution License, Version 1.0 only
3112N/Arem (the "License"). You may not use this file except in compliance
3112N/Arem with the License.
3112N/Arem
3112N/Arem You can obtain a copy of the license at
3112N/Arem trunk/opends/resource/legal-notices/OpenDS.LICENSE
3112N/Arem or https://OpenDS.dev.java.net/OpenDS.LICENSE.
3112N/Arem See the License for the specific language governing permissions
3112N/Arem and limitations under the License.
3112N/Arem
3112N/Arem When distributing Covered Code, include this CDDL HEADER in each
3112N/Arem file and include the License file at
3112N/Arem trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
3112N/Arem add the following below this CDDL HEADER, with the fields enclosed
3112N/Arem by brackets "[]" replaced with your own identifying information:
3112N/Arem Portions Copyright [yyyy] [name of copyright owner]
3112N/Arem
3112N/Arem CDDL HEADER END
5061N/Arem
6273N/Arem
3112N/Arem Portions Copyright 2006-2007 Sun Microsystems, Inc.
4458N/A
4458N/Asetlocal
4458N/A
4458N/Aset DIR_HOME=%~dP0.
3832N/Aset INSTANCE_ROOT=%DIR_HOME%
3832N/A
4458N/A:checkJavaBin
3832N/Aif "%JAVA_BIN%" == "" goto noJavaBin
3832N/Agoto setClassPath
4458N/A
4974N/A:noJavaBin
6308N/Aif "%JAVA_HOME%" == "" goto noJavaHome
4458N/Aif not exist "%JAVA_HOME%\bin\java.exe" goto noJavaHome
5581N/Aset JAVA_BIN=%JAVA_HOME%\bin\java.exe
6308N/Agoto setClassPath
6308N/A
6308N/A:noJavaHome
5580N/Aif not exist "%DIR_HOME%\lib\set-java-home.bat" goto noSetJavaHome
6308N/Acall "%DIR_HOME%\lib\set-java-home.bat"
4978N/Aset JAVA_BIN=%JAVA_HOME%\bin\java.exe
4978N/Agoto setClassPath
6308N/A
4978N/A:noSetJavaHome
5010N/Aecho Error: JAVA_HOME environment variable is not set.
4978N/Aecho Please set it to a valid Java 5 (or later) installation.
3832N/Agoto end
4458N/A
4458N/A:noValidJavaHome
4458N/Aecho ERROR: The detected Java version could not be used. Please set
4458N/Aecho JAVA_HOME to to a valid Java 5 (or later) installation.
4458N/Agoto end
4458N/A
4458N/A:setClassPath
4495N/AFOR %%x in ("%DIR_HOME%\lib\*.jar") DO call "%DIR_HOME%\lib\setcp.bat" %%x
4495N/A
4495N/Aset PATH=%SystemRoot%
4495N/A
4495N/Arem Test that the provided JDK is 1.5 compatible.
4495N/A"%JAVA_BIN%" org.opends.server.tools.InstallDS -t > NUL 2>&1
4458N/Aif not %errorlevel% == 0 goto noValidJavaHome
4458N/A
4458N/Aif "%*" == "" goto callLaunch
4458N/Agoto callJava
4458N/A
4714N/A:callLaunch
4714N/A"%DIR_HOME%\lib\winlauncher.exe" launch "%DIR_HOME%" "%JAVA_BIN%" %JAVA_ARGS% org.opends.quicksetup.uninstaller.UninstallLauncher
4714N/Agoto end
4458N/A
4458N/A:callJava
4458N/A"%JAVA_BIN%" %JAVA_ARGS% org.opends.quicksetup.uninstaller.UninstallLauncher %*
4495N/Agoto end
4458N/A
4458N/A:end
4458N/A