You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-user@db.apache.org by Hemant Gaur <hg...@interwoven.com> on 2007/04/13 13:18:25 UTC

DERBY_HOME for UNIX

derby version db-derby-10.2.1.6-bin
 
For UNIX the default scripts need DERBY_HOME to be set.
==================================================
bash-2.05# ./ij
Error: DERBY_HOME is not set. Please set the DERBY_HOME environment
variable
to the location of your Derby installation.
bash-2.05# export DERBY_HOME=/home/test/derby
bash-2.05# ./ij
DERBY_HOME is set to /home/test/derby
ij version 10.2
ij>
==================================================
This is automatically determined in Windows bats by relating path to the
current dir, but for some unknown reason for the Solaris scripts, the
DERBY_HOME is additionally checked as the first step.
 
Removing this check the derby home is properly set from the
derby_common.sh called in the next step.
 
if [ -z "$DERBY_HOME" ]; then
  echo "Error: DERBY_HOME is not set. Please set the DERBY_HOME
environment variable"
  echo "to the location of your Derby installation."
  exit 1
fi
 
--regards
Hemant 

Re: DERBY_HOME for UNIX

Posted by John Embretsen <Jo...@Sun.COM>.
Hemant Gaur wrote:
> derby version db-derby-10.2.1.6-bin
>  
> For UNIX the default scripts need DERBY_HOME to be set.
[snip demonstration]

> This is automatically determined in Windows bats by relating path to the 
> current dir, but for some unknown reason for the Solaris scripts, the 
> DERBY_HOME is additionally checked as the first step.

You are right, I noticed this difference in behavior (between .bat and .sh 
scripts) when I was working on the related DERBY-2501 [1], but I did not have a 
particular itch for doing anything about it at that time.

> Removing this check the derby home is properly set from the 
> derby_common.sh called in the next step.

Won't the logic for determining the correct path have to be moved from 
derby_common.sh to each top-level script as well?

Anyway, you are free to create a new Jira issue for improving this. I'm sure you 
will get comments if things need to be the way they are for some reason.


-- 
John

[1]: https://issues.apache.org/jira/browse/DERBY-2501