Skip to content

Instantly share code, notes, and snippets.

@lebao3105
Last active December 24, 2023 08:56
Show Gist options
  • Save lebao3105/8e22c264395b0daa4f09f1c280aef3d8 to your computer and use it in GitHub Desktop.
Save lebao3105/8e22c264395b0daa4f09f1c280aef3d8 to your computer and use it in GitHub Desktop.

How to build libpatchfinder on macOS with Brew

You just need Brew from brew.sh. macOS Monterey or higher is recommended.

Steps

Clone everything you need with git (this will be your build order too):

Why do I use libplist from libimobiledevice rather than Homebrew repository? Because libplist on Homebrew is version 2.2 (head repo is not libimobiledevice github + not tested), lower than the required libplist >= 2.3.0 from img{3,4}tool.

Install packages with brew:

  • autoconf
  • automake
  • libtool
  • pkg-config
  • python

Build everything with these commands:

$ cd <project>
$ ./autogen.sh
$ make install
# go back and build the next project
# imagine you're in a for-loop:)
$ cd ..

If you see Permission error, use sudo make install instead of make install.

If you encountered an error and want to try if your solution worked or not, run ./autogen.sh.

All projects you build are automake projects, which is used mostly on Linux/BSD. It works like meson: parse + check dependencies, then generate make files.

Happy hacking!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment