From 4dd95908c0ef058597823b7d957511fdc7ca9de8 Mon Sep 17 00:00:00 2001 From: "Andrew V. Samoilov" Date: Tue, 13 Nov 2001 11:42:53 +0000 Subject: [PATCH] * samba/lib/system.c (sys_chroot): Removed. * samba/configure.in: Remove RUNPROG. Don't check for chroot and execl functions. Remove syslog logging support. Add --with-codepagedir and --with-configdir from samba 2.2.2. * samba/Makefile.in: Use configdir and codepagedir. --- vfs/ChangeLog | 12 +++++++- vfs/samba/Makefile.in | 6 ++-- vfs/samba/configure.in | 67 ++++++++++++++++++++++++------------------ vfs/samba/lib/system.c | 16 ---------- 4 files changed, 53 insertions(+), 48 deletions(-) diff --git a/vfs/ChangeLog b/vfs/ChangeLog index ef71336e9..726af6157 100644 --- a/vfs/ChangeLog +++ b/vfs/ChangeLog @@ -1,3 +1,13 @@ +2001-11-13 Andrew V. Samoilov + + * samba/lib/system.c (sys_chroot): Removed. + * samba/configure.in: Remove RUNPROG. Don't check + for chroot and execl functions. + Remove syslog logging support. + Add --with-codepagedir and --with-configdir from samba 2.2.2. + + * samba/Makefile.in: Use configdir and codepagedir. + 2001-11-08 Pavel Roskin * Make-mc.in (SAMBA_DIST): Remove lib/getsmbpass.c. @@ -7,7 +17,7 @@ * smbfs.c (smbfs_add_dots): New function. Insert a "." and ".." entries into the linked list. (smbfs_loaddir): Call smbfs_add_dots for shares or servers. - (smbfs_get_free_bucket): Eliminate utime. + (smbfs_get_free_bucket): Eliminate time. (fake_share_stat): Make path const. * samba/configure.in: Don't check whether getpass diff --git a/vfs/samba/Makefile.in b/vfs/samba/Makefile.in index ff3fe9c8b..4e8ec2b86 100644 --- a/vfs/samba/Makefile.in +++ b/vfs/samba/Makefile.in @@ -38,8 +38,8 @@ INSTALLPERMS = 0755 # or in smb.conf (see smb.conf(5)) SMBLOGFILE = $(VARDIR)/log.smb NMBLOGFILE = $(VARDIR)/log.nmb -CONFIGFILE = $(LIBDIR)/smb.conf -LMHOSTSFILE = $(LIBDIR)/lmhosts +CONFIGFILE = @configdir@/smb.conf +LMHOSTSFILE = @configdir@/lmhosts DRIVERFILE = $(LIBDIR)/printers.def PASSWD_PROGRAM = /bin/passwd # This is where smbpasswd et al go @@ -51,7 +51,7 @@ SMB_PASSWD_FILE = $(PRIVATEDIR)/smbpasswd LOCKDIR = @lockdir@ # The directory where code page definition files go -CODEPAGEDIR = $(LIBDIR)/codepages +CODEPAGEDIR = @codepagedir@ # The current codepage definition list. CODEPAGELIST= 437 737 850 852 861 932 866 949 950 936 diff --git a/vfs/samba/configure.in b/vfs/samba/configure.in index ddfae87e1..c4f4e6e41 100644 --- a/vfs/samba/configure.in +++ b/vfs/samba/configure.in @@ -6,7 +6,6 @@ AC_PREFIX_DEFAULT(/usr/local/samba) dnl Unique-to-Samba variables we'll be playing with. AC_SUBST(SHELL) -AC_SUBST(RUNPROG) AC_SUBST(MPROGS) AC_SUBST(LDSHFLAGS) AC_SUBST(HOST_OS) @@ -160,15 +159,7 @@ if test x"$ac_cv_func_connect" = x"no"; then fi fi -# Check if we have execl, if not we need to compile smbrun. -AC_CHECK_FUNCS(execl) -if test x"$ac_cv_func_execl" = x"no"; then - RUNPROG="bin/smbrun" -else - RUNPROG="" -fi - -AC_CHECK_FUNCS(waitpid getcwd strdup strtoul strerror chown chmod chroot) +AC_CHECK_FUNCS(waitpid getcwd strdup strtoul strerror chown chmod) AC_CHECK_FUNCS(fstat strchr utime utimes getrlimit fsync bzero memset) AC_CHECK_FUNCS(memmove vsnprintf snprintf setsid glob strpbrk pipe crypt16 getauthuid) AC_CHECK_FUNCS(strftime sigprocmask sigblock sigaction innetgr setnetgrent getnetgrent endnetgrent) @@ -707,24 +698,6 @@ AC_ARG_WITH(ssl, ) -################################################# -# check for syslog logging -AC_MSG_CHECKING([whether to use syslog logging]) -AC_ARG_WITH(syslog, -[ --with-syslog Include experimental SYSLOG support - --without-syslog Don't include SYSLOG support (default)], -[ case "$withval" in - yes) - AC_MSG_RESULT(yes) - AC_DEFINE(WITH_SYSLOG) - ;; - *) - AC_MSG_RESULT(no) - ;; - esac ], - AC_MSG_RESULT(no) -) - ################################################# # set private directory location AC_ARG_WITH(privatedir, @@ -767,6 +740,42 @@ AC_ARG_WITH(lockdir, AC_SUBST(lockdir)] ) +################################################# +# set configuration directory location +configdir="\$(LIBDIR)" +AC_ARG_WITH(configdir, +[ --with-configdir=DIR Where to put configuration files (\$libdir)], +[ case "$withval" in + yes|no) + # + # Just in case anybody does it + # + AC_MSG_WARN([--with-configdir called without argument - will use default]) + ;; + * ) + configdir="$withval" + ;; + esac] +) + + +################################################# +# set codepage directory location +codepagedir="\$(LIBDIR)/codepages" +AC_ARG_WITH(codepagedir, +[ --with-codepagedir=DIR Where to put codepage files (\$libdir/codepages)], +[ case "$withval" in + yes|no) + # + # Just in case anybody does it + # + AC_MSG_WARN([--with-codepagedir called without argument - will use default]) + ;; + * ) + codepagedir="$withval" + ;; + esac]) + AC_MSG_CHECKING([configure summary]) AC_TRY_RUN([#include "${srcdir-.}/tests/summary.c"], AC_MSG_RESULT(OK);, @@ -775,5 +784,7 @@ AC_TRY_RUN([#include "${srcdir-.}/tests/summary.c"], builddir=`pwd` AC_SUBST(builddir) +AC_SUBST(configdir) +AC_SUBST(codepagedir) AC_OUTPUT([include/stamp-h Makefile]) diff --git a/vfs/samba/lib/system.c b/vfs/samba/lib/system.c index e0b19fd15..14cf62294 100644 --- a/vfs/samba/lib/system.c +++ b/vfs/samba/lib/system.c @@ -385,22 +385,6 @@ int sys_chown(const char *fname,uid_t uid,gid_t gid) #endif } -/******************************************************************* -os/2 also doesn't have chroot -********************************************************************/ -int sys_chroot(const char *dname) -{ -#ifndef HAVE_CHROOT - static int done; - if (!done) { - DEBUG(1,("WARNING: no chroot!\n")); - done=1; - } -#else - return(chroot(dname)); -#endif -} - /************************************************************************** A wrapper for gethostbyname() that tries avoids looking up hostnames in the root domain, which can cause dial-on-demand links to come up for no