Skip to main content

Build instructions for Sharp Zaurus running pdaXrom

9 replies [Last post]
egoelema
Offline
Joined: 2006-11-16

Hi all,

I've added complete build instructions for the Sharp Zaurus running pdaXrom to the wiki. Hopefully it is of any help to some of you. See http://wiki.java.net/bin/view/Mobileandembedded/PhoneMEAdvancedPlatforms...
I've also succesfully build a gtk version (thanks to the instructions of Hinkmond), but it complains about a missing font. I still have to find out how to solve this (maybe something for a different thread).

greetz,
egoelema

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
yuzhoumao
Offline
Joined: 2007-05-08

Hi egoelema :

I have built phoneme advanced by reading your document by the following command:

make JDK_HOME=/home/software/java/j2sdk1.4.2_14/ J2ME_CLASSLIB=personal AWT_IMPLEMENTATION=peer_based CVM_TARGET_TOOLS_PREFIX=/opt/base/toolchain/arm/3.2.3/bin/arm-linux- HOST_CC=/usr/bin/gcc HOST_CCC=/usr/bin/g++ AWT_PEERSET=gtk CVM_PRELOAD=true USE_MIDP=true USE_JUMP=true USE_GCI=false USE_DIRECTFB=false USE_STATIC_PROPERTIES=true USE_AAPCS=false CVM_JAVA_TOOLS_PREFIX=/home/software/java/j2sdk1.4.2_14/bin/

but I got compiling errors:
Could you give some help?

thanks
regards
Mao

Checking for build-time classes to compile ...
Checking for phoneME Advanced classes to compile ...
Compiling phoneME Advanced classes...
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GButtonPeer.java:40: sun.awt.gtk.GButtonPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GButtonPeer extends GComponentPeer implements ButtonPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GCanvasPeer.java:39: sun.awt.gtk.GCanvasPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GCanvasPeer extends GComponentPeer implements CanvasPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GChoicePeer.java:40: sun.awt.gtk.GChoicePeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GChoicePeer extends GComponentPeer implements ChoicePeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GCheckboxPeer.java:40: sun.awt.gtk.GCheckboxPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GCheckboxPeer extends GComponentPeer implements CheckboxPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GPanelPeer.java:39: sun.awt.gtk.GPanelPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GPanelPeer extends GContainerPeer implements PanelPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GWindowPeer.java:40: sun.awt.gtk.GWindowPeer is not abstract and does not override abstract method setActive() in sun.awt.peer.WindowPeer
class GWindowPeer extends GPanelPeer implements WindowPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GDialogPeer.java:40: sun.awt.gtk.GDialogPeer is not abstract and does not override abstract method setActive() in sun.awt.peer.WindowPeer
class GDialogPeer extends GWindowPeer implements DialogPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GdkGraphics.java:60: sun.awt.gtk.GdkGraphics is not abstract and does not override abstract method drawString(java.text.AttributedCharacterIterator,int,int) in java.awt.Graphics
class GdkGraphics extends Graphics2D implements ConstrainableGraphics {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GdkGraphicsConfiguration.java:40: sun.awt.gtk.GdkGraphicsConfiguration is not abstract and does not override abstract method createCompatibleVolatileImage(int,int) in java.awt.GraphicsConfiguration
class GdkGraphicsConfiguration extends GraphicsConfiguration {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GdkGraphicsDevice.java:33: sun.awt.gtk.GdkGraphicsDevice is not abstract and does not override abstract method getFullScreenWindow() in java.awt.GraphicsDevice
class GdkGraphicsDevice extends GraphicsDevice {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GFileDialogPeer.java:40: sun.awt.gtk.GFileDialogPeer is not abstract and does not override abstract method setActive() in sun.awt.peer.WindowPeer
class GFileDialogPeer extends GDialogPeer implements FileDialogPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GFramePeer.java:49: sun.awt.gtk.GFramePeer is not abstract and does not override abstract method setActive() in sun.awt.peer.WindowPeer
class GFramePeer extends GWindowPeer implements FramePeer, ImageObserver {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GLabelPeer.java:41: sun.awt.gtk.GLabelPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
public class GLabelPeer extends GComponentPeer implements LabelPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GListPeer.java:40: sun.awt.gtk.GListPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GListPeer extends GComponentPeer implements ListPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GScrollPanePeer.java:40: sun.awt.gtk.GScrollPanePeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GScrollPanePeer extends GContainerPeer implements ScrollPanePeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GScrollPanePeer.java:129: setValue(java.awt.Adjustable,int) in sun.awt.gtk.GScrollPanePeer cannot implement setValue(java.awt.Adjustable,int) in sun.awt.peer.ScrollPanePeer; attempting to use incompatible return type
found : void
required: int
public void setValue(Adjustable adj, int v) {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GScrollbarPeer.java:40: sun.awt.gtk.GScrollbarPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GScrollbarPeer extends GComponentPeer implements ScrollbarPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GTextAreaPeer.java:39: sun.awt.gtk.GTextAreaPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GTextAreaPeer extends GTextComponentPeer implements TextAreaPeer {
^
../../src/share/personal/classes/awt/peer_based/sun/awt/gtk/GTextFieldPeer.java:40: sun.awt.gtk.GTextFieldPeer is not abstract and does not override abstract method createVolatileImage(int,int) in sun.awt.peer.ComponentPeer
class GTextFieldPeer extends GTextComponentPeer implements TextFieldPeer {
^
Note: Some input files use or override a deprecated API.
Note: Recompile with -deprecation for details.
19 errors

egoelema
Offline
Joined: 2006-11-16

Hi Mao,

The errors can be resolved by adjusting the classes so that all abstract or interface methods are implemented. For the time being I've just added all missing methods as dummies, not doing anything really.

Unfortunately it's not possible to add attachments here, otherwise I could have added all patches here. Following classes need to be patched:

GButtonPeer
GCanvasPeer
GComponentPeer
GDialogPeer
GdkGraphicsConfiguration
GdkGraphicsDevice
GdkGraphics
GdkGraphicsEnvironment
GPlatformFont
GScrollPanePeer

Hinkmond, if you read this, can I send you the patches, so they can be added to the trunk?

Mao, I hope this will help you out.

Regards,
egoelema

yuzhoumao
Offline
Joined: 2007-05-08

Great!

I have add some methods to the classes by check out the branch of Hinkmond Wong.
svn co
https://phoneme.dev.java.net/svn/phoneme/components/cdc/branches/hinkmon...
cdc

But now there are still 4 errors left:)

Could you send to me by yuzhoumao # gmail.com ?
It is better sending all the java file *.java.

thanks
Mao

yuzhoumao
Offline
Joined: 2007-05-08

All the errors have been removed now by the branch of Hinkmond Wong.
svn co
https://phoneme.dev.java.net/svn/phoneme/components/cd
c/branches/hinkmond-pp-gtk
cdc

But I can not svn ci the change.

Hi Hinkmond, how can I ci the change?

Regards
Thanks
Mao

> Great!
>
> I have add some methods to the classes by check out
> the branch of Hinkmond Wong.
> svn co
> https://phoneme.dev.java.net/svn/phoneme/components/cd
> c/branches/hinkmond-pp-gtk
> cdc
>
> But now there are still 4 errors left:)
>
> Could you send to me by yuzhoumao # gmail.com ?
> It is better sending all the java file *.java.
>
> thanks
> Mao

Hinkmond Wong

these classes are in btclasses.zip, and are properly found there.
phonemeadvanced@mobileandembedded.org wrote:
> All the errors have been removed now by the branch of Hinkmond Wong.
> svn co
> https://phoneme.dev.java.net/svn/phoneme/components/cd
> c/branches/hinkmond-pp-gtk
> cdc
>
> But I can not svn ci the change.
>
> Hi Hinkmond, how can I ci the change?

Hi Mao,

This is great news! Please sign and return the following contributor's
form:

https://mobileandembedded.dev.java.net/content/sca.html

Let me know when you have completed it and how you sent it back (postal
mail, fax, or e-mail)

Then follow these instructions to package your changes to check in your
code:
https://mobileandembedded.dev.java.net/content/contribute.html#submit

You can use me as your contribution sponsor (hinkmond@dev.java.net).

Let me know if you have any problems or questions with this process.

Thanks very much for your help on this!
Hinkmond

>
> Regards
> Thanks
> Mao
>
>> Great!
>>
>> I have add some methods to the classes by check out
>> the branch of Hinkmond Wong.
>> svn co
>> https://phoneme.dev.java.net/svn/phoneme/components/cd
>> c/branches/hinkmond-pp-gtk
>> cdc
>>
>> But now there are still 4 errors left:)
>>
>> Could you send to me by yuzhoumao # gmail.com ?
>> It is better sending all the java file *.java.
>>
>> thanks
>> Mao
> [Message sent by forum member 'yuzhoumao' (yuzhoumao)]
>
> http://forums.java.net/jive/thread.jspa?messageID=221423
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: advanced-unsubscribe@phoneme.dev.java.net
> For additional commands, e-mail: advanced-help@phoneme.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: advanced-unsubscribe@phoneme.dev.java.net
For additional commands, e-mail: advanced-help@phoneme.dev.java.net

Hinkmond Wong

phonemeadvanced@mobileandembedded.org wrote:
> Hi all,
>
> I've added complete build instructions for the Sharp Zaurus running pdaXrom to the wiki. Hopefully it is of any help to some of you. See http://wiki.java.net/bin/view/Mobileandembedded/PhoneMEAdvancedPlatforms...
> I've also succesfully build a gtk version (thanks to the instructions of Hinkmond), but it complains about a missing font. I still have to find out how to solve this (maybe something for a different thread).
>

Very nice work on the Zaurus MIDP/PP/CDC build instructions for phoneME
Advanced! That's an awesome combination to be able to run MIDlets,
Xlets, and applets on a Linux PDA. Very cool!

For the missing font problem, you will probably need to add some extra
font packages on your Ubuntu system, like the ttfonts-free package or
the msttcorefonts package. Does it give a specific font that it says is
missing?

Hinkmond

---------------------------------------------------------------------
To unsubscribe, e-mail: advanced-unsubscribe@phoneme.dev.java.net
For additional commands, e-mail: advanced-help@phoneme.dev.java.net

egoelema
Offline
Joined: 2006-11-16

Hinkmond,

I don't have the missing font problem on the Ubuntu (host) platform but on the Zaurus (target) platform. The message is:

GPLATFORMFONT: (cn) :default
GPLATFORMFONT: (fn) :unknown
java.awt.AWTError: Could not load font set "unknown" and default font "-adobe-courier-medium-r-normal--*-120-*" not present
at sun.awt.gtk.GPlatformFont.init(Native Method)
at sun.awt.gtk.GPlatformFont.(Unknown Source)
at sun.awt.gtk.GFontPeer.(Unknown Source)
at sun.awt.gtk.GFontPeer.getFontPeer(Unknown Source)
at sun.awt.gtk.GToolkit.getFontPeer(Unknown Source)
at java.awt.Font.(Unknown Source)
at.basis.Builder$Status.(Unknown Source)
at basis.Builder.build(Unknown Source)
at basis.DemoFrame.(Unknown Source)
at personal.DemoFrame.(Unknown Source)
at personal.DemoFrame.main(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at sun.misc.CVM.runMain(Unknown Source)

Oh, and by the way, after this exception the JVM hangs. Ctrl+C returns to the prompt.

Any ideas?

Hinkmond Wong

phonemeadvanced@mobileandembedded.org wrote:
> I don't have the missing font problem on the Ubuntu (host) platform but on the Zaurus (target) platform. The message is:
>
> GPLATFORMFONT: (cn) :default
> GPLATFORMFONT: (fn) :unknown
> java.awt.AWTError: Could not load font set "unknown" and default font "-adobe-courier-medium-r-normal--*-120-*" not present
> at sun.awt.gtk.GPlatformFont.init(Native Method)
> at sun.awt.gtk.GPlatformFont.(Unknown Source)
> at sun.awt.gtk.GFontPeer.(Unknown Source)
> at sun.awt.gtk.GFontPeer.getFontPeer(Unknown Source)
> at sun.awt.gtk.GToolkit.getFontPeer(Unknown Source)
> at java.awt.Font.(Unknown Source)
> at.basis.Builder$Status.(Unknown Source)
> at basis.Builder.build(Unknown Source)
> at basis.DemoFrame.(Unknown Source)
> at personal.DemoFrame.(Unknown Source)
> at personal.DemoFrame.main(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at sun.misc.CVM.runMain(Unknown Source)
>

Whoa. That's a new one. I have not run GTK on a Zaurus before, only
the default Qt that is shipped by Sharp. Where are you getting your GTK
lib from for the Zaurus? I suspect it's a problem with either missing
font files in the /usr/X11R6/lib/X11/fonts/ dirs or your default font
should be set to something that the X11 util "xfontsel" can display.
What happens when you run "xfontsel" on the Zaurus? Can you select
"-adobe-courier-medium-r-normal--*-120-*"?

> Oh, and by the way, after this exception the JVM hangs. Ctrl+C returns to the prompt.
>

I'm guessing it's related to you GTK libs on your Zaurus. But, I'm not
familiar with being able to install GTK on a Zaurus so I don't know much
about it. Maybe you can try a Zaurus forum group like
http://www.pdastreet.com/boards/Zaurus/

Hinkmond

---------------------------------------------------------------------
To unsubscribe, e-mail: advanced-unsubscribe@phoneme.dev.java.net
For additional commands, e-mail: advanced-help@phoneme.dev.java.net

egoelema
Offline
Joined: 2006-11-16

> phonemeadvanced@mobileandembedded.org wrote:
> > I don't have the missing font problem on the Ubuntu
> (host) platform but on the Zaurus (target) platform.
> The message is:
> >
> > GPLATFORMFONT: (cn) :default
> > GPLATFORMFONT: (fn) :unknown
> > java.awt.AWTError: Could not load font set
> "unknown" and default font
> "-adobe-courier-medium-r-normal--*-120-*" not present
> > at sun.awt.gtk.GPlatformFont.init(Native
> Method)
> > at sun.awt.gtk.GPlatformFont.(Unknown
> Source)
> > at sun.awt.gtk.GFontPeer.(Unknown Source)
> > at sun.awt.gtk.GFontPeer.getFontPeer(Unknown
> Source)
> > at sun.awt.gtk.GToolkit.getFontPeer(Unknown
> Source)
> > at java.awt.Font.(Unknown Source)
> > at.basis.Builder$Status.(Unknown Source)
> > at basis.Builder.build(Unknown Source)
> > at basis.DemoFrame.(Unknown Source)
> > at personal.DemoFrame.(Unknown Source)
> > at personal.DemoFrame.main(Unknown Source)
> > at java.lang.reflect.Method.invoke(Unknown
> Source)
> > at sun.misc.CVM.runMain(Unknown Source)
> >
>
> Whoa. That's a new one. I have not run GTK on a
> Zaurus before, only
> the default Qt that is shipped by Sharp. Where are
> you getting your GTK
> lib from for the Zaurus?

pdaXrom is a replacement ROM for the original Sharp OS, based on X11 and runs GTK and Qt3 applications. If you haven't seen it, you should really give it a try, just to see what the marvellous piece of Zaurus hardware is really capable of doing.

> I suspect it's a problem with either missing
> font files in the /usr/X11R6/lib/X11/fonts/ dirs or
> your default font
> should be set to something that the X11 util
> "xfontsel" can display.
> What happens when you run "xfontsel" on the Zaurus?
> Can you select
> -adobe-courier-medium-r-normal--*-120-*"?

No, the -adobe-courier-medium-r-normal--*-120-* cannot be selected in xfontsel, although other fonts and combinations are possible. Looking into the code, the -adobe-courier-medium-r-normal--*-120-* font is hard-coded in a few places. I'll try to replace it with one available on my machine, just to see if this resolves the problem.

> > Oh, and by the way, after this exception the JVM
> hangs. Ctrl+C returns to the prompt.
> >
>
> I'm guessing it's related to you GTK libs on your
> Zaurus. But, I'm not
> familiar with being able to install GTK on a Zaurus
> so I don't know much
> about it. Maybe you can try a Zaurus forum group
> like
> http://www.pdastreet.com/boards/Zaurus/
>

I will try running cvm through strace to see where it hangs or loops. If it's gtk related i'll post a message in the most active Zaurus forum at http://www.oesf.org/forums/ ;-)

Thanks for your suggestions.

>
> Hinkmond
>
> ------------------------------------------------------
> ---------------
> To unsubscribe, e-mail:
> advanced-unsubscribe@phoneme.dev.java.net
> For additional commands, e-mail:
> advanced-help@phoneme.dev.java.net