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

Re: Problems with libsvnjavahl under cygwin

From: Patrick Mayweg <mayweg_at_qint.de>
Date: 2005-05-12 13:04:24 CEST

Hi Mathias,
All the JVM crashes I know produce some kind of output. Did you run the
java.exe from a dos box? From my personal point of view, I would prefer
if you use the precompiled versions.
Regards,
Patrick

Mathias.Weinert@gfa-net.de wrote:

>
> Hi there,
>
> I am trying to build (and use) libsvnjavahl under cygwin and
> encountered several problems. I was able to solve some of them but not
> all. Perhaps anyone has an idea what I can do.
>
> Here is what I do:
> First I build APR from the sources 0.9.6 (as I did some patches to it).
> Then I build subversion from the sources (revision 14694 from
> branches/1.2.x) under cygwin which works fine.
> After doing some patches to srcipts and sources (see below) I was able
> to build cygsvnjavahl-1-0.dll but unfortunately it doesn't work. When
> I say (in a Java program) 'SVNClient client = new SCNClien( );' the
> SVNClient class loads the library and the Java program terminates
> without telling me anything about an exception or something like this.
> This happens if I tell the SVNClient class to also search for
> cygsvnjavahl-1-0, if I rename the dll to svnjavahl.dll and if I set
> subversion.native.library to /path/to/dll/cygsvnjavahl-1-0.dll (or
> c:\path\to\dll\cygsvnjavahl-1-0.dll).
> If I use the windows libsvnjavahl-1.dll instead, everything works fine
> (without changing anything else).
>
> Does anybody have an idea why it doesn't work?
> Is there anybody who managed to build and use the library under cygwin?
> FYI: As I don't have java under cygwin I have to use my win32 Java
> (jdk 1.4.2_03). May this be the cause of the problem?

This may definitely be the problem.

>
> Perhaps it has something to do with the already mentioned patches I
> did. Here they are:
>
> Problem: libsvnjavahl needs threads in APR but under cygwin APR is
> always build without threads
> Solution: I told APR not to forbid to use threads under cygwin and
> managed to build it with threads enabled.
> I know that there are certainly some facts that lead to the conclusion
> "don't build APR with threads under cygwin". But may this be the cause
> for my problem?
>
> Problem: Compile problems regarding the JDK include file win32/jni_md.h
> Solution: I changed the typedef of jlong in include/win32/jni_md.h:
> -typedef __int64 jlong;
> +typedef long long jlong;
>
> Problem: libsvnjavahl needs libsvn_fs (shouldn't this be a problem for
> everyone, even if you aren't using cygwin???)
> Solution:
> --- build.conf.orig 2005-05-09 08:17:55.000000000 +0200
> +++ build.conf 2005-05-10 17:53:14.354796500 +0200
> @@ -417,7 +417,7 @@
> description = Subversion Java HighLevel binding
> type = lib
> path = subversion/bindings/java/javahl/native
> -libs = libsvn_repos libsvn_client libsvn_wc libsvn_ra libsvn_delta
> libsvn_subr
> +libs = libsvn_fs libsvn_repos libsvn_client libsvn_wc libsvn_ra
> libsvn_delta libsvn_subr
> aprutil apriconv apr neon
> sources = *.cpp *.c
> add-deps = $(javahl_javah_DEPS) $(javahl_java_DEPS)
>
> Problem/Solution: As I am using win32 Java I had to change the syntax
> of the -classpath option in Makefile.in and
> build/generator/gen_make.py. I enclosed it in " " and I have to use
> ';' instead of ':'
>
> Problem: I mustn't use absolute paths names for the javac compile
> Solution:
> --- build/generator/gen_make.py.orig 2005-03-22
> 16:08:25.000000000 +0100
> +++ build/generator/gen_make.py 2005-05-10 17:53:58.323265100
> +0200
> @@ -146,8 +146,7 @@
> # link in the object file
> objects.append(link_dep.filename)
> for dep in self.graph.get_sources(gen_base.DT_OBJECT,
> link_dep, gen_base.SourceFile):
> - object_srcs.append(
> - build_path_join('$(abs_srcdir)', dep.filename))
> + object_srcs.append(dep.filename)
> elif isinstance(link_dep, gen_base.HeaderFile):
> # link in the header file
> # N.B. that filename_win contains the '_'-escaped class name
>
> I would be very greatful if anybody could help me.
>
> Mathias

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu May 12 13:06:11 2005

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.