Skip to content

macOS

Requirements

  • macOS 13 Ventura or later (tested on Sequoia 15)

Quick install via Homebrew

The easiest way to install Frida on macOS is through the MLZ Homebrew tap, which installs Frida and all its dependencies automatically.

First, install Homebrew if not already present:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Then add the MLZ tap and install Frida:

brew tap mlz/frida https://jugit.fz-juelich.de/mlz/frida
brew install mlz/frida/frida

The command frida should now start a session. If you run into issues, see the Troubleshooting section below.


Build from source

The following describes how to build Frida from source. This is only needed if you want to modify the code.

Prerequisites

Xcode Command Line Tools

xcode-select --install

This provides the compiler (clang++, C++20 from Xcode ≥ 14), make, and other POSIX tools.

Homebrew

Install Homebrew if not already present:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Dependencies via Homebrew

brew install cmake bison flex pkg-config \
  readline gsl fftw hdf5 boost libyaml \
  libcerf gnuplot

Note: bison and flex are keg-only — Homebrew installs them but does not add them to PATH, to avoid overriding the versions shipped with macOS. The CMakePresets.json handles this automatically.

Build MLZ dependencies

kww and lmfit are available through the MLZ tap. If you added the tap in the quick install step above, they are already installed. If not, install them with:

brew tap mlz/frida https://jugit.fz-juelich.de/mlz/frida
brew install mlz/frida/kww mlz/frida/lmfit

Build Frida

Clone or download the Frida source from https://jugit.fz-juelich.de/mlz/frida.

The source tree includes a CMakePresets.json for macOS. Set the Homebrew prefix, then use the preset:

export HOMEBREW_PREFIX=$(brew --prefix)
cmake --preset macos-homebrew -B build
cd build
make -j$(sysctl -n hw.logicalcpu)

Anaconda users: deactivate the conda environment before running cmake (conda deactivate), otherwise Anaconda’s older Boost may be picked up instead of Homebrew’s.

Run the test suite:

ctest -j$(sysctl -n hw.logicalcpu)

Only proceed if all tests pass. If any fail, run ctest -V for verbose output and report to the maintainer.

Install:

sudo make install

Troubleshooting

gnuplot: Symbol not found: _luaL_openlibs

gnuplot was compiled against an older version of Lua than what is now installed. Fix by reinstalling gnuplot:

brew reinstall gnuplot

gnuplot: libcerf.2 not found

If Frida starts but plot windows fail with Library not loaded: libcerf.2.dylib, gnuplot was compiled against an older libcerf than what is installed. Fix by reinstalling gnuplot:

brew reinstall gnuplot

If that fails due to a Qt conflict on your system, create a compatibility symlink as a workaround:

sudo ln -s "$(brew --prefix libcerf)/lib/libcerf.3.dylib" \
           "$(brew --prefix libcerf)/lib/libcerf.2.dylib"

gnuplot: no display

If gnuplot complains about no display terminal, ensure it was built with an interactive terminal. Check with:

gnuplot -e "set terminal" 2>&1 | grep -i qt

If qt is missing, reinstall: brew reinstall gnuplot.

cmake cannot find a library

Check that the library is installed and that pkg-config can find it:

PKG_CONFIG_PATH=$(brew --prefix)/lib/pkgconfig \
  pkg-config --modversion yaml-0.1   # example for libyaml

If a library is keg-only, pass its prefix explicitly:

cmake .. \
  -DCMAKE_PREFIX_PATH="$(brew --prefix);$(brew --prefix readline)"

Library not found at runtime

macOS uses DYLD_LIBRARY_PATH rather than LD_LIBRARY_PATH:

export DYLD_LIBRARY_PATH=$(brew --prefix)/lib:$DYLD_LIBRARY_PATH

Or update the dynamic linker cache after installing to /usr/local:

sudo update_dyld_shared_cache   # macOS 12 and earlier