monkey-patch build_pb.sh to support python3

This commit is contained in:
Jochen Hoenicke 2016-07-03 15:12:00 +02:00 committed by Pavol Rusnak
parent 897d57803a
commit 6b17bf179b
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
1 changed files with 3 additions and 0 deletions

View File

@ -6,3 +6,6 @@ cd $CURDIR/../trezor-common/protob
for i in messages types ; do
protoc --python_out=$CURDIR/trezorlib/ -I/usr/include -I. $i.proto
done
# hack to make output python 3 compatible
sed -i 's/^import types_pb2/from . import types_pb2/g' $CURDIR/trezorlib/messages_pb2.py