← Back to team overview

openjdk team mailing list archive

Bug#517338: Bug#517338: openjdk-6-jre: /usr/lib/jni not in library path

 

tags 517338 + patch
kthxbye

On Mon, Mar 16, 2009 at 08:45:05AM +0100, Matthias Klose wrote:
brian m. carlson schrieb:
According to Debian Java Policy[0], /usr/lib/jni *must* be in the
default library path, but it isn't:

I have never seen a rationale for this policy, but it's there ... I'd like to
downgrade it, other VM's like sun-java[56] don't honor it as well. Care to send
a patch?

Well, whether it's honored or not by JVMs, other packages are relying on
it[0].  I'd prefer that you not downgrade it, since it is mandated by
policy; if the policy changes, then feel free to downgrade it (and clone
this bug to libunixsocket-java, stating that it needs to put its shared
library somewhere else).

A patch (to one of the IcedTea patches) is enclosed; this should
search /usr/lib{64,}/jni before the normal system directories, but I
haven't tested it.  If you really want me to bootstrap it, let me know;
I won't be able to get to it any sooner than to-morrow.

[0] gcj has this path in its java.library.path; in fact, other than the
gcj-specific directory, that's the only directory that's in there.

--
brian m. carlson / brian with sandals: Houston, Texas, US
+1 713 440 7475 | http://crustytoothpaste.ath.cx/~bmc | My opinion only
troff on top of XML: http://crustytoothpaste.ath.cx/~bmc/code/thwack
OpenPGP: RSA v4 4096b 88AC E9B2 9196 305B A994 7552 F1BA 225C 0223 B187
--- openjdk-6-6b14-1.5~pre1/patches/icedtea-lib64.patch.old	2009-03-16 18:04:37.000000000 +0000
+++ openjdk-6-6b14-1.5~pre1/patches/icedtea-lib64.patch	2009-03-16 18:05:31.000000000 +0000
@@ -7,9 +7,9 @@
 -#define DEFAULT_LIBPATH	"/lib:/usr/lib"
 +
 +#if defined(AMD64) || defined(_LP64) && (defined(PPC) || defined(S390))
-+#define DEFAULT_LIBPATH "/usr/lib64:/lib64:/lib:/usr/lib"
++#define DEFAULT_LIBPATH "/usr/lib64/jni:/usr/lib/jni:/usr/lib64:/lib64:/lib:/usr/lib"
 +#else
-+#define DEFAULT_LIBPATH	"/lib:/usr/lib"
++#define DEFAULT_LIBPATH	"/usr/lib/jni:/lib:/usr/lib"
 +#endif
  
  #define EXTENSIONS_DIR	"/lib/ext"

Attachment: signature.asc
Description: Digital signature


References