protoc: check for headers in new location as well
authorRuben Kerkhof <ruben@rubenkerkhof.com>
Sun, 9 Aug 2015 17:05:25 +0000 (19:05 +0200)
committerRuben Kerkhof <ruben@rubenkerkhof.com>
Sat, 28 Nov 2015 12:10:29 +0000 (13:10 +0100)
Newer versions of protobuf-c have their headers in
/usr/include/protobuf-c, and a symlink from
/usr/include/google/protobuf-c/.

These symlinks will eventually disappear however, so be prepared.

configure.ac

index 888c6e9..d119fc7 100644 (file)
@@ -64,8 +64,8 @@ fi
 
 if test "x$have_protoc_c" = "xyes"
 then
-       AC_CHECK_HEADERS([google/protobuf-c/protobuf-c.h],
-                        [have_protoc_c="yes"],
+       AC_CHECK_HEADERS([protobuf-c/protobuf-c.h google/protobuf-c/protobuf-c.h],
+                        [have_protoc_c="yes"; break],
                         [have_protoc_c="no (<google/protobuf-c/protobuf-c.h> not found)"])
 fi
 if test "x$have_protoc_c" = "xyes"