Opened 16 years ago
Closed 16 years ago
#22753 closed defect (fixed)
[derby] DERBY_HOME can not be properly set
| Reported by: | martin.osx@… | Owned by: | blair (Blair Zajac) |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 1.8.1 |
| Keywords: | Cc: | ||
| Port: | derby |
Description
Hello,
one can not set the DERBY_HOME variable propperly in derby. See extract from "/opt/local/bin/derby_common.sh":
[...]
# set DERBY_LIB location
DERBY_LIB="${DERBY_HOME}/lib"
[...]
# set local classpath, don't overwrite the user's
LOCALCLASSPATH=$DERBY_LIB/derby.jar:$DERBY_LIB/derbynet.jar:$DERBY_LIB/derbytools.jar:$DERBY_LIB/derbyclient.jar
[...]
As you can see it is expected that ${DERBY_HOME}/lib/derby.jar exits but derby.jar is installed in /opt/local/share/java/derby.jar.
I suggest that installation is done similar to ant or maven2 which both create a subdirectory in /opt/local/share/java/.
Attachments (1)
Change History (6)
comment:1 Changed 16 years ago by jmroot (Joshua Root)
| Owner: | changed from macports-tickets@… to blair@… |
|---|
comment:2 Changed 16 years ago by blair (Blair Zajac)
comment:3 Changed 16 years ago by martin.osx@…
I noticed some other problems when trying to start a server: Not all shell scripts are installed into bin. I attached a patch which will install all files into /opt/local/share/java/derby and symlinks the shell scripts to /opt/local/bin. This is the same technique used by ant and maven2. It think this is a far better approach.
Martin
comment:4 Changed 16 years ago by blair (Blair Zajac)
I've taken your approach and in r64413 dropped the entire Derby install into ${prefix}/share/derby then set up the appropriate symlinks.
I didn't set up the other tools in bin besides ij, syinfo and dblook. Are all of them needed?
comment:5 Changed 16 years ago by blair (Blair Zajac)
| Resolution: | → fixed |
|---|---|
| Status: | new → closed |
| Summary: | [derby] DERBY_HOME can not be proppery set → [derby] DERBY_HOME can not be properly set |
Please reopen or open a new ticket for additional modifications.

Well, given we're installing Derby into a non-standard install (for it), I think I would rather patch derby_common.sh to change DERBY_LIB to point to the share/java. We don't install any jar's into lib, so we'll have to patch it. Installing all the Derby jar's into a subdirectory, say /opt/local/share/java/derby, won't fix this, we'll have to patch derby_common.sh.
I don't have too many cycles, but if you agree, could you send a patch to have derby_common.sh set DERBY_HOME to $prefix and DERBY_LIB to $DERBY_HOME/share/java.
Regards, Blair