I'm also have this problem and didn't find anywhere how to solve...
Same problem here, with 0.4.5 version. AWT and swing libraries are not working, I'm blocked!!!!
Any workaround?
I think this problem is about the file 「wcepeer.dll」 try to System.loadLibrary("wcepeer"); it's output is : java.lang.UnsatisfiedLinkError: Native library wcepeer' not found (as file wcepeer') in gnu.classpath.boot.library.path and java.library.path but try the another file in the same dir : System.loadLibrary("wcesound"); without throw Exception
My environment is mysaifu 0.4.5 + WinCE 5.0/6.0 this problem's discussion only see after 0.4.5 release cound I get the file 「wcepeer.dll」 in any early version ?
Mysaifu JVM uses some Windows Mobile specific APIs. (SHLoadImageFile() etc.) I think this is a cause of the problem. Windows CE device cannot load the DLL. I don't know how to port Windows Mobile specific DLL to Windows CE device.
The same is happening with version 0.4.7 and am using WinCE 5.0. Is there a workaround? Can't create any window/form so this is a show stopper. Any suggestions?
the Mysaifu JVM has been installed on my PDA with Windows CE 5.00 ,but my java applications can not run on my PDA at all ? this same problem arises.Some one give a suggestion?
Hello,
It's been 10 years since this was posted.
Today I'm having the same problem. Have anyone got a solution for this?
Répondre à hanafi_othman
Hello, It's been 10 years since this was posted. Today I'm having the same problem. Have anyone got a solution for this?
I'm using the latest version of Mysaifu (0.4.8)
Hello,
I am developing a quite simple application for a ATID pocket PC with Windows CE 5.00 and 128 Mb.
The applications consists of a simple frame with some basic components. When Mysaifu tries to paint the frame it causes a 'Exception in thread "Thread-1" java.awt.AWTError: Cannot load AWT toolkit: gnu.java.awt.peer.wce.WCEToolkit' because the JVM does not find the wcepeer library'.
I can assure you that that library exists and is on the correct path (just take a look to the code I give you).
You can find the source code and all the details about the error here:
// -------------- PROGRAM OUTPUT ----------------------
\Program Files\Mysaifu JVM\jre\bin null wcepeer.dll exists. Exception in thread "Thread-1" java.awt.AWTError: Cannot load AWT toolkit: gnu.java.awt.peer.wce.WCEToolkit
Caused by: java.lang.ExceptionInInitializerError
Caused by: java.lang.UnsatisfiedLinkError: Native library wcepeer' not found (as file wcepeer') in gnu.classpath.boot.library.path and java.library.path
JVM exit
//----------------- SOURCE -----------------------------
package vista;
import java.awt.Frame; import java.awt.Rectangle; import java.awt.Label; import java.awt.TextField; import java.awt.TextArea; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.WindowEvent; import java.awt.event.WindowListener; import java.awt.Button; import java.io.File;
public class Vista extends Frame {
private static final long serialVersionUID = 1L; private Label label = null; private TextField textField = null; private TextArea textArea = null; private Button button = null; /** * This method initializes textField * * @return java.awt.TextField */ private TextField getTextField() { if (textField == null) { textField = new TextField(); textField.setBounds(new Rectangle(28, 61, 174, 23)); textField.setText("Campo de texto"); } return textField; }
/** * This method initializes textArea * * @return java.awt.TextArea */ private TextArea getTextArea() { if (textArea == null) { textArea = new TextArea(); textArea.setBounds(new Rectangle(28, 89, 171, 41)); textArea.setText("Campo de texto"); } return textArea; }
/** * This method initializes button * * @return java.awt.Button */ private Button getButton() { if (button == null) { button = new Button(); button.setBounds(new Rectangle(228, 61, 53, 23)); button.setLabel("Cerrar"); button.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent arg0) { System.exit(0); } }); } return button; }
/** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub System.out.println(System.getProperty("java.library.path")); System.out.println(System.getProperty("gnu.classpath.boot.library.path")); File file = new File(System.getProperty("java.library.path") + File.separatorChar + "wcepeer.dll"); if(file.exists()){ System.out.println("wcepeer.dll exists."); }else{ System.out.println("wcepeer.dll doesn't exists!!"); } new Vista(); }
/** * This is the default constructor */ public Vista() { super(); initialize(); setVisible(true); addWindowListener(new WindowListener() { @Override public void windowOpened(WindowEvent e) { // TODO Auto-generated method stub } @Override public void windowIconified(WindowEvent e) { // TODO Auto-generated method stub } @Override public void windowDeiconified(WindowEvent e) { // TODO Auto-generated method stub } @Override public void windowDeactivated(WindowEvent e) { // TODO Auto-generated method stub } @Override public void windowClosing(WindowEvent e) { // TODO Auto-generated method stub } @Override public void windowClosed(WindowEvent e) { // TODO Auto-generated method stub System.exit(0); } @Override public void windowActivated(WindowEvent e) { // TODO Auto-generated method stub } }); }
/** * This method initializes this * * @return void */ private void initialize() { label = new Label(); label.setBounds(new Rectangle(25, 36, 173, 23)); label.setText("Label de prueba"); this.setLayout(null); this.setSize(298, 296); this.setTitle("Frame");
this.add(label, null); this.add(getTextField(), null); this.add(getTextArea(), null); this.add(getButton(), null); }
} // @jve:decl-index=0:visual-constraint="10,1
//------------- ANT FILE ----------------------- <?xml version="1.0" encoding="ISO-8859-1"?> <project name="Frame" basedir="." default="jar">
<attribute name="Main-Class" value="${mainclass}"/> <attribute name="Class-Path" value="${manifest.classpath}"/> </manifest>
</project>
Please, do not hesitate to ask me if you need help.
Thank you, Miguel.