Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitigmore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.dependencies
39 changes: 39 additions & 0 deletions scripts/install-thrift-locally.sh
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe include macos in the file name like install-thrift-macos?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good call, I was thinking of making it agnostic, but didn't, let me do that

Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
#!/bin/bash -e

cd $(dirname $0)/..

if [[ ! -d .dependencies ]]; then
mkdir .dependencies
fi

cd .dependencies
rm -rf thrift
mkdir thrift
cd thrift

APACHE_THRIFT_VERSION=0.9.3

brew install bison

# macs have an old versiion of bison hanging around typically
# so override it by using the brew version in PATH
export PATH="/opt/homebrew/opt/bison/bin:$PATH"

wget https://archive.apache.org/dist/thrift/${APACHE_THRIFT_VERSION}/thrift-${APACHE_THRIFT_VERSION}.tar.gz && \

tar -xvf thrift-${APACHE_THRIFT_VERSION}.tar.gz
rm thrift-${APACHE_THRIFT_VERSION}.tar.gz
cd thrift-${APACHE_THRIFT_VERSION}/

./configure --enable-libs=no --enable-tests=no --enable-tutorial=no --with-cpp=no --with-c_glib=no --with-java=yes --with-ruby=no --with-erlang=no --with-go=no --with-nodejs=no --with-python=no && \

make
echo ""
echo "thrift expects to be globally installed :/"
echo "asking do do with sudo to install to /usr/local/bin"
echo ""
sudo make install && \
cd .. && \
rm -rf thrift-${APACHE_THRIFT_VERSION}
thrift --version
echo "done"