# $SRC_DIR: .proto 所在的源目录
# --cpp_out: 生成 c++ 代码
# $DST_DIR: 生成代码的目标目录
# xxx.proto: 要针对哪个 proto 文件生成接口代码
# protoc -I=$SRC_DIR --cpp_out=$DST_DIR $SRC_DIR/xxx.proto
if [ -z "$1" ]; then
    echo "usage: $0 no $1"
    exit 0
fi
# exit 0
echo "$1"
# 算法mqtt配置
protoc -I="$1/include/pahoc" mqtt_async.proto --cpp_out="$1/include/pahoc"
# 算法优化的相关定义
protoc -I="$1/Modules/AlgWheelDetect" define.proto --cpp_out="$1/Modules/AlgWheelDetect"

# 算法测试的相关定义
protoc -I="$1/Modules/AlgAddTest" define.proto --cpp_out="$1/Modules/AlgAddTest"

# message
protoc -I="$1/include/message" measure_message.proto --cpp_out="$1/include/message"
protoc -I="$1/include/message" message.proto --cpp_out="$1/include/message"
protoc -I="$1/include/message" message_base.proto --cpp_out="$1/include/message"

# rabbitmq
protoc -I="$1/include/rabbitmq" rabbitmq.proto --cpp_out="$1/include/rabbitmq"

# 测量节点
protoc -I="$1/Modules/MeasureNode/velodyne_lidar" velodyne_config.proto --cpp_out="$1/Modules/MeasureNode/velodyne_lidar"
protoc -I="$1/Modules/MeasureNode/message" central_control_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" dispatch_control.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" dispatch_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" log_process.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" measure_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" message_base.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" notify_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" parkspace_allocation_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" process_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" singlechip_msg.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" terminal_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/message" UnNormalized_module_message.proto --cpp_out="$1/Modules/MeasureNode/message"
protoc -I="$1/Modules/MeasureNode/communication" communication.proto --cpp_out="$1/Modules/MeasureNode/communication"
protoc -I="$1/Modules/MeasureNode/rabbitmq" rabbitmq.proto --cpp_out="$1/Modules/MeasureNode/rabbitmq"
protoc -I="$1/Modules/MeasureNode/verify" hardware_limit.proto --cpp_out="$1/Modules/MeasureNode/verify"
protoc -I="$1/Modules/MeasureNode/wanji_lidar" wj_lidar_conf.proto --cpp_out="$1/Modules/MeasureNode/wanji_lidar"







