Skip to content

Packaging app on Apple Silicon won't run without Rosetta #389

Open
@wheelerlaw

Description

@wheelerlaw

I'm submitting a…

  • bug report
  • feature request
  • other

Short description of the issue/suggestion:

When I try to run an app that I packaged on a Mac with Apple silicon, the app will not run unless Rosetta is installed.

Steps to reproduce the issue/enhancement:

  1. Make sure Rosetta is not installed on your system
  2. Clone this repo: https://github.com/SteelecoSystems/sample-native-app
  3. Run mvn package
  4. Go into Finder, and try to run the app, and it should show the popup asking to install Rosetta.

What is the expected behavior?

It should not ask to install Rosetta, as I have a JDK installed that is universal. If I manually
run the jar using the JDK that gets bundled with the Mac app, it runs fine:

./target/sample-native-app/sample-native-app.app/Contents/PlugIns/jre.jre/Contents/Home/bin/java -jar ./target/sample-native-app/sample-native-app.app/Contents/Resources/Java/sample-native-app-1.0-SNAPSHOT-runnable.jar

What is the current behavior?

A popup appears asking for Rosetta to be installed.

Do you have outputs, screenshots, demos or samples which demonstrate the problem or enhancement?

I can produce one if you are unable to reproduce the issue.

What is the motivation / use case for changing the behavior?

If the Java Runtime running the Jar directly doesn't need Rosetta, then what else is happening with the App that requires it to be installed?

Please tell us about your environment:

  • JavaPackager version: 1.7.5
  • OS version: macOS Sonoma 14.2.1
  • JDK version: 21.0.1 (installed through Homebrew)
  • Build tool:
    • Maven
    • Gradle

Other information (e.g. related issues, suggestions how to fix, links for us to have context)

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions