Max 6 Java Standalone Error

django's icon

Hi fellow Maxers,

I have a problem building a standalone with Max 6 on Windows 7 which includes a mxj object. I get the following error message, when opening the standalone:

(mxj) Unable to resolve path of max.jar!mjx is rendered powerless.
•error: Unable to create JVM

I know this issue was mentioned bevore in this forum, for example here:
https://cycling74.com/forums/problems-with-mxj-to-include-in-standalone

But copying the "Cycling'74/Max6.0/Cycling'74/java" folder in the standalone support folder didn't work for me.

Has anyone experienced the same or knows how to solve this?

Thanks a lot - d

django's icon

Anyone?

I tried every solution I could find in the forum, but no success.
I'm working on a project for some time now which includes making a standalone with some java objects. So this is a real bummer.

Any help much appreciated!

Jan M's icon

This is out of the blue, and I am not in from of Max right now, but ...:
... have you checked if the java config file is included and if the pathes inside are correct?

... do the pathnames include space or other characters that need to be escaped?

Jan

django's icon

Hi Jan,

thanks for your reply. I'm not shure what you mean. The max.java.config File is included in the support/java Folder. It looks like this:

; This is the config used by Max when instantiating the JVM ;
; Comments are enclosed within 2 semicolons ;

; The file format is relatively fragile so pay attention ;
; when editing this file !! ;

; some example options one may use ;

; add all jars in /Users/topher/java/lib to the system classpath i.e. immutable classpath ;
; max.system.jar.dir /Users/topher/java/lib;

; add /Users/topher/foo to the system classpath i.e. immutable classpath ;
; max.system.class.dir /Users/topher/foo ;

; these next 2 are typically what you would want to use if you want additional directories ;
; added to your classpath for max ;

; add /Users/topher/myclasses to the dynamic classpath of MXJClassLoader ;
; max.dynamic.class.dir /Users/topher/myclasses ;

; add all jars in /Users/topher/myjars to the dynamic classpath of MXJClassLoader ;
;max.dynamic.jar.dir /Users/topher/myjars ;

; specify some jvm options ;
max.jvm.option -Xincgc
max.jvm.option -Xms64m
max.jvm.option -Xmx256m

; uncomment these options(i.e. remove surrounding semi colons ;
; to cause the JVM to be created ;
; in debug mode and listening for remote debugger connections ;
; on port 8074. This would enable you to interactively debug ;
; your mxj code using JDB or some other debugger which supports ;
; the JDI wire protocol ;

; max.jvm.option -Xdebug ;
; max.jvm.option -Xnoagent ;
; max.jvm.option -Xrunjdwp:transport=dt_socket,address=8074,server=y,suspend=n ;
; max.jvm.option -XX:-UseSharedSpaces ;

Do I have to edit it?

Thanks - D

Jan M's icon

Sorry misread your text ist's max.jar that couldn't be found.
No in that case you definitely should not edit this file....

2.) You are you on Max 6

I tried to build a standalone and a java class in max 6 on win XP and it fails as well. The same patch works fine on Max 5!

That's a Bug I'd say!

Jan

Jan M's icon

just saw that 6.0.4 is released - maybe it's already fixed...

Jan M's icon

... one more: restarted the computer and now it works here also on 6.0.3 ... so not a bug ;)

django's icon

Hi Jan,

thanks again for your time. Yes I copied all the files mentioned in the link.
I guess I'll try contacting the support for this.

Cheers - D

django's icon

Ok, for anyone running into this problem as well.
I solved it with the great support from cycling (thank you Andrew).

I was building the standalone on my boot drive. When I tried building it on my secondary drive the error message disappeared...

Roth's icon

I was building the standalone on my boot drive. When I tried building it on my secondary drive the error message disappeared...

That's funny, I seem to remember the opposite being true of some version of Max5, except no error messages (standalones built anywhere but the boot volume just wouldn't launch).

Roth's icon

Oops, just woke up when I posted and forgot this thread was about Java (stupid I know as it is in the title). My last post doesn't exactly relate I suppose.

pdelges's icon

Roth, you're right. Years ago, building a standalone on another partition than the boot one didn't work well, there were some permissions problems deep in the package and the app didn't launch. So now I always build my standalone on my desktop and never checked wether this bug is finally corrected.

Not sure everybody has a second drive to build standalones...

p

thispatcher's icon

Hi!

I am also having this problem. I tried building the app on another drive, but it's still not working.

:( ANyone else have other thoughts?