[izpack-users] Problem creating shortcuts withWindows(UnsatisfiedLinkError)

Benjamin Hanzelmann benjamin at hanzelmann.de
Mon Oct 9 14:31:03 CEST 2006

On Mon, Oct 09, 2006 at 11:17:20AM +0200, Bartz, Klaus wrote:
> >Yes, in http://lupus.cs.uni-dortmund.de/~hanzelm/ are all the XML-files
> >used for the installer. The ShellLink.dll is included in the
> >JavaABC-Installer.jar under the name "native/ShellLink.dll".
> 1. If you would create a shortcut to a installed program positioning 
> ShortcutPanel after InstallPanel because the COM classes needs an existent
> file to create the link. Else it fails.

Okay, I reordered.

> 2. If you wold use an xml parser to validate your xml file use the
> same order as in the dtd. Means, write native entry as last.

Okay, I did not think of that -- 
With reordered and valid xml I get the same errors:
(this time at panel activation because of the update, see below)

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.panelActivate(ShortcutPanel.java:600)
        at com.izforge.izpack.installer.InstallerFrame.switchPanel(InstallerFrame.java:576)
        at com.izforge.izpack.installer.InstallerFrame.navigateNext(InstallerFrame.java:1120)
        at com.izforge.izpack.installer.InstallerFrame$NavigationHandler.actionPerformed(InstallerFrame.java:1159)
        at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
        at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
        at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
        at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
        at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
        at java.awt.Component.processMouseEvent(Unknown Source)
        at javax.swing.JComponent.processMouseEvent(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.LightweightDispatcher.retargetMouseEvent(Unknown Source)
        at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
        at java.awt.LightweightDispatcher.dispatchEvent(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)

> >> Works the IzPack installation on the box where 
> >JavaABC-Installer fails?
> >
> >I did not try that, I will give it a go later today...
> With this test you get a hint whether it is a general or a problem of
> your specific installation. Therefore it should be an early test.
> Also tests on other windows boxes with other OS versions are need.

I have only two windows boxes at my workplace, and both show the same
Exception. One is a Windows 2003 Terminalserver, the other a notebook
with XP Professional (I think). I will try to boot my XP Professional
at home this evening. (didn't do that for ages ;)

> It is right that all panels are created just after language dialog. But the
> conclusion that all dependant classes are created at that time is not right.
> See the ShortcutPanel constructor, there is no creation of the class which
> uses the native part. Else in panelActivate the creation will be done
> (see ShortcutPanel.java line 621f).
> You see, there are more than one things which are a little bit quaint
> with point in time of exception and exception contents.

I just updated from svn and now the behaviour is as you expected,
the exceptions are coming at panel activation.

I'll try to get a JDK installed on the terminal server and test building
the installer there next...


More information about the izpack-users mailing list