]> sigrok.org Git - libsigrok.git/commitdiff
configure.ac: Don't build BeagleLogic where a build would fail.
authorUwe Hermann <redacted>
Mon, 4 Aug 2014 20:00:17 +0000 (22:00 +0200)
committerUwe Hermann <redacted>
Tue, 5 Aug 2014 15:32:28 +0000 (17:32 +0200)
The BeagleLogic driver needs sys/mman.h and sys/ioctl.h in order to
build, so disable the driver if those headers aren't available.

This is the case (for example) on MinGW.

configure.ac

index d2faf59a42552e12731d4547a77cf5ac0b14ea40..68f9d1f6170209ad35a570fb2622c85b79308270 100644 (file)
@@ -409,6 +409,10 @@ case "$host" in
        ;;
 esac
 
+# The BeagleLogic driver needs sys/mman.h and sys/ioctl.h. Don't try to
+# build it if these headers aren't available.
+AC_CHECK_HEADERS([sys/mman.h sys/ioctl.h], [], [HW_BEAGLELOGIC="no"])
+
 AC_SUBST(SR_PKGLIBS)
 
 CFLAGS="$CFLAGS -I./include/libsigrok $LIB_CFLAGS"
@@ -633,7 +637,8 @@ AM_CONDITIONAL(BINDINGS_PYTHON, test x$BINDINGS_PYTHON = xyes)
 AM_CONDITIONAL(BINDINGS_JAVA, test x$BINDINGS_JAVA = xyes)
 
 # Checks for header files.
-# These are already checked: inttypes.h stdint.h stdlib.h string.h unistd.h.
+# These are already implicitly checked: inttypes.h stdint.h stdlib.h string.h
+# unistd.h memory.h strings.h dlfcn.h sys/types.h sys/stat.h.
 
 # Checks for typedefs, structures, and compiler characteristics.
 AC_C_BIGENDIAN