[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

JavaHL problem with 1.4

From: Mark Phippard <markp_at_softlanding.com>
Date: 2006-08-30 17:53:18 CEST

Sorry to be bringing this up late in the cycle. The JavaHL changes
between 1.3 and 1.4 are fairly minor and I was not anticipating any
problems.

The problem I am running into is that I cannot use the JavaHL JAR file
produced with 1.4, with the Subversion 1.3 libraries. I think that this
is something we should try to support.

We include the Java JAR file with Subclipse, but we rely on the user to
get the native libraries using whatever OS-specific distribution mechanism
is appropriate. During the release candidate phase the only way to get
these is to build from source, and even after GA it will not be easy to
get the 1.4 libraries on a lot of platforms for quite a while.

This creates an impossible chick and egg problem for us with Subclipse. We
want to take advantage of 1.4, but if we start including the JAR file,
someone just trying to start Eclipse when they have the Subversion 1.3
libraries installed will just have their JVM crash.

I have debugged and the problem was caused by r20652. Here is the log
message:

JavaHL: Improve handling of the Subversion client's configuration
directory during native library initialization, and API manipulation.

Depends on r20648's bug fix to svn_config_ensure().

[ in subversion/bindings/java/javahl/ ]

* native/SVNClient.cpp
  (setConfigDirectory): When changing the config directory, ensure
   that the config area and templates exist in the new location.

* native/SVNClient.h
  (setConfigDirectory): Document behavior.

* native/JNIUtil.cpp
  (JNIGlobalInit): Remove code block which called svn_config_ensure()
   during library initialization, and errored out on failure.

* src/org/tigris/subversion/javahl/SVNClientInterface.java
  (setConfigDirectory): Document change in behavior.

* src/org/tigris/subversion/javahl/SVNClient.java
  (SVNClient): Call setConfigDirectory() to trigger svn_config_ensure().

Found by: Thiru Kandasamy <thiru@collab.net>
Review by: djames

It is basically one line of code:

            setConfigDirectory(null);

The null must cause the native 1.3 library to crash.

Other than Subclipse providing a custom version of the JavaHL java
library, does anyone have any ideas for how this could be fixed for 1.4
GA?

Mark

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Aug 30 18:25:00 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.