Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: Xcode based app bundle and code signing #1693

Closed
wants to merge 6 commits into from

Conversation

mentlerd
Copy link
Contributor

@mentlerd mentlerd commented May 20, 2024

Problem description

ImHex runs as full trust application on macOS with a non-compliant application bundle layout.

Implementation description

This PR introduces Xcode based application bundle generation, including code signing. Using Xcode ImHex can be built into a compliant application bundle with:

rm -r build
cmake --preset xcode -DCMAKE_PREFIX_PATH="$(brew --prefix llvm@17)"
cmake --build build/xcode
open build/xcode/Debug/imhex.app

Additionally, the resulting bundle can be adhoc code-signed and sandboxed by adding the CMake setting:

IMHEX_ENABLE_SANDBOXING_XCODE=YES

To make the application's bundle fully compliant fully compliant with the bundle spec the code had to be changed slightly:

Resources have moved from the Contents/MacOS directory to Contents/Resources, plugins have moved from Contents/MacOS/plugins to Contents/PlugIns as per the spec.

The application will still search for these resources in the original places too to preserve compatibility, and out-of-bundle build support.

Screenshots

image

@codecov-commenter
Copy link

codecov-commenter commented May 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 1.51%. Comparing base (bdaf1e4) to head (eacd28f).

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@          Coverage Diff           @@
##           master   #1693   +/-   ##
======================================
  Coverage    1.51%   1.51%           
======================================
  Files         275     275           
  Lines       27008   27008           
  Branches    14474   14474           
======================================
  Hits          409     409           
  Misses      26341   26341           
  Partials      258     258           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mentlerd mentlerd closed this Aug 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants