1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
|
#! /usr/bin/make -f
export PYBUILD_NAME=bernhard
%:
dh $@ --buildsystem=pybuild
execute_before_dh_auto_build:
protoc -I=debian --python_out=bernhard debian/riemann.proto
mv bernhard/riemann_pb2.py bernhard/pb.py
execute_before_dh_gencontrol:
pbvercur=`dpkg -l python3-protobuf | grep 'ii' | sed -e 's/^.*python3-protobuf[[:space:]]\+\([0-9.]\+\)-[0-9].*/\1/' | cut -d '.' -f 1,2` ; \
pbvernext=`echo $$pbvercur | awk -F '[.]' '{printf "%d.%d\n", $$1, $$2 + 1}'` ; \
sed -i "s/python3-protobuf/python3-protobuf (>= $${pbvercur}), python3-protobuf (<< $${pbvernext})/" debian/*substvars
|