Kathey Marsden wrote:

[EMAIL PROTECTED] wrote:

Knut Anders Hatlen wrote:

-1

All the ksh scripts are have CRLF line terminators and therefore don't
work under unix.

% ksh ij.ksh
ij.ksh[13]: ^M:  not found
ij.ksh[15]: ^M:  not found
ij.ksh[16]: {^M:  not found
ij.ksh[17]:
/tmp/derbyrc/db-derby-10.1.2.0-bin/frameworks/embedded/bin/setEmbeddedCP.ksh^M: not found

In addition, frameworks/readme.html says:

 To use the scripts for a particular framework, modify the scripts as
 necessary and put that framework's bin subdirectory first in your
 path.

This won't work since the scripts don't have the executable bit set.

The quick solution is running this before packaging:

 find . -name "*.ksh" | xargs perl -pi -e 's/\r\n/\n/g'
 find . -name "*.ksh" | xargs chmod 755

The right solution is fixing DERBY-330.
Following up on this, I think the recommended property list at
http://www.apache.org/dev/svn-eol-style.txt contains errors.
Platform-specific files should have platform-specific eol-style, so
that they will be correct for the deployment platform, whatever the
build platform is:

*.bat = svn:eol-style=native  # Should be CRLF
*.sh = svn:eol-style=native # Should be LF

There should also be an entry like this:
*.ksh = svn:eol-style=LF

This sounds like a worthy  showstopper to me and changing the properties
seems right too instead of running a script to fix aup the distribution.
A few questions:
I got around by running  the dos2unix command on the scripts in LINUX.
But definitely not a user-friendly way, hence
would be  useful if the above fixes all such issues.

Should svn:executable also be set for ksh, sh  files?
Yes, that would really helpful to make all the ksh (sh) files
executable, rather than doing the 'ksh ij.ksh" commands.

Maybe not for v10.1.2, but for future:

Won't it help, if instead of setting the DERBY_INSTALL to the actual
installation dir in each script,
we use relative path in the scripts to call setClasspath etc.

OR

in scripts like the ij.ksh, startNetworkServer.ksh (or .bat) etc. we use
the java command with -classpath on the command line like:

java -cp ../../../lib/derbytools.jar org.apache.derby.tools.ij

instead of setting the CLASSPATH everytime.

My $0.02.

Regards,
Rajesh







Reply via email to