|
From: Eoin (Peelmeagrape) <eo...@pe...> - 2004-10-27 15:07:27
|
I am putting together a release of some software. I would like to have
one release that can be launched with wrapper on different platforms.
What I have done so far is as follows (just showing linux and windows):
project/
bin/
wrapper.conf
wrapper.jar
wrapper.license.txt
windows/
wrapper.dll
wrapper.exe
installservice.bat
run.bat
linux/
wrapper
libwrapper.so
run.sh
the intention is to run the sh / bat file for the desired platform and
have them use the same conf file. To do this, i've made the following
settings in the conf file:
wrapper.working.dir=../..
wrapper.java.classpath.1=bin/wrapper.jar
wrapper.java.library.path.1=bin/%PLATFORM%/
wrapper.java.library.path.2=bin/windows/
and edited the script files to set an environment variable PLATFORM to
the name of the platform (windows, linux etc.). To get this to work with
windows service (where the bat file is not run on service start), i also
add the windows folder as a java library path.
run.bat contains:
set PLATFORM=windows
run.sh contains:
PLATFORM="linux"
export PLATFORM
This is all working ok. What I'm wondering is if there's a neater way to
do it (in particular adding the windows folder to library path for all
platforms i don't like). If not, would it be a useful feature for
wrapper to have some feature to make this type of multi-platform
configuration easier?
regards,
Eoin Curran.
|