Am Wed, 08 Jul 2009 16:47:57 +0200 (CEST)
schrieb Helmut Jarausch <jarau...@igpm.rwth-aachen.de>:

> Hi,

Hi,

> I'm in need to use some commercial software (Matlab and Maple) which
> come with their own (probably old) version of Java.
> 
> Now, both of those software packages cannot print, they don't see any
> CUPS printer UNLESS I remove the symlink /usr/lib/libcups.so which
> points to libcups.so.2
> 
> But some GenToo packages do need that link, e.g. x11-lib/qt-gui won't
> install unless that link is there.
> 
> I remember there is a bug with older versions of Java accessing CUPS,
> and probably my commercial packages contain such an old version.
> 
> Does anybody know how to fix or circumvent this.
> (Currently I have to remove the symlink when using one of these
> commercial packages and reinstall it afterwards, but ... for a normal
> user without root priviledges that's not possible unless I write an SUID
> script)

I can't speak for Maple, but for Matlab you can export the variable
$MATLAB_JAVA. I have

mar...@marcec ~ % echo $MATLAB_JAVA 
/usr/lib/jvm/emul-linux-x86-java-1.6

You can check if it worked via "matlab -e" in a shell or with the following
Matlab command:

  EDU>> version('-java')        
  ans =
  Java 1.5.0 with Sun Microsystems Inc. Java HotSpot(TM) Client VM mixed mode

That's the Java that's shipped with my 2007a installation. For comparison,
with $MATLAB_JAVA set as above:

  EDU>> version('-java')
  ans =
  Java 1.6.0_13 with Sun Microsystems Inc. Java HotSpot(TM) Client VM mixed
  mode, sharing

I just tested printing from the editor and it works with the system 32bit JVM,
but not with the shipped one, so it should work for you.

I'm not sure about stability, though. I never used to have problems, but more
or less recently Matlab would SEGFAULT occasionally (even though I set this
variable long before the SEGFAULTs started). While using the shipped JVM, it
never crashed. It could be completely unrelated to the JVM being used, but I
think it's better to be aware of the possibility.

> Thanks for any hints,
> 
> Helmut Jarausch
> 
> Lehrstuhl fuer Numerische Mathematik
> RWTH - Aachen University
> D 52056 Aachen, Germany

HTH
--
Marc Joliet
--
"People who think they know everything really annoy those of us who know we
don't" - Bjarne Stroustrup

Attachment: signature.asc
Description: PGP signature

Reply via email to