This should do the trick on debian-flavoured systems:
apt-get install build-essential cmake libprotobuf-dev libsnappy-dev protobuf-compiler git submodule init git submodule update cd build cmake -DWITH_EXAMPLES=1 -DWITH_TOOLS=1 .. make -j6 make install
This should generate butterflyjs0.js and butterflyjs1.js. Use the later for a stable JS api.
You can use the included Dockerfile to build a docker image of the project - and then just copy out the built binaries or use them in-place.