diff options
| author | lhchavez <[email protected]> | 2021-09-06 05:13:55 -0700 |
|---|---|---|
| committer | GitHub <[email protected]> | 2021-09-06 05:13:55 -0700 |
| commit | c6da3b97a8a2c7bbbed4496f50c990a1aab4f7bf (patch) | |
| tree | 8cda919a8faf849e9ce4f58910020ca5e33a575c /script/build-libgit2.sh | |
| parent | c8ce59d4eb3fc736fa380e7a2747c96659552e5d (diff) | |
Allow building libgit2 with Chromium zlib (#831)
This change allows the caller to set the `USE_CHROMIUM_ZLIB=ON`
environment variable to use the Chromium implementation of zlib when
building libgit2.
Diffstat (limited to 'script/build-libgit2.sh')
| -rwxr-xr-x | script/build-libgit2.sh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/script/build-libgit2.sh b/script/build-libgit2.sh index e490b4b..dbc19e4 100755 --- a/script/build-libgit2.sh +++ b/script/build-libgit2.sh @@ -61,12 +61,18 @@ else mkdir -p "${BUILD_PATH}/install/lib" fi +USE_BUNDLED_ZLIB="ON" +if [ "${USE_CHROMIUM_ZLIB}" = "ON" ]; then + USE_BUNDLED_ZLIB="Chromium" +fi + mkdir -p "${BUILD_PATH}/build" && cd "${BUILD_PATH}/build" && cmake -DTHREADSAFE=ON \ -DBUILD_CLAR=OFF \ -DBUILD_SHARED_LIBS"=${BUILD_SHARED_LIBS}" \ -DREGEX_BACKEND=builtin \ + -DUSE_BUNDLED_ZLIB="${USE_BUNDLED_ZLIB}" \ -DUSE_HTTPS=OFF \ -DUSE_SSH=OFF \ -DCMAKE_C_FLAGS=-fPIC \ |
