Automate building Thrift code and JVMPetrel. Support binary install.