Skip to content

Instantly share code, notes, and snippets.

@AndrewSB
Created October 24, 2017 03:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AndrewSB/e5f0d53044f1585f25396d84e39684eb to your computer and use it in GitHub Desktop.
Save AndrewSB/e5f0d53044f1585f25396d84e39684eb to your computer and use it in GitHub Desktop.
Allows a copy-pasteable installation of thrift patched to support swift
# Read this, and then copy paste it into your shell. IF ALL of it succeeds, then you should have a usable thrift tool in /usr/local/Cellar/thrift/mine/bin/thrift
brew install thrift bison
cd /tmp
mkdir setting-up-thrift
cd setting-up-thrift
git clone https://github.com/apocolipse/thrift
cd thrift
PATH="/usr/local/opt/bison/bin:$PATH" # we need some bison utils
./bootstrap.sh || echo "bootstrapping thrift failed" && exit 1
./configure --disable-debug --prefix=/usr/local/Cellar/thrift/mine --libdir=/usr/local/Cellar/thrift/mine/lib --without-ruby --disable-tests --without-php_extension --without-python --without-haskell --without-java --without-perl --without-php --without-erlang --without-boost || echo "configuring thrift failed" && exit 1
make || echo "making thrift failed" && exit 1
make install "make installing thrift failed" && exit 1
echo "It works! You should have a usable binary in /usr/local/Cellar/thrift/mine/bin/thrift"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment