Skip to content

Commit

Permalink
Merge branch '0.10' of https://github.com/openlightingproject/ola int…
Browse files Browse the repository at this point in the history
…o master-resync
  • Loading branch information
peternewman committed Dec 15, 2023
2 parents 1a68747 + aed518a commit fa2bd3b
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion config/ola.m4
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,14 @@ if test -z "$PROTOC" ; then
AC_MSG_ERROR([cannot find 'protoc' program]);
elif test -n "$1" ; then
AC_MSG_CHECKING([protoc version])
[protoc_version=`$PROTOC --version 2>&1 | grep 'libprotoc' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'`]
# Since v20.x we only get effectively the minor and patch versions out of protoc.
# Treat them as major and minor and everything should keep working indefinitely.
# See https://protobuf.dev/support/version-support/
# So we've got either of these:
# libprotoc 2.4.1
# libprotoc 23.3
# The first sed ensures all versions have major, minor, patch, by adding a .0 on the end of ones missing it
[protoc_version=`$PROTOC --version 2>&1 | grep 'libprotoc' | sed 's/\([^\.0-9][0-9][0-9]*\.[0-9][0-9]*\)$/\1\.0/g' | sed 's/[^0-9]*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'`]
[required=$1]
[required_major=`echo $required | sed 's/[^0-9].*//'`]
[required_minor=`echo $required | sed 's/[0-9][0-9]*\.\([0-9][0-9]*\)\.[0-9][0-9]*/\1/'`]
Expand Down

0 comments on commit fa2bd3b

Please sign in to comment.