Skip to content
This repository was archived by the owner on Feb 4, 2023. It is now read-only.
This repository was archived by the owner on Feb 4, 2023. It is now read-only.

Main class not found #123

@kerner1000

Description

@kerner1000

I'm submitting a…

  • bug report
  • feature request
  • other

Short description of the issue/suggestion:

Error: Could not find or load main class com.kerner1000.myapp.Launcher
Caused by: java.lang.ClassNotFoundException: com.kerner1000.myapp.Launcher

My Info.plist looks like this:

    <key>JavaX</key>
    <dict>
        <key>MainClass</key>
        <string>com.kerner1000.myapp.Launcher</string>
        <key>ClassPath</key>
        <array>
            <string>Java/myapp-0.6.4-SNAPSHOT.jar</string>
        </array>
        <key>WorkingDirectory</key>
        <string>$APP_PACKAGE/Contents/Resources</string>
        <key>JVMOptionsFile</key>
        <string>$APP_PACKAGE/Contents/Resources/MyApp.l4j.ini</string>
        <key>RelocateJar</key>
        <true/>
    </dict>

MANIFEST.MF inside the jar:

Manifest-Version: 1.0
Created-By: Maven JAR Plugin 3.2.2
Build-Jdk-Spec: 18
Implementation-Title: MyApp
Implementation-Version: 0.6.4-SNAPSHOT
Main-Class: org.springframework.boot.loader.JarLauncher
Start-Class: com.kerner1000.myapp.Launcher
Spring-Boot-Version: 2.7.1
Spring-Boot-Classes: BOOT-INF/classes/
Spring-Boot-Lib: BOOT-INF/lib/
Spring-Boot-Classpath-Index: BOOT-INF/classpath.idx
Spring-Boot-Layers-Index: BOOT-INF/layers.idx

If I execute java -jar target/MyApp/MyApp.app/Contents/Resources/Java/myapp-0.6.4-SNAPSHOT.jar directly, the app starts normally.

Please tell us about your environment:

  • universalJavaApplicationStub version: latest from repository
  • macOS version: 12.4
  • Java version(s): 18

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions