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

macOS: Add cmake based app bundle generation for mythfrontend #1015

Merged
merged 12 commits into from
Jan 16, 2025

Conversation

jhoyt4
Copy link
Contributor

@jhoyt4 jhoyt4 commented Jan 4, 2025

Multiple commits, but the main commits:

for general macOS use:

  • Fix RUNPREFIX for Bundled Applications
  • Update darwin python path for several executables

in cmake (macOS dependant):

  • Update homebrew logic to use homebrews "@" naming convention
  • Add cmake based app bundling and signing
  • copy any python virtual environment files to the install prefix

general cmake tidy:
-Quiet warning on add_custom_command without build stage

Checklist

@jhoyt4 jhoyt4 marked this pull request as draft January 4, 2025 19:42
@jhoyt4 jhoyt4 changed the title Add cmake based macOS app bundle generation for macOS macOS: Add cmake based app bundle generation for mythfrontend Jan 4, 2025
@jhoyt4 jhoyt4 marked this pull request as ready for review January 4, 2025 20:15
@jhoyt4 jhoyt4 marked this pull request as draft January 4, 2025 20:18
@jhoyt4 jhoyt4 marked this pull request as ready for review January 4, 2025 20:28
@jhoyt4 jhoyt4 marked this pull request as draft January 5, 2025 14:10
@jhoyt4 jhoyt4 force-pushed the master branch 2 times, most recently from 6612392 to b47846a Compare January 5, 2025 15:02
@jhoyt4 jhoyt4 marked this pull request as ready for review January 5, 2025 15:06
jhoyt4 and others added 12 commits January 16, 2025 17:24
  In DARWIN executables, search for the App Bundle's RUNPREFIX
  setting the mythdirs to point internally to the app bundle.
  If they are not found, default to the install prefix.
  mythfrontend,mythbackend,mythmetalookup,musicmetautils all have hard
  coded PYTHONPATHS that require updated to the app build struture
  Homebrew uses the "@" designator to differentiate versions of the
  same package.  Update QT's logic to force use of this convention.
  Add cmake and cpack code to optionally generate an application bundle
  and dmg distribution package via cmake and cpack. cmake will also
  optionally codesign and notarize the app bundle and dmg distirbution
  package.

  To activate building an app bundle set the following flags to ON:
    DARWIN_FRONTEND_BUNDLE
  To sign and notarize the App Bundle and Distribution package these
  Values must be set:
    DARWIN_SIGNING_ID
    DARWIN_NOTARIZATION_KEYCHAIN
…stall prefix

  The Darwin ansible playbooks use a python virtual environment to pull
  in allof the necessary python packages via pip in a non-interfering
  basise with the host package mangaer. If a venv has been used, copy
  the files to the install prefix to aide in application bundling as
  well as to make sure that the built applications has access to the
  appropriate packages.
If the configuration of a project or subproject exits before the cmake
project() function is called, you get a very weird error about the
version of ninja being too low regardless of what version is actually
installed.  The Darwin Packaging subproject is elsewhere protected
from being created if the APPLE variable isn't set, so remove that
test here.  Just in case.  So if you do somehow invoke it when you
shouldn't you don't waste time chasing false clues.  :-)
…ariables.

Its easier to read code that says "if MACPORTS" than code that says
"if DETECT_MACPORTS EQUAL 0". The former is obvious; the latter
requires you to remember that the variable contains the output of a
shell command and that "0" means "true" in this case even though it
means "false" everywhere else in computing.
  A warning message appears when add_custom_command is called without
  a build stage defaulting to POST_BUILD.  Add POST_BUILD to remove the
  warning.
@linuxdude42 linuxdude42 merged commit 6c30a19 into MythTV:master Jan 16, 2025
8 of 10 checks passed
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