AS_COMPILER_FLAG([-Wno-unused-function],[PYTHON_QUIET="$PYTHON_QUIET -Wno-unused-function"], true )
AC_SUBST(PYTHON_QUIET)
-AC_ARG_ENABLE([ruby-binding],[ --disable-ruby-binding Disable building of Ruby binding],
- [ENABLE_RUBY=$enableval],[ENABLE_RUBY="yes"])
+AC_ARG_ENABLE([ruby-binding], [ --disable-ruby-binding Disable building of Ruby binding],
+ [ENABLE_RUBY=$enableval], [ENABLE_RUBY="yes"])
AC_PATH_PROG(RUBY, ruby, no)
-if test "$RUBY" == "no" ; then
+if test "$RUBY" != "no" ; then
+ RUBY_INC_DIR=`$RUBY -e "require 'rbconfig'; c = ::Config::CONFIG; print c[['archdir']];"`
+ AC_CHECK_HEADER([$RUBY_INC_DIR/ruby.h],[],[ENABLE_RUBY="no";AC_MSG_WARN([ruby.h not found, disabling Ruby binding])])
+else
AC_MSG_WARN([ruby not found, disabling ruby binding])
ENABLE_RUBY="no"
fi
AM_CONDITIONAL(HAVE_RUBY, [test "$ENABLE_RUBY" == "yes"])
-AC_ARG_VAR(RUBY_PREFIX,[path prefix for Ruby binding [PREFIX/]])
+AC_ARG_VAR(RUBY_PREFIX,[path prefix for Ruby binding])
AC_ARG_VAR(RUBY_SO_DIR,[path for Ruby extensions])
if test "$RUBY_PREFIX" != "" ; then
RUBY_CONFIG_OPTIONS="$RUBY_CONFIG_OPTIONS --prefix=\$(RUBY_PREFIX)"
fi
AC_SUBST(RUBY_CONFIG_OPTIONS)
+AC_ARG_ENABLE([scxi], [ --enable-scxi Enable SCXI convenience library],
+ [ENABLE_SCXI=$enableval], [ENABLE_SCXI="no"])
+AM_CONDITIONAL(BUILD_SCXI, [test "$ENABLE_SCXI" == "yes"])
+
AC_PATH_PROG(DOCBOOK2MAN, docbook2man, no)
if test "$DOCBOOK2MAN" = "no" ; then
AC_MSG_WARN([docbook2man not found, will not be able to rebuild man pages])
#see: http://linux-hotplug.sourceforge.net/
#the hotplug expects the device dependent scripts here:
-usbhotplugdir="/etc/hotplug/usb"
+usbhotplugdir="\${sysconfdir}/hotplug/usb"
AC_SUBST(usbhotplugdir)
#firmware for the hotplug script
#see: http://linux-hotplug.sourceforge.net/
-usbfirmwaredir="/usr/share/usb"
+usbfirmwaredir="\${datadir}/usb"
AC_SUBST(usbfirmwaredir)
AC_CONFIG_FILES(
include/Makefile
lib/Makefile
man/Makefile
+scxi/Makefile
swig/Makefile
swig/python/Makefile
swig/ruby/Makefile