[izpack-users] Problem creating shortcuts with Windows (UnsatisfiedLinkError)
Benjamin Hanzelmann
nabcos at gmx.net
Wed Oct 4 15:14:33 CEST 2006
Hi,
I have a (hopefully small ;) problem regarding the creation of shortcuts
for the Windows menu. When I start the installer via "java -jar ..." I
get the following Expection right after the language selection:
U:\>java -jar JavaABC-Installer.jar
could not create shortcut instance
java.lang.Exception: unidentified problem initializing COM
java.lang.UnsatisfiedLinkError: initializeCOM
at com.izforge.izpack.util.os.ShellLink.initialize(ShellLink.java:481)
at com.izforge.izpack.util.os.ShellLink.<init>(ShellLink.java:349)
at com.izforge.izpack.util.os.Win_Shortcut.initialize(Win_Shortcut.java:79)
at com.izforge.izpack.panels.ShortcutPanel.<init>(ShortcutPanel.java:473)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.izforge.izpack.installer.InstallerFrame.loadPanels(InstallerFrame.java:203)
at com.izforge.izpack.installer.InstallerFrame.<init>(InstallerFrame.java:160)
at com.izforge.izpack.installer.GUIInstaller.loadGUI(GUIInstaller.java:391)
at com.izforge.izpack.installer.GUIInstaller.<init>(GUIInstaller.java:128)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at com.izforge.izpack.installer.Installer.main(Installer.java:62)
When I click "Next" until I get to the ShortcutPanel, the panel ist empty and
the following Exception occurs:
java.lang.NullPointerException
at com.izforge.izpack.util.os.Win_Shortcut.getProgramsFolder(Win_Shortcut.java:650)
at com.izforge.izpack.panels.ShortcutPanel.getProgramsFolder(ShortcutPanel.java:641)
at com.izforge.izpack.panels.ShortcutPanel.panelActivate(ShortcutPanel.java:603)
at com.izforge.izpack.installer.InstallerFrame.switchPanel(InstallerFrame.java:463)
at com.izforge.izpack.installer.InstallerFrame.navigateNext(InstallerFrame.java:918)
at com.izforge.izpack.panels.PathInputPanel.actionPerformed(PathInputPanel.java:145)
at com.izforge.izpack.panels.PathSelectionPanel.actionPerformed(PathSelectionPanel.java:162)
at javax.swing.JTextField.fireActionPerformed(Unknown Source)
at javax.swing.JTextField.postActionEvent(Unknown Source)
at javax.swing.JTextField$NotifyAction.actionPerformed(Unknown Source)
at javax.swing.SwingUtilities.notifyAction(Unknown Source)
at javax.swing.JComponent.processKeyBinding(Unknown Source)
at javax.swing.JComponent.processKeyBindings(Unknown Source)
at javax.swing.JComponent.processKeyEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)
at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(Unknown Source)
at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(Unknown Source)
at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(Unknown Source)
at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
The native-Library is configured like this in the installer.xml:
(The complete XML-file is available at
http://lupus.cs.uni-dortmund.de/~hanzelm/installer.xml)
<native type="izpack" name="ShellLink.dll"/>
The dll-file is included in the jar:
hanzelm # jar tf dist/JavaABC-Installer.jar | grep ShellLink
com/izforge/izpack/util/os/ShellLink.class
native/ShellLink.dll
hanzelm #
It works flawlessly with Linux (as far as I can tell), but obviously it
won't need the dll for Linux systems anyway. ;)
When I looked into the izpack-code it seemed like everything was going
fine right down to the JNI-method which calls the dll, but I don't
know any windows or C-programming so I did not go further... The problem
is reproducable for the two windows systems we have here at my workplace.
So the question is:
What am I doing wrong? Help, please, anybody? ;)
Regards,
Benjamin Hanzelmann
More information about the izpack-users
mailing list