jam-cloud/build_rprotoc

22 lines
503 B
Plaintext
Raw Normal View History

2012-07-31 04:00:33 +00:00
#!/bin/bash
# ruby protocol buffers
# http://code.google.com/p/ruby-protobuf/
RUBY_OUT=$TARGET/ruby
# we exit with 0; treat ruby as optional at the moment
command -v "bundle" >/dev/null 2>&1 || { echo >&2 "bundle is required but not installed. Skipping ruby protocol buffers."; exit 0; }
# creates a bin folder with 'rprotoc' command inside
bundle install --binstubs
# die on error at this point
set -e
for i in "${PROTO_FILES[@]}"
do
bin/rprotoc --proto_path $SRC --out $RUBY_OUT "$i"
done