configure: Fix cross builds (check for TensorFlow header)

AC_CHECK_FILE does not work in cross builds. Such builds aborted.
Replace it by AC_CHECK_HEADERS. This fixes cross builds.

To enable TensorFlow in cross builds, more work is needed.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
This commit is contained in:
Stefan Weil 2019-05-26 17:29:23 +02:00
parent 3b210ec059
commit 3c9691f286

View File

@ -203,7 +203,7 @@ AC_ARG_WITH([tensorflow],
AM_CONDITIONAL([TENSORFLOW], false)
TENSORFLOW_LIBS=
AS_IF([test "x$with_tensorflow" != xno],
[AC_CHECK_FILE([/usr/include/tensorflow/core/framework/graph.pb.h],
[AC_CHECK_HEADERS(["tensorflow/core/framework/graph.pb.h"],
[AC_SUBST([TENSORFLOW_LIBS], ["-lprotobuf -ltensorflow_cc"])
AM_CONDITIONAL([TENSORFLOW], true)
],