Building MythFrontend on Mac OS X
These instructions will walk you through setting up your Mac to compile and generate a Mythfrontend.app and .dmg file for macOS.
Building Mythfrontend with Macports and Ansible
Note: This page is meant to help those who wish to build Mythfrontend.app v31 and later for macOS. Most users should visit MythTV on Mac OS X to download prebuilt binaries instead. The script has been tested on a mixture of configurations from v31 through master/v34. The script supports both arm64 and x84_64 based builds.
Install Xcode, Xcode Command Line Tools
Xcode and Xcode Command Line Tools can now be installed via the Apple App Store. Please install them before moving on to installing the package manager of your choice (MacPorts or Homebrew).
Install a Package Manager
The compile script now works with either MacPorts or Homebrew. Please install your preferred package manager.
Option 1 (Preferred for Legacy Installs): Install MacPorts
MacPorts is a stable and mature system for bringing open-source software to the Mac platform. Changes are tested and reviewed before being committed to MacPorts. MacPorts operates several build slaves which automatically build the default variant of each port. All this means that if you decide to try building with MacPorts, there is a strong likelihood that it will just work. And, if it doesn't, there is an active support system working to resolve any problems.
MacPorts also specializes in support for older macOS versions. If you're running a deprecated version of macOS, this is your best path for success.
To install, follow the MacPorts' directions for installing MacPorts for your respective version of MacOS.
Note: Remember to run "sudo port -v selfupdate" after installing MacPorts to update the MacPorts repositories
Option 2: Install Homebrew
Homebrew has quickly become the most popular package manager on macOS. It is the default package manager on github runners. Homebrew has a tendancy to have more frequent updates to packages at the cost of leaving legacy systems and package versions behind. If you're running a deprecated version of macOS, you may want to consider using MacPorts instead.
Download and Run the Compile Script
The compile script can be found in the official MythTV packaging repository
Download "compileMythFrontendAnsible.zsh" to your system and make executable.
Run the Compile Script
Run the script with the following command:
Note: In order to install packages via ansible, this script must be run by a user with sudo privileges. When prompted for either a "Password;" or "BECOME password:" you'll need to enter your sudo password.
The script automatically performs the following steps:
- Sets up the build directory structure (tries to mirror the mythtv dev team's structure)
- Installs ansible-playbook via MacPorts o Homebrew
- Clones the MythTV ansible git repository
- Installs MythTV compile requirements and their dependencies via ansible and macports or hoebrew)
- Clones the MythTV git repository, applying any user specified patches to mythtv or plugins
- Clones the MythTV Packaging git repository, applying any user specified patches
- Configures, builds, and installs MythTV to a temp directory
- Optionally Configures, builds, and installs MythPlugins to a temp directory
- Deploys QT and python to the compiled mythfrontend.app
- Copies the required dylibs, support data, and fonts into the app linking
- Optionally Packages mythfrontend.app into a .dmg file
Pre-built Application
For those who would prefer to just download a pre-built application, these files can be found on the MythTVForMacOSX site. These files are updated sporadically by the github runners and the MythTV mac user community.
Problems?
If you have any problems compiling mythtv, please post to the mythtv-users mailing list or mythtv forums.
For MacPorts related issues, please post to the macports-users mailing list. If necessary, please file a bug with the MacPorts bug tracker.
For Homebrew related issues, please consult the Homebrew docs and Homebrew discussions forum.