Skip to content

#423 Added PKG Installer build for macOS systems#2098

Open
laim2003 wants to merge 11 commits into
devonfw:mainfrom
laim2003:feature/#433-macos-installer
Open

#423 Added PKG Installer build for macOS systems#2098
laim2003 wants to merge 11 commits into
devonfw:mainfrom
laim2003:feature/#433-macos-installer

Conversation

@laim2003

@laim2003 laim2003 commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

This PR fixes #423

Implemented changes:

  • Modifed both release.yml and nightly-build.yaml to build, upload and publish a PKG-based installer. PKG-Installers are the macOS equivalent of MSI files on windows.
  • The installer includes a license agreement and setup instructions.
grafik

A few notes:

  • In this state, I did not add a signature to the installer, as this from what I could tell during the research I did for this issue, this requires an Apple Developer License. So for now, users will most likely have to follow the typical mac gatekeeper workaround by going to "Privacy & Security" in the settings in order to open the installer.
  • Also, this installer currently only supports the installation into the standard "[user]/projects/" path. Giving users the option to choose their own path can be implemented later, as this is a bit more complicated to implement in the macOS PKG installer.

Testing instructions

Disclaimer: Testing this requires a mac.

  1. Do a complete build by copying the commands from release.yml (Tasks: 1. Build native image and then Build MacOS PKG) and running them from /workspaces/main/ideasy/
  2. Uninstall the current version of IDEasy.
  3. As a result of the build, you should find a IDEasy-[versionname].pkg file under /macos-installer
  4. Open the file; an installer window should now show up.
  5. The title of the installer should be "IDEasy - [Version]"
  6. Follow the installer steps. They should include agreeing to IDEasys' license, then it will prompt you wether you really want to install, and then it should show you a "conclusion" screen, that includes a first-steps-instruction page.
  7. After the installation, IDeasy should be installed under the standard /projects/_ide/ folder and the ide command should be usable from the command line.

Retesting:

  1. Download the PKG file that should now be included in the nightly builds and test wether it succesfully installs like above.

Checklist for this PR

Make sure everything is checked before merging this PR. For further info please also see
our DoD.

  • When running mvn clean test locally all tests pass and build is successful
  • PR title is of the form #«issue-id»: «brief summary» (e.g. #921: fixed setup.bat). If no issue ID exists, title only.
  • PR top-level comment summarizes what has been done and contains link to addressed issue(s)
  • PR and issue(s) have suitable labels
  • Issue is set to In Progress and assigned to you or there is no issue (might happen for very small PRs)
  • You followed all coding conventions
  • You have added the issue implemented by your PR in CHANGELOG.adoc unless issue is labeled
    with internal
  • You have formulated clear instructions on how to test your contribution under "Testing instructions"

@github-project-automation github-project-automation Bot moved this to 🆕 New in IDEasy board Jul 1, 2026
@laim2003 laim2003 self-assigned this Jul 1, 2026
@laim2003 laim2003 added install installation process of IDE + tools and install commandlet macOS specific for Apple MacOS labels Jul 1, 2026
@coveralls

coveralls commented Jul 1, 2026

Copy link
Copy Markdown
Collaborator

Coverage Report for CI Build 28707177014

Coverage increased (+0.004%) to 71.836%

Details

  • Coverage increased (+0.004%) from the base build.
  • Patch coverage: No coverable lines changed in this PR.
  • No coverage regressions found.

Uncovered Changes

No uncovered changes found.

Coverage Regressions

No coverage regressions found.


Coverage Stats

Coverage Status
Relevant Lines: 16300
Covered Lines: 12200
Line Coverage: 74.85%
Relevant Branches: 7308
Covered Branches: 4759
Branch Coverage: 65.12%
Branches in Coverage %: Yes
Coverage Strength: 3.17 hits per line

💛 - Coveralls

@laim2003 laim2003 moved this from 🆕 New to 🏗 In progress in IDEasy board Jul 3, 2026
@oanding-blrng oanding-blrng self-assigned this Jul 3, 2026
@laim2003 laim2003 changed the title #433 Added PKG Installer build for macOS systems #432 Added PKG Installer build for macOS systems Jul 3, 2026
@laim2003 laim2003 changed the title #432 Added PKG Installer build for macOS systems #423 Added PKG Installer build for macOS systems Jul 3, 2026
@laim2003 laim2003 force-pushed the feature/#433-macos-installer branch from 4a6b166 to 51a5cc9 Compare July 3, 2026 16:31
@laim2003 laim2003 moved this from 🏗 In progress to Team Review in IDEasy board Jul 4, 2026
@laim2003 laim2003 marked this pull request as ready for review July 4, 2026 13:09
@oanding-blrng

oanding-blrng commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

@laim2003
I'm able to create the PKG installer, but I can't install IDEasy with it. It get the following output from the installer which is fine due to the mentioned lack of the Apple Developer License. But the mac gatekeeper workaround isn't working for me, because the option to allow the specific program doesn't appear. The workaround still works for the traditional way via extracting the .tar.gz and running setup.

Bild 06 07 26 um 10 44

@laim2003

laim2003 commented Jul 6, 2026 via email

Copy link
Copy Markdown
Contributor Author

@OscarVertonix

OscarVertonix commented Jul 6, 2026

Copy link
Copy Markdown

Installation protocol (Error and status messages):

Jul  6 13:26:31 MacBookPro Installer[7862]: @(#)PROGRAM:Install  PROJECT:Install-1000
Jul  6 13:26:31 MacBookPro Installer[7862]: @(#)PROGRAM:Installer  PROJECT:Installer-1359.120.1
Jul  6 13:26:31 MacBookPro Installer[7862]: Hardware: MacBookPro18,1 @ 2.40 GHz (x 10), 32768 MB RAM
Jul  6 13:26:31 MacBookPro Installer[7862]: Running OS Build: macOS 26.5.1 (25F80)
Jul  6 13:26:31 MacBookPro Installer[7862]: IDEasy - 2026.07.001  Installation Log
Jul  6 13:26:31 MacBookPro Installer[7862]: Opened from: /Users/vertonix/projects/IDEasy/workspaces/pr-2098-pkg-installer-macos/IDEasy/macos-installer/IDEasy-2026.07.001.pkg
Jul  6 13:26:31 MacBookPro Installer[7862]: Failed to load specified background image
Jul  6 13:26:31 MacBookPro Installer[7862]: Could not load resource readme: (null)
Jul  6 13:26:36 MacBookPro Installer[7862]: ================================================================================
Jul  6 13:26:36 MacBookPro Installer[7862]: User picked Standard Install
Jul  6 13:26:36 MacBookPro Installer[7862]: Choices selected for installation:
Jul  6 13:26:36 MacBookPro Installer[7862]: 	Installieren: "IDEasy - 2026.07.001"
Jul  6 13:26:36 MacBookPro Installer[7862]: 	Installieren: "(null)"
Jul  6 13:26:36 MacBookPro Installer[7862]: ================================================================================
Jul  6 13:26:38 MacBookPro Installer[7862]: Configuring volume "Macintosh HD"
Jul  6 13:26:38 MacBookPro Installer[7862]: Free space on "Macintosh HD": 237,04 GB (237036875776 bytes).
Jul  6 13:26:38 MacBookPro Installer[7862]: Create temporary directory "/var/folders/7t/bmvv3jrd7k9chztwf_9_spwm0000gn/T//Install.7862P2zivJ"
Jul  6 13:26:38 MacBookPro Installer[7862]: IFPKInstallElement (1 packages)
Jul  6 13:26:38 MacBookPro Installer[7862]: PackageKit: Enqueuing install with framework-specified quality of service (utility)
Jul  6 13:26:38 MacBookPro installd[759]: PackageKit: ----- Begin install -----
Jul  6 13:26:41 MacBookPro installd[759]: PackageKit: Install Failed: Error Domain=PKInstallErrorDomain Code=112 "Beim Ausführen der Skripts aus dem Paket „IDEasy-2026.07.001.pkg“ ist ein Fehler aufgetreten." UserInfo={NSFilePath=./postinstall, NSURL=file:///Users/vertonix/projects/IDEasy/workspaces/pr-2098-pkg-installer-macos/IDEasy/macos-installer/IDEasy-2026.07.001.pkg#IDEasyComponent.pkg, PKInstallPackageIdentifier=com.devonfw.ideasy, NSLocalizedDescription=Beim Ausführen der Skripts aus dem Paket „IDEasy-2026.07.001.pkg“ ist ein Fehler aufgetreten.} {
	    NSFilePath = "./postinstall";
	    NSLocalizedDescription = "Beim Ausf\U00fchren der Skripts aus dem Paket \U201eIDEasy-2026.07.001.pkg\U201c ist ein Fehler aufgetreten.";
	    NSURL = "file:///Users/vertonix/projects/IDEasy/workspaces/pr-2098-pkg-installer-macos/IDEasy/macos-installer/IDEasy-2026.07.001.pkg#IDEasyComponent.pkg";
	    PKInstallPackageIdentifier = "com.devonfw.ideasy";
	}
Jul  6 13:26:42 MacBookPro Installer[7862]: Install failed: Die Installation ist aufgrund eines Fehlers fehlgeschlagen. Wende dich an den Hersteller der Software.
Jul  6 13:26:42 MacBookPro Installer[7862]: IFDInstallController 29C0000 state = 8
Jul  6 13:26:42 MacBookPro Installer[7862]: Displaying 'Install Failed' UI.
Jul  6 13:26:42 MacBookPro Installer[7862]: 'Install Failed' UI displayed message:'Die Installation ist aufgrund eines Fehlers fehlgeschlagen. Wende dich an den Hersteller der Software.'.

Last message mentioned a problem with the UI. Maybe the underlying problem here is connected to the nightly build (https://github.com/devonfw/IDEasy/actions/runs/28696754044/job/85107587327).

@laim2003

laim2003 commented Jul 6, 2026

Copy link
Copy Markdown
Contributor Author

@oanding-blrng i quickly pushed a small fix. now, when you look at the installation log, you should see a log message that points to the IDEasy installation log. Also, what size did the installer display when choosing the disk?

@OscarVertonix

Copy link
Copy Markdown

The installtion log:

Looking for IDE_HOME in /private/tmp/PKInstallSandbox.TAVyLP/Scripts/com.devonfw.ideasy.E2YkRS
Looking for IDE_HOME in /private/tmp/PKInstallSandbox.TAVyLP/Scripts
Looking for IDE_HOME in /private/tmp/PKInstallSandbox.TAVyLP
Looking for IDE_HOME in /private/tmp
Looking for IDE_HOME in /private
Looking for IDE_HOME in /
System console not available - using System.in as fallback
Starting step ide with params [install]...
Trying to match arguments to commandlet install
Trying to match argument 'install'
Next property candidate to match argument is KeywordProperty[install:true]
Running commandlet InstallCommandlet[install]
Properties not found at /Users/vertonix/.ide/ide.properties
Properties not found at /Users/vertonix/devon.properties
CONF: Variable IDE_WRITE_LOGFILE is undefined.
WORKSPACE: Variable IDE_WRITE_LOGFILE is undefined.
SETTINGS: Variable IDE_WRITE_LOGFILE is undefined.
USER@/Users/vertonix/.ide/ide.properties: Variable IDE_WRITE_LOGFILE is undefined.
SYSTEM: Variable IDE_WRITE_LOGFILE is undefined.
Cannot enable log-file since IDE_ROOT is undefined.
Detected that IDEasy is running as graalvm native image...
Installing IDEasy from /Library/IDEasy
Missing required file IDEasy.pdf
Step 'ide' ended with failure.
ide (install) failed after PT0.004S

IDEasy release is inconsistent at /Library/IDEasy [artifact=IDEasy.pdf]

The installer is showing 62,5 MB for the size. Although not in the "Choose Disk" but rather in "Installation type". I only have one big partition for the hard drive. I assume, that MacOS and the installer dosn't bother to ask if there is only one possible option to choose.

@OscarVertonix

Copy link
Copy Markdown

For better manual testing I extracted the relevant commands from the jobs of release.yaml into it's own script.

maven_config="$(cat .mvn/maven.config)"
current_version="${maven_config/#*-Drevision=}"
current_version="${current_version/ */}"
next_version="${current_version/-SNAPSHOT/}"
cd cli
mvn -B -ntp -Drevision=${next_version} -Pnative -DskipTests=true package
cd ..

cd documentation
mvn -B -ntp clean install
cd ..
mkdir -p macos-installer/pkg-root/Library/IDEasy/bin
mkdir -p macos-installer/Resources
cp documentation/target/generated-docs/LICENSE.rtf macos-installer/Resources/LICENSE.rtf
cp -r cli/target/package/* macos-installer/pkg-root/Library/IDEasy/
rm -rf macos-installer/pkg-root/Library/IDEasy/system/windows
rm -rf macos-installer/pkg-root/Library/IDEasy/system/linux
cp cli/target/ideasy macos-installer/pkg-root/Library/IDEasy/bin/
chmod +x macos-installer/pkg-root/Library/IDEasy/bin/ideasy
chmod +x macos-installer/scripts/postinstall
cd macos-installer
pkgbuild --root pkg-root --identifier com.devonfw.ideasy \
  --version $next_version --install-location "/" \
  --scripts scripts IDEasyComponent.pkg
sed -i '' "s/\${next_version}/${next_version}/" Distribution.xml
productbuild --distribution Distribution.xml --resources Resources \
  --package-path . IDEasy-$next_version.pkg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

install installation process of IDE + tools and install commandlet macOS specific for Apple MacOS

Projects

Status: Team Review

Development

Successfully merging this pull request may close these issues.

Create installer for MacOS

4 participants