[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: java package and MacOS
From: |
Ben Abbott |
Subject: |
Re: java package and MacOS |
Date: |
Wed, 12 Dec 2012 21:18:12 -0500 |
On Nov 27, 2012, at 10:31 PM, Ben Abbott wrote:
> On Nov 27, 2012, at 10:23 PM, Michael Goffioul wrote:
>
>> On Tue, Nov 27, 2012 at 10:18 PM, Ben Abbott <address@hidden> wrote:
>>
>> On Nov 27, 2012, at 10:01 PM, Daniel J Sebald wrote:
>>
>>> On 11/27/2012 08:45 PM, Ben Abbott wrote:
>>>>
>>>> On Nov 27, 2012, at 6:14 PM, Daniel J Sebald wrote:
>>> [snip]
>>>>> Well, if you have Java on your system (which I assume is the case if you
>>>>> do any web browsing...type "java" or "javac" at a shell command line to
>>>>> confirm) then this should be a configuration issue (emphasis "should").
>>>>> Java is supposed to be a very portable environment.
>>>>>
>>>>> Perhaps your definition of JAVA_HOME is wrong, but in my case I can set
>>>>> JAVA_HOME to any valid directory and "dlgtest(0)" functions properly.
>>>>>
>>>>> Dan
>>>>
>>>> MacOS X has Java. If I understand the problem correctly ,.. the problem
>>>> is that for MacOS X, the GUI loop must be in the main program thread.
>>>> What I'm not sure of is if the GUI loop can support both a Qt and Java (I
>>>> suspect it can not, but don't know).
>>>
>>> Oh, you are running Octave as its GUI? I think several of us have been
>>> running with the --no-gui option.
>>>
>>> I just found out a little while ago that running these Java commands while
>>> inside the GUI doesn't work. Nothing happens or it crashes.
>>>
>>> Dan
>>
>> No. The gui does not work yet on MacOS X.
>>
>> The problem with Qt is not the same as the problem for Java. For the Qt
>> GUI, the main thread includes the GUI loop (at least that is my
>> understanding). The problem for the gui on MacOS X has to do with forking.
>> I get the error below.
>>
>> The process has forked and you cannot use this CoreFoundation functionality
>> safely. You MUST exec().
>> Break on
>> __THE_PROCESS_HAS_FORKED_AND_YOU_CANNOT_USE_THIS_COREFOUNDATION_FUNCTIONALITY___YOU_MUST_EXEC__()
>> to debug.
>>
>> The problem with Java is that the GUI loop is not the main thread, but MacOS
>> requires that the first thread spawned be the main()/GUI thread (I'm not an
>> expert in how Cocoa works, and am only repeating what I've read here and
>> else were).
>>
>> There you obviously have a problem, you can't have Qt and Java running their
>> own GUI loop in the main thread (at least not in a trivial way).
>>
>> Michael.
>
> Maybe I was confused, Does the Java gui loop run in the main thread?
>
> Ben
My tip is now ...
hg tip
changeset: 15777:b8bcb2c7f3e8
tag: tip
user: Rik <address@hidden>
date: Wed Dec 12 16:03:46 2012 -0800
summary: configure.ac: Search for jvm.dll on MingW/Cygwin platforms for
Java.
Running dlgtest(1) results in ...
dlgtest (1)
0 ... STOP
1 ... listdlg tests
2 ... errordlg tests
3 ... warndlg tests
4 ... helpdlg tests
5 ... inputdlg tests
6 ... TeX code tests
Run which test? [0] > 1
2012-12-12 21:11:45.716 octave[78603:2603] Apple AWT Java VM was loaded on
first thread -- can't start AWT.
- test listdlg with selectionmode single. No caption, no prompt.
error: [java] java.lang.InternalError: Can't start the AWT because Java was
started on the first thread. Make sure StartOnFirstThread is not specified in
your application's Info.plist or on the command line
error: called from:
error:
/Users/bpabbott/Development/mercurial/default/sources/scripts/java/listdlg.m at
line 131, column 8
error:
/Users/bpabbott/Development/mercurial/default/sources/scripts/java/dlgtest.m at
line 61, column 6
error:
/Users/bpabbott/Development/mercurial/default/sources/scripts/java/dlgtest.m at
line 30, column 9
Looks like the Java thread isn't main(), but the first thread spawned by main()?
Ben
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: java package and MacOS,
Ben Abbott <=