two python projects: fix protobuf install (#8246)

This commit is contained in:
DavidKorczynski 2022-08-13 22:33:21 +01:00 committed by GitHub
parent 91e148cbb3
commit 680fe65b23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 16 deletions

View File

@ -18,22 +18,20 @@
# Build protoc with default options.
unset CFLAGS CXXFLAGS
mkdir $SRC/protobuf-install/
cd $SRC/protobuf/
./autogen.sh
./configure --prefix=$SRC/protobuf-install
cd $SRC/protobuf-install/
cmake -Dprotobuf_BUILD_TESTS=OFF $SRC/protobuf
make -j$(nproc)
make install
export PROTOC="$SRC/protobuf-install/bin/protoc"
ldconfig
cd python
python3 setup.py build --cpp_implementation
cd $SRC/protobuf/python
python3 setup.py build
pip3 install .
# Compile .proto specs
cd $SRC/python-api-common-protos/
for target in quota billing service routing log; do
$PROTOC --python_out=. --proto_path=. google/api/$target.proto
protoc --python_out=. --proto_path=. google/api/$target.proto
done
# Compile fuzzer

View File

@ -18,21 +18,18 @@
# Build protoc with default options.
unset CFLAGS CXXFLAGS
mkdir $SRC/protobuf-install/
cd $SRC/protobuf/
./autogen.sh
./configure --prefix=$SRC/protobuf-install
cmake $SRC/protobuf -Dprotobuf_BUILD_TESTS=OFF
make -j$(nproc)
make install
export PROTOC="$SRC/protobuf-install/bin/protoc"
ldconfig
cd python
python3 setup.py build --cpp_implementation
cd $SRC/protobuf/python
python3 setup.py build
pip3 install .
# Compile test protos with protoc.
cd $SRC/
$PROTOC --python_out=. --proto_path=. test-full.proto
protoc --python_out=. --proto_path=. test-full.proto
# Build fuzzers in $OUT.
for fuzzer in $(find $SRC -name 'fuzz_*.py'); do