aboutsummaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorStephan Raue <stephan@openelec.tv>2011-09-19 11:29:21 -0700
committerStephan Raue <stephan@openelec.tv>2011-09-19 11:29:21 -0700
commit1d0c129c8a05f531b3db1cc0b475fee2a6ae32ab (patch)
tree3261bd66769f9add917990c63ff644b0b3d3b1ec /configure.in
parent8d7aebd16e21db160993ebfc95822e2ba0a85b74 (diff)
parent6e3715830eccb23dda5145e4098e4476c5d7ed62 (diff)
Merge pull request #427 from sraue/optional-samba
configure: let select samba support, this patch adds a configure option to en/disable samba support in xbmc. this is usefull if xbmc is not used as a full mediacenter (kiosk systems, embedded systems) where a minimal OS is needed (not using libsmbclient can save around 6MB) or to restrict samba access from xbmc for various reasons. samba support is enabled by default and configure breaks with missing_library if libsmbclient is not found and samba support is not explicity disabled at configure time. on windows samba support is fully enabled
Diffstat (limited to 'configure.in')
-rwxr-xr-xconfigure.in30
1 files changed, 29 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index 04d4c5cb2e..7c2149f026 100755
--- a/configure.in
+++ b/configure.in
@@ -111,6 +111,7 @@ libnfs_not_found="== Could not find libnfs. NFS support disabled. =="
libnfs_disabled="== NFS support disabled. =="
libafpclient_not_found="== Could not find libafpclient. AFP support disabled. =="
libafpclient_disabled="== AFP support disabled. =="
+samba_disabled="== SAMBA support disabled. =="
alsa_not_found="== Could not find ALSA. ALSA support disabled. =="
dbus_not_found="== Could not find DBUS. DBUS support disabled. =="
@@ -270,6 +271,12 @@ AC_ARG_ENABLE([rtmp],
[use_librtmp=$enableval],
[use_librtmp=auto])
+AC_ARG_ENABLE([samba],
+ [AS_HELP_STRING([--disable-samba],
+ [disable SAMBA support (default is enabled)])],
+ [use_samba=$enableval],
+ [use_samba=yes])
+
AC_ARG_ENABLE([nfs],
[AS_HELP_STRING([--enable-nfs],
[enable NFS support via libnfs (default is auto)])],
@@ -647,7 +654,6 @@ AC_CHECK_LIB([crypto], [main],, AC_MSG_ERROR($missing_library))
AC_CHECK_LIB([ssl], [main],, AC_MSG_ERROR($missing_library))
AC_CHECK_LIB([mysqlclient], [main],, AC_MSG_ERROR($missing_library))
AC_CHECK_LIB([ssh], [sftp_tell64],, AC_MSG_RESULT([Could not find suitable version of libssh]))
-AC_CHECK_LIB([smbclient], [main],, AC_MSG_ERROR($missing_library))
AC_CHECK_LIB([bluetooth], [hci_devid],, AC_MSG_RESULT([Could not find suitable version of libbluetooth]))
AC_CHECK_LIB([yajl], [main],, AC_MSG_ERROR($missing_library))
@@ -934,6 +940,21 @@ else
AC_MSG_NOTICE($librtmp_disabled)
fi
+# samba
+if test "x$use_samba" != "xno"; then
+ AC_CHECK_LIB([smbclient], [main],,
+ use_samba=no;AC_MSG_ERROR($missing_library))
+ USE_LIBSMBCLIENT=0
+else
+ AC_MSG_RESULT($samba_disabled)
+ USE_LIBSMBCLIENT=0
+fi
+
+if test "x$use_samba" != "xno"; then
+ AC_DEFINE([HAVE_LIBSMBCLIENT], [1], [Define to 1 if you have Samba installed])
+ USE_LIBSMBCLIENT=1
+fi
+
# libnfs
if test "$use_libnfs" != "no"; then
AC_CHECK_HEADERS([nfsc/libnfs.h],,
@@ -1562,6 +1583,12 @@ else
final_message="$final_message\n libRTMP support:\tNo"
fi
+if test "x$use_samba" != "xno"; then
+ final_message="$final_message\n libsmbclient support:\tYes"
+else
+ final_message="$final_message\n libsmbclient support:\tNo"
+fi
+
if test "$use_libnfs" != "no"; then
final_message="$final_message\n libnfs support:\tYes"
else
@@ -1683,6 +1710,7 @@ AC_SUBST(USE_OPENGLES)
AC_SUBST(USE_VDPAU)
AC_SUBST(USE_VAAPI)
AC_SUBST(USE_CRYSTALHD)
+AC_SUBST(USE_LIBSMBCLIENT)
AC_SUBST(USE_LIBNFS)
AC_SUBST(USE_LIBAFPCLIENT)
AC_SUBST(USE_VDA)