diff options
author | Gerald Carter <jerry@samba.org> | 2003-01-28 20:55:09 +0000 |
---|---|---|
committer | Gerald Carter <jerry@samba.org> | 2003-01-28 20:55:09 +0000 |
commit | 4571637a4bdd0d63367186f5612e49934fe568f6 (patch) | |
tree | f2153d3dd299d3c1984d961e30adf910e526558c /source3/configure.in | |
parent | cc0af58dc2dee7860621c75866c1104c8bc24b1d (diff) | |
download | samba-4571637a4bdd0d63367186f5612e49934fe568f6.tar.gz samba-4571637a4bdd0d63367186f5612e49934fe568f6.tar.bz2 samba-4571637a4bdd0d63367186f5612e49934fe568f6.zip |
patch from Paul Green to only build libsmbclient.so on platforms that support shared libraries
(This used to be commit f739a7263d9da6edc2ecba5b942253c22f7cb3f8)
Diffstat (limited to 'source3/configure.in')
-rw-r--r-- | source3/configure.in | 31 |
1 files changed, 21 insertions, 10 deletions
diff --git a/source3/configure.in b/source3/configure.in index 4590e5313e..06066f28d9 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -140,6 +140,8 @@ AC_SUBST(PICFLAG) AC_SUBST(PICSUFFIX) AC_SUBST(POBAD_CC) AC_SUBST(SHLIBEXT) +AC_SUBST(INSTALLCLIENTCMD_SH) +AC_SUBST(INSTALLCLIENTCMD_A) AC_SUBST(LIBSMBCLIENT_SHARED) AC_SUBST(LIBSMBCLIENT) AC_SUBST(PRINTLIBS) @@ -1115,13 +1117,6 @@ if test $ac_cv_shlib_works = no; then fi fi -# this updates our target list if we can build shared libs -if test $BLDSHARED = true; then - LIBSMBCLIENT_SHARED=bin/libsmbclient.$SHLIBEXT -else - LIBSMBCLIENT_SHARED= -fi - ################ AC_CACHE_CHECK([for long long],samba_cv_have_longlong,[ @@ -2558,26 +2553,42 @@ AC_ARG_WITH(manpages-langs, ################################################# # should we build libsmbclient? +INSTALLCLIENTCMD_SH=: +INSTALLCLIENTCMD_A=: LIBSMBCLIENT_SHARED= LIBSMBCLIENT= AC_MSG_CHECKING(whether to build the libsmbclient shared library) AC_ARG_WITH(libsmbclient, -[ --with-libsmbclient Build the libsmbclient shared library (default=yes)], +[ --with-libsmbclient Build the libsmbclient shared library (default=yes if shared libs supported)], [ case "$withval" in no) AC_MSG_RESULT(no) ;; *) if test $BLDSHARED = true; then + INSTALLCLIENTCMD_SH="\$(INSTALLCMD)" LIBSMBCLIENT_SHARED=bin/libsmbclient.$SHLIBEXT LIBSMBCLIENT=libsmbclient AC_MSG_RESULT(yes) else - AC_MSG_RESULT(no shared library support) + INSTALLCLIENTCMD_A="\$(INSTALLCMD)" + LIBSMBCLIENT=libsmbclient + AC_MSG_RESULT(no shared library support -- will supply static library) fi ;; esac ], - AC_MSG_RESULT(yes) +[ +# if unspecified, default is to built it iff possible. + if test $BLDSHARED = true; then + INSTALLCLIENTCMD_SH="\$(INSTALLCMD)" + LIBSMBCLIENT_SHARED=bin/libsmbclient.$SHLIBEXT + LIBSMBCLIENT=libsmbclient + AC_MSG_RESULT(yes) + else + INSTALLCLIENTCMD_A="\$(INSTALLCMD)" + LIBSMBCLIENT=libsmbclient + AC_MSG_RESULT(no shared library support -- will supply static library) + fi] ) |