diff options
author | Ash McKenzie <amckenzie@gitlab.com> | 2022-02-03 06:48:19 +0300 |
---|---|---|
committer | Ash McKenzie <amckenzie@gitlab.com> | 2022-02-03 06:48:19 +0300 |
commit | 18f2afab42d9280e926ebb25883f4eb448d5088a (patch) | |
tree | dc0f395da66bf218de24638c029d82642bbb7184 | |
parent | 3db92ca403f2dd3a3a3c738ac25d9605570761e7 (diff) |
Set LIBPCREDIR if brew command availableashmckenzie/correctly-build-git-on-macos
-rw-r--r-- | Makefile | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -196,6 +196,13 @@ ifeq ($(origin GIT_BUILD_OPTIONS),undefined) GIT_BUILD_OPTIONS += NO_INSTALL_HARDLINKS=YesPlease endif +MACOS_HOMEBREW_PREFIX := $(shell command -v brew > /dev/null 2>&1 && brew --prefix || true) + +# LIBPCREDIR needs to explicitly be set for macOS platforms +ifneq ($(MACOS_HOMEBREW_PREFIX),) +GIT_BUILD_OPTIONS += LIBPCREDIR="${MACOS_HOMEBREW_PREFIX}/opt/pcre2" +endif + ifdef GIT_APPEND_BUILD_OPTIONS GIT_BUILD_OPTIONS += ${GIT_APPEND_BUILD_OPTIONS} endif |