Skip to content

Commit f5891e0

Browse files
committed
add make rule to install libs for mac and linux
1 parent 83a8201 commit f5891e0

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

Makefile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ build-ui:
1414
build-server:
1515
mkdir -p ./dist
1616
go build -o ./dist
17+
18+
install_deps:
19+
if [[ "$(shell uname)" == "Darwin" ]]; then cd ./lib/macos_amd64 && ./install_deps && cd .. ; else cd ./lib/linux_x86_64 && ./install_deps && cd ..; fi
20+
1721
build:
1822
echo "Initiating gitconvex build"
1923
echo "Cleaning up old directories"
@@ -39,9 +43,9 @@ build:
3943
echo "Building final go source with UI bundle" && \
4044
go build -v -a -o ./dist && \
4145
echo "Gitconvex build completed!" && \
42-
mv ./dist/gitconvex-server ./dist/gitconvex
43-
echo "Copying etc files to dist"
44-
cp -rp ./etc ./dist/
46+
mv ./dist/gitconvex-server ./dist/gitconvex
47+
echo "Installing libs"
48+
$(MAKE) install_deps
4549
echo "Use ./dist/gitconvex to start Gitconvex on port 9001"
4650
echo "Try ./dist/gitconvex --port PORT_NUMBER to run gitconvex on the desired port"
4751
test:

lib/linux_x86_64/install_deps

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# Make sure you run the script as sudo
55

66
# Extract libs from tar
7-
echo "Extracting the lib folder..."
7+
echo "Extracting the lib folder for Linux..."
88
tar -xzf linux_x86_64.tar.gz
99

1010
# OpenSSL

lib/macos_amd64/install_deps

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# Make sure you run the script as sudo
55

66
# Extract libs from tar
7-
echo "Extracting the lib folder..."
7+
echo "Extracting the lib folder for MacOS..."
88
tar -xzf macos_amd64.tar.gz
99

1010
# OpenSSL

0 commit comments

Comments
 (0)