Apache OpenOffice (AOO) Bugzilla – Issue 44154
Java does not work on Mac OS X
Last modified: 2005-06-17 20:32:28 UTC
Environment: Mac OS X: 10.3.8 Tools -> Options -> Java: 1.4.2_05 (Vendor: Apple Computer, Inc.) Issue 1: Loading from CVS qa/qatesttool/global/input/xml_filter/*.xml reports a "Gener Error. Input/Output Error" => These important (MS Word ML, MS Excel ML, XHTML-Export) XSLT based filters needs Java Issue 2: Loading from CVS qa/qatesttool/global/input/java/java.htm => Crash (since 1.1.x it has not been fixed) Issue 3: Loading from CVS File -> Wizards -> Letter (and all other Java written filters) => Nothing happens. To get a Mac OS X OOo 2.0 Beta IMHO this issues has to be fixed because it works fine on all other UNIX also with Java 1.4.*
Issue confirmed.
mh->jl: do you have a hint which area we have to look at ? setting Prio to 1 as major areas do not work.
On my system: iMac:/opt/openoffice.org1.9.82/program oo$ ./javaldx /System/Library/Frameworks/JavaVM.framework/Versions/1.4.2/Home/lib/ppc/client:/System/Library/Frameworks/JavaVM.framework/Versions/1.4.2/Home/lib/ppc/native_threads:/System/Library/Frameworks/JavaVM.framework/Versions/1.4.2/Home/lib/ppc iMac:/opt/openoffice.org1.9.82/program oo$
This can have a lot of reasons. Wrong LD_LIBRARY_PATH, VM start parameters, missing packages. However, this has to be solved in the respective porting projects.
take over.
Eric: please take this issue from me.
Hi, About Issue 3 : letter and fax are now working. I just have made some changes in <http://www.openoffice.org/issues/show_bug.cgi?id=43540> and I'll work intensively on this issue this week : m92 is building with --enable-debug flags (fr / en-US only, because I have no more place on my disk, sorry for de version) Florian, does it matter if I upload en-US version for you ? BTW : isn't this issue somewhere a duplicate of #i43540# ?
Only applying the patch you provided in i43450 does not work for me. Letter and Fax do NOT work. Did you do anything else apart from building with --enable-debug which mustn't change any of the functionality of OOo?
ericb -> fheckl I have noticed it doesn't work for you. Don't know what happens. Do you apply the change while building or before ? Maybe we can declare this issue as duplicated of #i43540# and concentrate in it the infos ? BTW : I'll put new infos in #i43540# -- eric bachard
I continue here. I am testing new changes for java on Mac OSX : first patch concerns jvmfwk_distributions_OpenOffice.org_javavendors.xml.patch -> changed max version for 1.4.2 second patch concerns jvmfwk_plugins_sunmajor_pluginlib.otherjre.cxx.patch : using javaldx, the return gave Linux PPC directories, I know well. Because I don't know why else case don't work, I have added Mac OSX arch. Rebuilding jvmfwk gives now correct directories for java on Mac OSX + PPC cases ? Probably something is buggy here. Florian, can you try, please ? To obtain more information, I have used : ktrace javaldx kdump Of course, I can be wrong, these changes are only experimental tries, like the last patch (ugly workaround to find what happens). FYI, Linux PPC java paths are : $JAVA_HOME/lib/ppc/* ( * = native_threads client .... )
Created attachment 24924 [details] min version1.3.1 max version is 1.4.2 for Java on Mac OSX
Created attachment 24925 [details] workaround to make javaldx happy Mac OSX _experimental_
I found a typo in jvmfwk/plugins/sunmajor/pluginlib/otherjre.cxx MACOX in place of MACOSX ...a new patch is coming
The old patch is no more necessary , just use the last one, and javldx will now correctly recognize java path.
Created attachment 24926 [details] new fix, clean this time, for javaldx / jvmfwk on Mac OSX m92
Issue 3 is solved by creating a symlink from libjava_uno.dylib to libjava_uno.jnilib A more precise error message for Issue 2 is "Apple AWT Java VM was loaded on first thread -- can't start AWT."
ericb -> Florian Thank's for this report : look's like every java lib needs to be .jnilib called, because of the opening method ( java native i.... ). If I understand correctly Fridrich's answer, AWT is in java since 1.3.x at least, so java vm don't work correctly (but partially only). From my side, Issue 3 is not completely solved, because autopillot for agenda don't work (OOo freezes...) To make a point, I'm now building m93 (build will probably end ~ this evening ) and : - jre is changed for 1.4.2 - max version in javavendors.xml is 1.4.2 too - now path for javaldx is correct ( libawt will be found) - what else ?? I really am interested to test... to add a comment, we have to investigate with missing symlink(s), but following give already us a positive answer : - libjava_uno.dylib to libjava_uno.jnilib - libhsqldb2.dylib to libhsqldb2.jnilib And probably others not listed yet will be usefull -- eric bachard
New test with new changes in jvmfwk/plugins/sunmajor/pluginlib/util.cxx where I have changed the one line only : /System/Library/Frameworks/JavaVM.framework/Versions/1.4.2 With the probably more correct : /System/Library/Frameworks/JavaVM.framework/Versions/1.3.1, /System/Library/Frameworks/JavaVM.framework/Versions/1.4.2 This way, I think both 1.3.1 *and* 1.4.2 jre will be available, and all case will work. After more investigations with m93 fr/de/en-US I have uploaded : web page wizard needs jre1.3.1 (just run soffice.bin -> it works) database needs 1.4.2 ( run normally soffice -> it works ) Thank's to Florian for his comments and confirmations. Note : in the second case, 1.4.2 DYLD_LIBRARY_PATH use java_library_path, containing 1.4.2 path. In the first, javaldx return is ignored, so 1.3.1 is used. Don't know if my last change will give what expected. New build always in progress (and cws in a hurry :-/ ), but I cannot commit these changes, nor send a patch before I have myself verified it works. Sorry for the ost time. -- eric bachard
One small correction to Eric's last comment: The web wizard (among other things) apparently needs AWT. The reason it fails with Apple's latest version of Java 1.4.2 is that Apple does not allow the creation of AWT in the main thread as the error message states: "Apple AWT Java VM was loaded on first thread -- can't start AWT." A further problem is that you are only allowed to use that VM in the thread that created it. Otherwise you get a "Bus error". Apple provides some sample code at http://developer.apple.com/samplecode/simpleJavaLauncher/ simpleJavaLauncher.html Unfortunately I have no clue how we can do this in OOo or at least where to start. I tried several things already but did not succeed.
regarding webwezard we should generate a dependent issue. In webwizard there is a "import javax.swing.DefaultListModel" which seems to cause on of the problems.
Created attachment 25183 [details] patch for missing symlinks (libhsqldb2 libjava_uno )
Attached patch works for me : symlinks libhsqldb2.jnilib and libjava_uno.jnilib are really created while installing. I'll commit it in macosx06 asap ericb -> mh About webwizard : I completely agree with you, and I'll open a new issue just for webwizard -- eric bachard
Fixed in macosx06
Verified with my own build
Verified in macosx06
closed