help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Why is glpk-java.jar not the same across all platforms?


From: glpk xypron
Subject: Re: [Help-glpk] Why is glpk-java.jar not the same across all platforms?
Date: Tue, 01 Jun 2010 08:20:13 +0200

Hello Fabio,

> yes, swapping the files leads to problems. For example when using the .jar
> generated on the Linux machine on my Mac OS X laptop, I get the following
> exception:
> 
> Exception in thread "main" java.lang.UnsatisfiedLinkError:
> org.gnu.glpk.GLPKJNI.GLP_BR_PCH_get()I
>       at org.gnu.glpk.GLPKJNI.GLP_BR_PCH_get(Native Method)

Symbol GLP_BR_PCH is defined in GLPK 4.43 but not in GLPK 4.38.

The problem is not with the jar file but with the dynamic
link library.

Please, check whether the loaded dynamic link library on your
Mac was created with GLPK 4.43.

Multiple versions of the library may exist in different
pathes. It will depend on the configuration of your operating
system in which sequence they will be searched. E.g. on OS X you
can define DYLD_LIBRARY_PATH to add search pathes.

At least on Linux you can list symbols in a dynamic link
library with the following command:

nm --dynamic libglpk_java.so

Look for the following symbol:
Java_org_gnu_glpk_GLPKJNI_GLP_1BR_1PCH_1get

Jar files will be binary different when created on the same
system in different runs.

Size may be subtly different when created with different Java
compilers.

Best regards

Xypron


-------- Original-Nachricht --------
> Datum: Mon, 31 May 2010 19:30:13 +0200
> Betreff: Re: [Help-glpk] Why is glpk-java.jar not the same across all 
> platforms?

> Hi Xypron,
> 
> yes, swapping the files leads to problems. For example when using the .jar
> generated on the Linux machine on my Mac OS X laptop, I get the following
> exception:
> 
> Exception in thread "main" java.lang.UnsatisfiedLinkError:
> org.gnu.glpk.GLPKJNI.GLP_BR_PCH_get()I
>       at org.gnu.glpk.GLPKJNI.GLP_BR_PCH_get(Native Method)
>       at org.gnu.glpk.GLPKConstants.<clinit>(GLPKConstants.java:66)
> 
> This is glpk 4.43 and glpk-java 1.0.13. I think the same error occurs on
> the Linux machine when using the .jar generated on the Mac laptop (I'm not
> at work, so I can't post the exact error message right now). 
> 
> They also have different file sizes:
> 
> -rw-r--r--   1 fabio  staff    49K 31 May 19:18 linux64-glpk-java.jar
> -rw-r--r--   1 fabio  staff    43K 31 May 19:18 mac64-glpk-java.jar
> 
> Best,
> Fabio
> 
> On 31 May 2010, at 19:09, glpk xypron wrote:
> 
> > Hello Fabio,
> > 
> > the jar files created for one version of glpk-java should be
> > completely interchangeable.
> > 
> >> I've successfully compiled glpk and gplk-java
> >> under Mac OS X 64bit and Linux 64bit).
> > Did you experience any problems swaping the jar files?
> > 
> > Best regards
> > 
> > Xypron
> 
> 
> _______________________________________________
> Help-glpk mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/help-glpk

-- 
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01



reply via email to

[Prev in Thread] Current Thread [Next in Thread]