Skip to content

Commit 83a8201

Browse files
committed
add prebuilt libs for macos
1 parent 5b5d1e6 commit 83a8201

File tree

3 files changed

+34
-6
lines changed

3 files changed

+34
-6
lines changed

LIBGIT_NOTES.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -84,18 +84,18 @@ make && make install
8484
cp -rp *.so* /usr/lib/
8585

8686
# Download and setup libssh2
87-
cd ~ && wget https://github.com/libssh2/libssh2/releases/download/libssh2-1.9.0/libssh2-1.9.0.tar.gz
88-
tar -xzf libssh2-1.9.0.tar.gz
89-
cd libssh2-1.9.0/
87+
cd ~ && git clone https://github.com/libssh2/libssh2.git libssh2
88+
cd libssh2/
9089
mkdir build && cd build
91-
cmake -DCMAKE_INSTALL_PREFIX=../install .. && cmake --build . --target install
90+
cmake -DCMAKE_INSTALL_PREFIX=../install ..
91+
cmake --build . --target install
9292

9393
#Download and setup libgit2
9494
cd ~ && wget https://github.com/libgit2/libgit2/releases/download/v1.1.0/libgit2-1.1.0.tar.gz
9595
tar -xzf libgit2-1.1.0.tar.gz
9696
cd libgit2-1.1.0/
9797
mkdir build && cd build
98-
cmake -DCMAKE_PREFIX_PATH=../../libssh2-1.9.0/install/ -DCMAKE_INSTALL_PREFIX=../install -DBUILD_CLAR=OFF ..
98+
cmake -DCMAKE_PREFIX_PATH=../../libssh2/install/ -DCMAKE_INSTALL_PREFIX=../install -DBUILD_CLAR=OFF ..
9999
cmake --build . --target install
100100

101101
# Copy the libgit2 shared object and pkconfig files to the /usr/lib path
@@ -115,4 +115,4 @@ Download and setup [brew](https://brew.sh/) to install all the required packages
115115
- [wget](https://formulae.brew.sh/formula/wget)
116116
- [gcc](https://gcc.gnu.org/)
117117

118-
Once the packages are setup, run the same commands mentioned above for Linux to setup libgit2
118+
Once the packages are set up, run the same commands mentioned above for Linux to setup libgit2

lib/macos_amd64/install_deps

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/bin/bash
2+
3+
# This script copies the dependent libraries required for gitconvex to function properly to the /usr/* directory
4+
# Make sure you run the script as sudo
5+
6+
# Extract libs from tar
7+
echo "Extracting the lib folder..."
8+
tar -xzf macos_amd64.tar.gz
9+
10+
# OpenSSL
11+
echo "Copying OpenSSL libs..."
12+
cp -rp ./openssl/include/* /usr/local/include/
13+
cp -p ./openssl/bin/* /usr/local/bin/
14+
cp -rp ./openssl/ssl /usr/local/
15+
cp -p ./openssl/lib/pkgconfig/* /usr/local/lib/pkgconfig/
16+
cp -rp ./openssl/lib/ossl-modules ./openssl/lib/engines-3 ./openssl/lib/lib* /usr/local/lib/
17+
18+
# Libssh
19+
echo "Copying libssh libs..."
20+
cp -rp ./libssh2/include/* /usr/local/include/
21+
cp -p ./libssh2/lib/lib* /usr/local/lib/
22+
cp -p ./libssh2/lib/pkgconfig/* /usr/local/lib/pkgconfig/
23+
24+
# Libgit
25+
echo "Copying libgit libs..."
26+
cp -rp ./libgit/include/* /usr/local/include/
27+
cp -p ./libgit/lib/lib* /usr/local/lib/
28+
cp -p ./libgit/lib/pkgconfig/* /usr/local/lib/pkgconfig/

lib/macos_amd64/macos_amd64.tar.gz

11.9 MB
Binary file not shown.

0 commit comments

Comments
 (0)