mirror of
https://github.com/HandBrake/HandBrake-docs.git
synced 2025-12-10 00:44:52 -06:00
docs: Update dependencies and instructions for building on macOS.
Includes a one-liner for checking whether Python 3 installed from third-parties such as Homebrew can open HTTPS connections, which indicates SSL certificates are properly installed and accessible. See https://github.com/HandBrake/HandBrake/issues/2216.
This commit is contained in:
parent
1b74c45a93
commit
3d7ee87590
@ -16,9 +16,9 @@ License_URL: https://handbrake.fr/docs/license.html
|
||||
Building HandBrake for Mac
|
||||
==========================
|
||||
|
||||
Building HandBrake for Mac requires an Apple computer with a 64-bit Intel processor running OS X 10.13.6 High Sierra or later[^mojave-dark-mode], and the following dependencies.
|
||||
Building HandBrake for Mac requires an Apple computer with a 64-bit Intel processor running macOS 10.14.3 Mojave or later, and the following dependencies.
|
||||
|
||||
- [Xcode](https://developer.apple.com/xcode/) 10 or later
|
||||
- [Xcode](https://developer.apple.com/xcode/) 10.3 or later
|
||||
- free Apple Developer registration required, or install from the Mac App Store
|
||||
- [Command Line Tools for Xcode](https://developer.apple.com/download/more/)
|
||||
- free Apple Developer registration required, or install using `xcode-select --install`
|
||||
@ -27,20 +27,27 @@ Building HandBrake for Mac requires an Apple computer with a 64-bit Intel proces
|
||||
|
||||
Additional dependencies (may be built via included script):
|
||||
|
||||
- autoconf
|
||||
- automake
|
||||
- cmake (3.8.2 or later recommended)
|
||||
- libtool
|
||||
- autoconf 2.69 or later
|
||||
- automake 1.16 or later
|
||||
- cmake 3.14 or later
|
||||
- libtool 2.4.6 or later
|
||||
- meson 0.47.0 or later
|
||||
- nasm 2.13 or later
|
||||
- pkg-config
|
||||
- yasm 1.2.0 or later (1.3.0 or later recommended)
|
||||
- ninja 1.8 or later
|
||||
- pkg-config 0.29.2 or later
|
||||
|
||||
Install Xcode[^xcode-install] and open it once. Approve any prompts to install additional tools. You may quit Xcode after it has finished loading.
|
||||
Install Xcode and open it once. Approve any prompts to install additional tools. You may quit Xcode after it has finished loading.
|
||||
|
||||
Install Command Line Tools for Xcode[^xcode-cli-tools].
|
||||
Install Command Line Tools for Xcode using the package installer provided by Apple[^xcode-cli-tools], or using `xcode-select`.
|
||||
|
||||
xcode-select --install
|
||||
|
||||
Install Python 3 using the latest package installer provided by [Python](https://www.python.org/downloads/).
|
||||
|
||||
If you installed Python 3 from a different source, such as Homebrew, it is necessary to check whether Python 3 can properly open HTTPS connections. The following test prints `0` for success, or `1` for failure. Upon failure, you will need to ensure SSL certificates are installed and accessible to your Python 3 installation, or remove the installation and reinstall from the official package.
|
||||
|
||||
python3 -c 'from urllib.request import urlopen; test = lambda x=exec("def f():\n try:\n urlopen(\"https://handbrake.fr\", timeout=10)\n return 0\n except: return 1"): f(); result = test(); exit(result)'; echo $?
|
||||
|
||||
Clone the HandBrake repository.
|
||||
|
||||
git clone https://github.com/HandBrake/HandBrake.git && cd HandBrake
|
||||
@ -53,7 +60,7 @@ This process will take a few minutes. If necessary, the script will provide you
|
||||
|
||||
Build HandBrake. To build the command line interface only, disable the graphical interface by appending `--disable-xcode`.
|
||||
|
||||
./configure --launch-jobs=$(sysctl -n hw.ncpu) --launch
|
||||
./configure --launch-jobs=$(sysctl -n hw.activecpu) --launch
|
||||
|
||||
When complete, you will find `HandBrakeCLI` in the `build/xroot` directory. If the graphical interface is enabled, you will also find `HandBrake.app` in this directory.
|
||||
|
||||
@ -65,10 +72,6 @@ To start over, simply remove the `build` directory.
|
||||
|
||||
rm -rf build
|
||||
|
||||
[^mojave-dark-mode]: HandBrake must be built on macOS 10.14 Mojave or later to enable Dark Mode toolbar icons. Building on earlier macOS, even with latest Xcode, will result in Light Mode toolbar icons being displayed in Dark Mode.
|
||||
|
||||
[^xcode-install]: Make sure Xcode is installed at `/Applications/Xcode.app`. When using an Xcode Beta release, you may need to rename `Xcode-beta.app` to `Xcode.app`.
|
||||
|
||||
[^xcode-cli-tools]: When installing Command Line Tools for Xcode using the package installer (instead of `xcode-select --install`), make sure to install the package that corresponds to the installed Xcode version. A mismatch between the installed Xcode and Command Line Tools versions may cause problems.
|
||||
|
||||
[^default-path]: `/usr/local/bin` is included in the system's `PATH` by default. It is not necessary to add it to your environment's `PATH` when installing the additional dependencies to `/usr/local`.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user