0

I have made an application using jpackage. When I try to open the app nothing happens apart from the icon appearing in the dock (bouncing up and down), and after 1 second it closes itself again. However if I run Asteroids.app > Contents > MacOS > Asteroids.exe it works perfectly fine.

What am I doing wrong and how can I fix this?

App contents:

/Applications/Asteroids.app/Contents
├── Info.plist
├── MacOS
│   └── Asteroids.exe
├── PkgInfo
├── Resources
│   └── Asteroids.icns
├── app
│   ├── Asteroids.cfg
│   └── prosjekt_boilerplate-1.0-SNAPSHOT-jar-with-dependencies.jar
└── runtime
    └── Contents
        ├── Home
        ├── Info.plist
        └── MacOS
Viljan
  • 23
  • 6

1 Answers1

0

Your executable works. That is good news. Still from the UI you cannot start the application.

Be aware that the bouncing application icon is a generic animation the window manager provides as user feedback for any kind of application, until the application opens it's window or a timeout occurs. It will even happen if your application was not started at all.

So you need to look at the launch instructions that tell the window manager how to launch your application. If it were a Freedesktop.org thingy I'd say ensure jpackage has some Asteroids.desktop file at hand. On MacOS I am unable to tell whether you need similar files or if all is done in Info.plist.

These two topics may help you going further:

Queeg
  • 7,748
  • 1
  • 16
  • 42