GWT 1.5 RC1: Hang with bad DISPLAY env variable

26 views
Skip to first unread message

Johan Rydberg

unread,
Jun 2, 2008, 11:21:33 AM6/2/08
to Google-We...@googlegroups.com
Planning to start a new GWT project, I thought it were best to begin
with 1.5 since it what will come.

I hacked up some boilerplate code, organized the my directory structure
and wrote two GWT modules (one for the project, and one for the app).

Fired up the compiler and it nicely prompted that it compiled my module.
But then; nothing. It was sitting there for minutes.

And then suddenly a traceback. See transcript below.

So to the question: why is the compiler trying to connect to my X
server?

$ time java -cp ... com.google.gwt.dev.GWTCompiler -out out myModule
Compiling module myModule
[ERROR] Errors in
'jar:file:.../gwt-linux-1.5.0/gwt-user.jar!/com/google/gwt/user/client/ui/MenuBar.java'
[ERROR] Missing message: compilation_internalError in:
org.eclipse.jdt.internal.compiler.messages
java.lang.InternalError: Can't connect to X11 window server using
'192.168.232.2:0.0' as the value of the DISPLAY variable.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at
sun.awt.X11GraphicsEnvironment.access$100(X11GraphicsEnvironment.java:52)
at
sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:155)
at java.security.AccessController.doPrivileged(Native Method)
at
sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:131)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at
java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:68)
at
java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1135)
at
com.google.gwt.user.rebind.ui.ImageBundleBuilder.drawBundledImage(ImageBundleBuilder.java:450)
at
com.google.gwt.user.rebind.ui.ImageBundleBuilder.writeBundledImage(ImageBundleBuilder.java:319)
at
com.google.gwt.user.rebind.ui.ImageBundleGenerator.generateImplClass(ImageBundleGenerator.java:305)
at
com.google.gwt.user.rebind.ui.ImageBundleGenerator.generate(ImageBundleGenerator.java:159)
at
com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:48)
at
com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.tryRebind(StandardRebindOracle.java:116)
at
com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.rebind(StandardRebindOracle.java:61)
at
com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.java:166)
at
com.google.gwt.dev.GWTCompiler$DistillerRebindPermutationOracle.getAllPossibleRebindAnswers(GWTCompiler.java:195)
at
com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRebinds(WebModeCompilerFrontEnd.java:134)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.process(AbstractCompiler.java:150)
at
org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:392)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompiler.java:84)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompiler.java:180)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.access$400(AbstractCompiler.java:70)
at
com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:493)
at
com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclarations(WebModeCompilerFrontEnd.java:79)
at
com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.<init>(JavaToJavaScriptCompiler.java:296)
at com.google.gwt.dev.GWTCompiler.distill(GWTCompiler.java:353)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:564)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:554)
at com.google.gwt.dev.GWTCompiler.main(GWTCompiler.java:214)

Exception in thread "main" java.lang.InternalError: Can't connect to X11
window server using '192.168.232.2:0.0' as the value of the DISPLAY
variable.
at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
at
sun.awt.X11GraphicsEnvironment.access$100(X11GraphicsEnvironment.java:52)
at
sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:155)
at java.security.AccessController.doPrivileged(Native Method)
at
sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:131)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at
java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:68)
at
java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1135)
at
com.google.gwt.user.rebind.ui.ImageBundleBuilder.drawBundledImage(ImageBundleBuilder.java:450)
at
com.google.gwt.user.rebind.ui.ImageBundleBuilder.writeBundledImage(ImageBundleBuilder.java:319)
at
com.google.gwt.user.rebind.ui.ImageBundleGenerator.generateImplClass(ImageBundleGenerator.java:305)
at
com.google.gwt.user.rebind.ui.ImageBundleGenerator.generate(ImageBundleGenerator.java:159)
at
com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:48)
at
com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.tryRebind(StandardRebindOracle.java:116)
at
com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.rebind(StandardRebindOracle.java:61)
at
com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.java:166)
at
com.google.gwt.dev.GWTCompiler$DistillerRebindPermutationOracle.getAllPossibleRebindAnswers(GWTCompiler.java:195)
at
com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRebinds(WebModeCompilerFrontEnd.java:134)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.process(AbstractCompiler.java:150)
at
org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:392)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompiler.java:84)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompiler.java:180)
at
com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.access$400(AbstractCompiler.java:70)
at
com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:493)
at
com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclarations(WebModeCompilerFrontEnd.java:79)
at
com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.<init>(JavaToJavaScriptCompiler.java:296)
at com.google.gwt.dev.GWTCompiler.distill(GWTCompiler.java:353)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:564)
at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:554)
at com.google.gwt.dev.GWTCompiler.main(GWTCompiler.java:214)

real 3m13.934s
user 0m13.710s
sys 0m0.290s

walden

unread,
Jun 2, 2008, 1:23:14 PM6/2/08
to Google Web Toolkit
You need a -headless option on your command line.

On Jun 2, 11:21 am, Johan Rydberg <johan.rydb...@edgeware.tv> wrote:
> Planning to start a new GWT project, I thought it were best to begin
> with 1.5 since it what will come.
>
> I hacked up some boilerplate code, organized the my directory structure
> and wrote two GWT modules (one for the project, and one for the app).
>
> Fired up the compiler and it nicely prompted that it compiled my module.
> But then; nothing.  It was sitting there for minutes.
>
> And then suddenly a traceback.  See transcript below.
>
> So to the question: why is the compiler trying to connect to my X
> server?
>
> $ time java -cp ... com.google.gwt.dev.GWTCompiler -out out myModule
> Compiling module myModule
> [ERROR] Errors in
> 'jar:file:.../gwt-linux-1.5.0/gwt-user.jar!/com/google/gwt/user/client/ui/M­enuBar.java'
>     [ERROR]  Missing message: compilation_internalError in:
> org.eclipse.jdt.internal.compiler.messages
> java.lang.InternalError: Can't connect to X11 window server using
> '192.168.232.2:0.0' as the value of the DISPLAY variable.
>          at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
>          at
> sun.awt.X11GraphicsEnvironment.access$100(X11GraphicsEnvironment.java:52)
>          at
> sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:155)
>          at java.security.AccessController.doPrivileged(Native Method)
>          at
> sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:131)
>          at java.lang.Class.forName0(Native Method)
>          at java.lang.Class.forName(Class.java:169)
>          at
> java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironmen­t.java:68)
>          at
> java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1135)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleBuilder.drawBundledImage(ImageBund­leBuilder.java:450)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleBuilder.writeBundledImage(ImageBun­dleBuilder.java:319)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleGenerator.generateImplClass(ImageB­undleGenerator.java:305)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleGenerator.generate(ImageBundleGene­rator.java:159)
>          at
> com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:48)
>          at
> com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.tryRebind(StandardRe­bindOracle.java:116)
>          at
> com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.rebind(StandardRebin­dOracle.java:61)
>          at
> com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.j­ava:166)
>          at
> com.google.gwt.dev.GWTCompiler$DistillerRebindPermutationOracle.getAllPossi­bleRebindAnswers(GWTCompiler.java:195)
>          at
> com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRe­binds(WebModeCompilerFrontEnd.java:134)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.process(AbstractCompil­er.java:150)
>          at
> org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:392)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompil­er.java:84)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompil­er.java:180)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.access$400(AbstractCom­piler.java:70)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:493)
>          at
> com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclaratio­ns(WebModeCompilerFrontEnd.java:79)
>          at
> com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.<init>(JavaToJavaScriptComp­iler.java:296)
>          at com.google.gwt.dev.GWTCompiler.distill(GWTCompiler.java:353)
>          at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:564)
>          at com.google.gwt.dev.GWTCompiler.run(GWTCompiler.java:554)
>          at com.google.gwt.dev.GWTCompiler.main(GWTCompiler.java:214)
>
> Exception in thread "main" java.lang.InternalError: Can't connect to X11
> window server using '192.168.232.2:0.0' as the value of the DISPLAY
> variable.
>          at sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
>          at
> sun.awt.X11GraphicsEnvironment.access$100(X11GraphicsEnvironment.java:52)
>          at
> sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:155)
>          at java.security.AccessController.doPrivileged(Native Method)
>          at
> sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:131)
>          at java.lang.Class.forName0(Native Method)
>          at java.lang.Class.forName(Class.java:169)
>          at
> java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironmen­t.java:68)
>          at
> java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1135)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleBuilder.drawBundledImage(ImageBund­leBuilder.java:450)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleBuilder.writeBundledImage(ImageBun­dleBuilder.java:319)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleGenerator.generateImplClass(ImageB­undleGenerator.java:305)
>          at
> com.google.gwt.user.rebind.ui.ImageBundleGenerator.generate(ImageBundleGene­rator.java:159)
>          at
> com.google.gwt.dev.cfg.RuleGenerateWith.realize(RuleGenerateWith.java:48)
>          at
> com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.tryRebind(StandardRe­bindOracle.java:116)
>          at
> com.google.gwt.dev.shell.StandardRebindOracle$Rebinder.rebind(StandardRebin­dOracle.java:61)
>          at
> com.google.gwt.dev.shell.StandardRebindOracle.rebind(StandardRebindOracle.j­ava:166)
>          at
> com.google.gwt.dev.GWTCompiler$DistillerRebindPermutationOracle.getAllPossi­bleRebindAnswers(GWTCompiler.java:195)
>          at
> com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.doFindAdditionalTypesUsingRe­binds(WebModeCompilerFrontEnd.java:134)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.process(AbstractCompil­er.java:150)
>          at
> org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:392)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompil­er.java:84)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.compile(AbstractCompil­er.java:180)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler$CompilerImpl.access$400(AbstractCom­piler.java:70)
>          at
> com.google.gwt.dev.jdt.AbstractCompiler.compile(AbstractCompiler.java:493)
>          at
> com.google.gwt.dev.jdt.WebModeCompilerFrontEnd.getCompilationUnitDeclaratio­ns(WebModeCompilerFrontEnd.java:79)
>          at
> com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.<init>(JavaToJavaScriptComp­iler.java:296)

todd....@gmail.com

unread,
Jun 2, 2008, 1:23:43 PM6/2/08
to Google Web Toolkit
Sorry I do not know much about developing in a *nix environment but
this might help. http://code.google.com/support/bin/answer.py?hl=en&answer=71442

GWT is trying to make an ImageBundle.

On Jun 2, 11:21 am, Johan Rydberg <johan.rydb...@edgeware.tv> wrote:

Ian Petersen

unread,
Jun 2, 2008, 1:23:48 PM6/2/08
to Google-We...@googlegroups.com
On Mon, Jun 2, 2008 at 11:21 AM, Johan Rydberg
<johan....@edgeware.tv> wrote:
> So to the question: why is the compiler trying to connect to my X
> server?

From your stack trace, it looks like you're using ImageBundle. In
case you weren't aware, ImageBundle grabs a bunch of existing image
files and crams them all together into one, larger image file. For
some reason unknown to me, Sun's Java-on-Linux strategy says "graphics
== X". There's probably some cosmic reason for it. Anyway, according
to http://java.sun.com/developer/technicalArticles/J2SE/Desktop/headless/
you can add the following to your command line to make things work:

-Djava.awt.headless=true

I wonder if the compiler could do that for you?

Ian

--
Tired of pop-ups, security holes, and spyware?
Try Firefox: http://www.getfirefox.com

Message has been deleted

nephtys

unread,
Jul 16, 2008, 12:10:40 PM7/16/08
to Google Web Toolkit
test bis

On Jul 16, 6:09 pm, nephtys <nephty...@gmail.com> wrote:
> test
>
> On Jun 2, 5:21 pm, Johan Rydberg <johan.rydb...@edgeware.tv> wrote:
>
> > Planning to start a newGWTproject, I thought it were best to begin
> > with 1.5 since it what will come.
>
> > I hacked up some boilerplate code, organized the my directory structure
> > and wrote twoGWTmodules (one for the project, and one for the app).
Reply all
Reply to author
Forward
0 new messages