Skip to content

Commit f166628

Browse files
Update build.yml
1 parent 12dc6ed commit f166628

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

.github/workflows/build.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,14 +60,30 @@ jobs:
6060
- name: Run macOS Build
6161
if: inputs.os_target == 'macos'
6262
run: |
63+
# Set up and build Protobuf 3.6.1
6364
export PROTOBUF_DIR="$HOME/local/protobuf-3.6.1"
65+
mkdir -p "$PROTOBUF_DIR"
66+
curl -LO https://github.com/protocolbuffers/protobuf/releases/download/v3.6.1/protobuf-cpp-3.6.1.tar.gz
67+
tar -xzf protobuf-cpp-3.6.1.tar.gz
68+
cd protobuf-3.6.1
69+
./configure --prefix="$PROTOBUF_DIR"
70+
make -j$(sysctl -n hw.logicalcpu)
71+
make install
72+
cd ..
73+
74+
# Export environment variables
6475
export PKG_CONFIG_PATH="$PROTOBUF_DIR/lib/pkgconfig:$PKG_CONFIG_PATH"
6576
export LDFLAGS="-L$PROTOBUF_DIR/lib $LDFLAGS"
6677
export CPPFLAGS="-I$PROTOBUF_DIR/include $CPPFLAGS"
6778
export LD_LIBRARY_PATH="$PROTOBUF_DIR/lib:$LD_LIBRARY_PATH"
6879
export PATH="$PROTOBUF_DIR/bin:$PATH"
6980
export PROTOC="$PROTOBUF_DIR/bin/protoc"
7081
82+
# Confirm protobuf installed
83+
$PROTOC --version
84+
pkg-config --modversion protobuf || echo "pkg-config failed"
85+
86+
# Run the macOS build script
7187
echo -e "2\ny\ny" | ./build_adventurecoin_mac.sh
7288
7389
- name: Upload to GitHub Release

0 commit comments

Comments
 (0)