diff options
author | taca <taca> | 2002-02-05 00:36:25 +0000 |
---|---|---|
committer | taca <taca> | 2002-02-05 00:36:25 +0000 |
commit | 3bf0a54dcbc5c96bf1ddd5c3543ff29d3834ac3c (patch) | |
tree | 4f6128b286293d46ce2c075b08e2bcf59f1d23ec /net/samba | |
parent | 8a3fd7f005eeb0a00b875e5ca641791b819b7878 (diff) | |
download | pkgsrc-3bf0a54dcbc5c96bf1ddd5c3543ff29d3834ac3c.tar.gz |
(1) Change Samba's "lockdir" from /var/run/samba to /var/db/samba.
(2) Add "piddir" as /var/run and "pidfile dir" and "pidfile directory"
statement for smb.conf.
(3) Some fix for password synchronization but it isn't tested much and
it is almost useless under "encrypt passwords = yes" environment.
Changes for INSTALL and part of Makefile are provided by
"Johnny C. Lam" <jlam@netbsd.org> and (2) and (3) are got
from FreeBSD ports.
Bump revision to 1; samba-2.2.3nb1 now.
Diffstat (limited to 'net/samba')
-rw-r--r-- | net/samba/INSTALL | 17 | ||||
-rw-r--r-- | net/samba/Makefile | 17 | ||||
-rw-r--r-- | net/samba/PLIST | 4 | ||||
-rw-r--r-- | net/samba/distinfo | 9 | ||||
-rw-r--r-- | net/samba/patches/patch-aa | 52 | ||||
-rw-r--r-- | net/samba/patches/patch-ab | 65 | ||||
-rw-r--r-- | net/samba/patches/patch-ak | 37 | ||||
-rw-r--r-- | net/samba/patches/patch-al | 17 | ||||
-rw-r--r-- | net/samba/patches/patch-am | 12 | ||||
-rw-r--r-- | net/samba/patches/patch-an | 22 | ||||
-rw-r--r-- | net/samba/patches/patch-ao | 37 |
11 files changed, 278 insertions, 11 deletions
diff --git a/net/samba/INSTALL b/net/samba/INSTALL index cfcf2709cbf..d7fc2cf143c 100644 --- a/net/samba/INSTALL +++ b/net/samba/INSTALL @@ -1,7 +1,8 @@ #!/bin/sh # -# $NetBSD: INSTALL,v 1.2 2001/11/21 16:44:17 jlam Exp $ +# $NetBSD: INSTALL,v 1.3 2002/02/05 00:36:25 taca Exp $ +SAMBA_LOCKDIR="@SAMBA_LOCKDIR@" SAMBA_PRIVATE="@SAMBA_PRIVATE@" case ${STAGE} in @@ -17,5 +18,19 @@ POST-INSTALL) ${CHMOD} 500 ${SAMBA_PRIVATE} echo "done." fi + + # Check for files in old "lock" directory. + if [ -e /var/run/samba ] + then + ${CAT} << EOF +=========================================================================== + +The location of the Samba cache directory has moved to ${SAMBA_LOCKDIR}. +If you have any files under /var/run/samba, please move them into +${SAMBA_LOCKDIR} and restart the SMB and NMB servers. + +=========================================================================== +EOF + fi ;; esac diff --git a/net/samba/Makefile b/net/samba/Makefile index b2700faaf31..34ca8878229 100644 --- a/net/samba/Makefile +++ b/net/samba/Makefile @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.77 2002/02/04 21:33:19 tron Exp $ +# $NetBSD: Makefile,v 1.78 2002/02/05 00:36:25 taca Exp $ DISTNAME= samba-2.2.3 +PKGREVISION= 1 WRKSRC= ${WRKDIR}/${DISTNAME}/source CATEGORIES= net MASTER_SITES= ftp://ftp.samba.org/pub/samba/ \ @@ -25,21 +26,24 @@ USE_GNU_READLINE= # uses rl_event_hook interface to GNU readline PKG_SYSCONFSUBDIR?= samba -SAMBA_LOGDIR?= /var/log -SAMBA_LOCKDIR?= /var/run/samba +VARDIR?= /var SAMBA_ETCDIR?= ${PKG_SYSCONFDIR} -SAMBA_PRIVATE?= ${SAMBA_ETCDIR}/private SAMBA_DATADIR= ${PREFIX}/share +SAMBA_LOCKDIR?= ${VARDIR}/db/samba +SAMBA_LOGDIR?= ${VARDIR}/log +SAMBA_PIDDIR?= ${VARDIR}/run +SAMBA_PRIVATE?= ${SAMBA_ETCDIR}/private MAKE_ENV+= ETCDIR=${SAMBA_ETCDIR} MAKE_ENV+= LOGDIR=${SAMBA_LOGDIR} -CONFIGURE_ARGS+= --localstatedir=${SAMBA_LOGDIR} +CONFIGURE_ARGS+= --localstatedir=${VARDIR} CONFIGURE_ARGS+= --sbindir=${PREFIX}/sbin CONFIGURE_ARGS+= --with-configdir=${SAMBA_ETCDIR} CONFIGURE_ARGS+= --with-codepagedir=${SAMBA_DATADIR}/samba/codepages CONFIGURE_ARGS+= --with-datadir=${SAMBA_DATADIR} CONFIGURE_ARGS+= --with-lockdir=${SAMBA_LOCKDIR} +CONFIGURE_ARGS+= --with-piddir=${SAMBA_PIDDIR} CONFIGURE_ARGS+= --with-privatedir=${SAMBA_PRIVATE} CONFIGURE_ARGS+= --with-swatdir=${SAMBA_DATADIR}/samba/swat @@ -86,8 +90,7 @@ MESSAGE_SUBST+= ETCDIR=${SAMBA_ETCDIR} CONF_FILES= ${EXAMPLESDIR}/smb.conf.sample ${SAMBA_ETCDIR}/smb.conf RCD_SCRIPTS= samba nmbd smbd -MAKE_DIRS= ${SAMBA_LOCKDIR} -OWN_DIRS= ${SAMBA_ETCDIR} ${SAMBA_PRIVATE} +OWN_DIRS= ${SAMBA_ETCDIR} ${SAMBA_PRIVATE} ${SAMBA_LOCKDIR} INSTALL_EXTRA_TMPL= ${PKGDIR}/INSTALL diff --git a/net/samba/PLIST b/net/samba/PLIST index e441187a333..3a639fb2ab6 100644 --- a/net/samba/PLIST +++ b/net/samba/PLIST @@ -1,4 +1,4 @@ -@comment $NetBSD: PLIST,v 1.4 2002/02/04 10:31:49 martti Exp $ +@comment $NetBSD: PLIST,v 1.5 2002/02/05 00:36:26 taca Exp $ bin/make_printerdef bin/make_smbcodepage bin/make_unicodemap @@ -152,9 +152,9 @@ share/examples/samba/printer-accounting/hp5-redir share/examples/samba/printer-accounting/lp-acct share/examples/samba/printer-accounting/printcap share/examples/samba/printing/smbprint +share/examples/samba/printing/smbprint-new.sh share/examples/samba/printing/smbprint.newer share/examples/samba/printing/smbprint.sysv -share/examples/samba/printing/smbprint-new.sh share/examples/samba/simple/README share/examples/samba/simple/smb.conf share/examples/samba/smb.conf.default diff --git a/net/samba/distinfo b/net/samba/distinfo index 68801df7b68..866e09bb16e 100644 --- a/net/samba/distinfo +++ b/net/samba/distinfo @@ -1,9 +1,16 @@ -$NetBSD: distinfo,v 1.14 2002/02/04 08:09:03 martti Exp $ +$NetBSD: distinfo,v 1.15 2002/02/05 00:36:26 taca Exp $ SHA1 (samba-2.2.3.tar.gz) = df469c3cbe15cd8379d47487ad749ef4407aa405 Size (samba-2.2.3.tar.gz) = 7138400 bytes +SHA1 (patch-aa) = 10a0f8f0f92b2ceae89eb4307ea5e60b6364b425 +SHA1 (patch-ab) = 92e8d3721ff137d90ae2e2fcf6d5c6820a90273e SHA1 (patch-ac) = a055bcc69e1a40124ada075ac836d1061ecfcd15 SHA1 (patch-ag) = 256a7e1edb961985398a94c0b738fd96fe781f9c SHA1 (patch-ah) = e87f2e393db68acc7028fe20d4772455379ad7aa SHA1 (patch-ai) = cc31eb9cfb2ee650400c18ceaaa9ec1a3626260f SHA1 (patch-aj) = e2c5f7580a8c701b6bf35d0d3004f714f2c810cb +SHA1 (patch-ak) = 110a676a911867b64bc319fceaf5e1dc1d7ecb26 +SHA1 (patch-al) = 368c7f88c5538fcaa32d7263ba98d138ba179859 +SHA1 (patch-am) = 82ea8411d7988aa4b49bf98825d368339bbc25ec +SHA1 (patch-an) = 74ce033913cc6ba19b1d98640a9f1a554286a9d7 +SHA1 (patch-ao) = b1fd0c8c73d88a4d53ca4f0f8b969f0744301ce7 diff --git a/net/samba/patches/patch-aa b/net/samba/patches/patch-aa new file mode 100644 index 00000000000..b601a7cae1a --- /dev/null +++ b/net/samba/patches/patch-aa @@ -0,0 +1,52 @@ +$NetBSD: patch-aa,v 1.17 2002/02/05 00:36:26 taca Exp $ + +--- configure.in.orig Sun Feb 3 09:46:35 2002 ++++ configure.in +@@ -13,13 +13,15 @@ + codepagedir="\$(DATADIR)/samba/codepages" + configdir="${sysconfdir}/samba" + lockdir="\${VARDIR}/cache/samba" ++ piddir="\$(VARDIR)/run" + logfilebase="\${VARDIR}/log/samba" + privatedir="\${CONFIGDIR}/private" + swatdir="\${DATADIR}/samba/swat", + codepagedir="\$(LIBDIR)/codepages" + configdir="\$(LIBDIR)" + lockdir="\$(VARDIR)/locks" +- logfilebase="\$(VARDIR)" ++ piddir="\${VARDIR}/run" ++ logfilebase="\$(VARDIR)/log" + privatedir="\${prefix}/private" + swatdir="\${prefix}/swat") + +@@ -56,6 +58,22 @@ + esac]) + + ################################################# ++# set pid directory location ++AC_ARG_WITH(piddir, ++[ --with-piddir=DIR Where to put lock files (\${VARDIR}/run)], ++[ case "$withval" in ++ yes|no) ++ # ++ # Just in case anybody calls it without argument ++ # ++ AC_MSG_WARN([--with-piddir called without argument - will use default]) ++ ;; ++ * ) ++ piddir="$withval" ++ ;; ++ esac]) ++ ++################################################# + # set SWAT directory location + AC_ARG_WITH(swatdir, + [ --with-swatdir=DIR Where to put SWAT files ($ac_default_prefix/swat)], +@@ -123,6 +141,7 @@ + AC_SUBST(configdir) + AC_SUBST(lockdir) + AC_SUBST(logfilebase) ++AC_SUBST(piddir) + AC_SUBST(privatedir) + AC_SUBST(swatdir) + AC_SUBST(bindir) diff --git a/net/samba/patches/patch-ab b/net/samba/patches/patch-ab new file mode 100644 index 00000000000..c88fe6eae96 --- /dev/null +++ b/net/samba/patches/patch-ab @@ -0,0 +1,65 @@ +$NetBSD: patch-ab,v 1.13 2002/02/05 00:36:26 taca Exp $ + +--- configure.orig Sun Feb 3 09:46:35 2002 ++++ configure +@@ -19,6 +19,8 @@ + ac_help="$ac_help + --with-lockdir=DIR Where to put lock files ($ac_default_prefix/var/locks)" + ac_help="$ac_help ++ --with-piddir=DIR Where to put lock files (\${VARDIR}/run)" ++ac_help="$ac_help + --with-swatdir=DIR Where to put SWAT files ($ac_default_prefix/swat)" + ac_help="$ac_help + --with-configdir=DIR Where to put configuration files (\$libdir)" +@@ -604,6 +606,7 @@ + codepagedir="\$(DATADIR)/samba/codepages" + configdir="${sysconfdir}/samba" + lockdir="\${VARDIR}/cache/samba" ++ piddir="\$(VARDIR)/run" + logfilebase="\${VARDIR}/log/samba" + privatedir="\${CONFIGDIR}/private" + swatdir="\${DATADIR}/samba/swat" +@@ -611,7 +614,8 @@ + codepagedir="\$(LIBDIR)/codepages" + configdir="\$(LIBDIR)" + lockdir="\$(VARDIR)/locks" +- logfilebase="\$(VARDIR)" ++ piddir="\${VARDIR}/run" ++ logfilebase="\$(VARDIR)/log" + privatedir="\${prefix}/private" + swatdir="\${prefix}/swat" + fi +@@ -656,6 +660,25 @@ + + + ################################################# ++# set pid directory location ++# Check whether --with-piddir or --without-piddir was given. ++if test "${with_piddir+set}" = set; then ++ withval="$with_piddir" ++ case "$withval" in ++ yes|no) ++ # ++ # Just in case anybody calls it without argument ++ # ++ echo "configure: warning: --with-piddir called without argument - will use default" 1>&2 ++ ;; ++ * ) ++ piddir="$withval" ++ ;; ++ esac ++fi ++ ++ ++################################################# + # set SWAT directory location + # Check whether --with-swatdir or --without-swatdir was given. + if test "${with_swatdir+set}" = set; then +@@ -13167,6 +13190,7 @@ + s%@configdir@%$configdir%g + s%@lockdir@%$lockdir%g + s%@logfilebase@%$logfilebase%g ++s%@piddir@%$piddir%g + s%@privatedir@%$privatedir%g + s%@swatdir@%$swatdir%g + s%@RUNPROG@%$RUNPROG%g diff --git a/net/samba/patches/patch-ak b/net/samba/patches/patch-ak new file mode 100644 index 00000000000..41cbcf3c0a2 --- /dev/null +++ b/net/samba/patches/patch-ak @@ -0,0 +1,37 @@ +$NetBSD: patch-ak,v 1.1 2002/02/05 00:36:27 taca Exp $ + +--- Makefile.in.orig Sun Feb 3 09:46:05 2002 ++++ Makefile.in +@@ -46,11 +46,11 @@ + # set these to where to find various files + # These can be overridden by command line switches (see smbd(8)) + # or in smb.conf (see smb.conf(5)) +-LOGFILEBASE = @logfilebase@ ++LOGFILEBASE = $(VARDIR)/log + CONFIGFILE = $(CONFIGDIR)/smb.conf + LMHOSTSFILE = $(CONFIGDIR)/lmhosts + DRIVERFILE = $(CONFIGDIR)/printers.def +-PASSWD_PROGRAM = /bin/passwd ++PASSWD_PROGRAM = /usr/bin/passwd + # This is where smbpasswd et al go + PRIVATEDIR = @privatedir@ + +@@ -63,6 +63,9 @@ + # the directory where lock files go + LOCKDIR = @lockdir@ + ++# the directory where pid files go ++PIDFILEDIR = /var/run ++ + # libsmbclient support here + BLDSHARED = @BLDSHARED@ + LIBSMBCLIENT_MAJOR=0 +@@ -78,7 +81,7 @@ + PASSWD_FLAGS = -DPASSWD_PROGRAM=\"$(PASSWD_PROGRAM)\" -DSMB_PASSWD_FILE=\"$(SMB_PASSWD_FILE)\" -DTDB_PASSWD_FILE=\"$(TDB_PASSWD_FILE)\" + FLAGS1 = $(CFLAGS) -Iinclude -I$(srcdir)/include -I$(srcdir)/ubiqx -I$(srcdir)/smbwrapper $(CPPFLAGS) -DLOGFILEBASE=\"$(LOGFILEBASE)\" + FLAGS2 = -DCONFIGFILE=\"$(CONFIGFILE)\" -DLMHOSTSFILE=\"$(LMHOSTSFILE)\" +-FLAGS3 = -DSWATDIR=\"$(SWATDIR)\" -DSBINDIR=\"$(SBINDIR)\" -DLOCKDIR=\"$(LOCKDIR)\" -DCODEPAGEDIR=\"$(CODEPAGEDIR)\" ++FLAGS3 = -DSWATDIR=\"$(SWATDIR)\" -DSBINDIR=\"$(SBINDIR)\" -DLOCKDIR=\"$(LOCKDIR)\" -DPIDFILEDIR=\"$(PIDFILEDIR)\" -DSMBRUN=\"$(SMBRUN)\" -DCODEPAGEDIR=\"$(CODEPAGEDIR)\" + FLAGS4 = -DDRIVERFILE=\"$(DRIVERFILE)\" -DBINDIR=\"$(BINDIR)\" + FLAGS5 = $(FLAGS1) $(FLAGS2) $(FLAGS3) $(FLAGS4) -DHAVE_INCLUDES_H + FLAGS = $(ISA) $(FLAGS5) $(PASSWD_FLAGS) diff --git a/net/samba/patches/patch-al b/net/samba/patches/patch-al new file mode 100644 index 00000000000..3b0f1f65e70 --- /dev/null +++ b/net/samba/patches/patch-al @@ -0,0 +1,17 @@ +$NetBSD: patch-al,v 1.1 2002/02/05 00:36:27 taca Exp $ + +--- include/local.h.orig Sun Feb 3 09:46:39 2002 ++++ include/local.h +@@ -170,10 +170,10 @@ + * Default passwd chat script. + */ + +-#define DEFAULT_PASSWD_CHAT "*new*password* %n\\n *new*password* %n\\n *changed*" ++#define DEFAULT_PASSWD_CHAT "*\\n*ew\\spassword* %n\\n *ew\\spassword* %n\\n *updating\\sthe\\sdatabase...\\npasswd:\\sdone\\n" + + /* Minimum length of allowed password when changing UNIX password. */ +-#define MINPASSWDLENGTH 5 ++#define MINPASSWDLENGTH 6 + + /* maximum ID number used for session control. This cannot be larger + than 62*62 for the current code */ diff --git a/net/samba/patches/patch-am b/net/samba/patches/patch-am new file mode 100644 index 00000000000..9ea45e24b64 --- /dev/null +++ b/net/samba/patches/patch-am @@ -0,0 +1,12 @@ +$NetBSD: patch-am,v 1.1 2002/02/05 00:36:27 taca Exp $ + +--- include/proto.h.orig Sun Feb 3 09:46:40 2002 ++++ include/proto.h +@@ -1813,6 +1813,7 @@ + char *lp_deleteprinter_cmd(void); + char *lp_os2_driver_map(void); + char *lp_lockdir(void); ++char *lp_piddir(void); + char *lp_utmpdir(void); + char *lp_wtmpdir(void); + BOOL lp_utmp(void); diff --git a/net/samba/patches/patch-an b/net/samba/patches/patch-an new file mode 100644 index 00000000000..9e03fd127d9 --- /dev/null +++ b/net/samba/patches/patch-an @@ -0,0 +1,22 @@ +$NetBSD: patch-an,v 1.1 2002/02/05 00:36:27 taca Exp $ + +--- lib/pidfile.c.orig Sun Feb 3 09:46:42 2002 ++++ lib/pidfile.c +@@ -37,7 +37,7 @@ + unsigned ret; + pstring pidFile; + +- slprintf(pidFile, sizeof(pidFile)-1, "%s/%s.pid", lp_lockdir(), name); ++ slprintf(pidFile, sizeof(pidFile)-1, "%s/%s.pid", lp_piddir(), name); + + fd = sys_open(pidFile, O_NONBLOCK | O_RDONLY, 0644); + if (fd == -1) { +@@ -78,7 +78,7 @@ + pstring pidFile; + pid_t pid; + +- slprintf(pidFile, sizeof(pidFile)-1, "%s/%s.pid", lp_lockdir(), name); ++ slprintf(pidFile, sizeof(pidFile)-1, "%s/%s.pid", lp_piddir(), name); + + pid = pidfile_pid(name); + if (pid != 0) { diff --git a/net/samba/patches/patch-ao b/net/samba/patches/patch-ao new file mode 100644 index 00000000000..b6fd0bfe9e7 --- /dev/null +++ b/net/samba/patches/patch-ao @@ -0,0 +1,37 @@ +$NetBSD: patch-ao,v 1.1 2002/02/05 00:36:27 taca Exp $ + +--- param/loadparm.c.orig Sun Feb 3 09:46:46 2002 ++++ param/loadparm.c +@@ -108,6 +108,7 @@ + char *szDeletePrinterCommand; + char *szOs2DriverMap; + char *szLockDir; ++ char *szPidDir; + char *szRootdir; + char *szDefaultService; + char *szDfree; +@@ -997,6 +998,8 @@ + {"auto services", P_STRING, P_GLOBAL, &Globals.szAutoServices, NULL, NULL, FLAG_DOS_STRING}, + {"lock dir", P_STRING, P_GLOBAL, &Globals.szLockDir, NULL, NULL, 0}, + {"lock directory", P_STRING, P_GLOBAL, &Globals.szLockDir, NULL, NULL, 0}, ++ {"pidfile dir", P_STRING, P_GLOBAL, &Globals.szPidDir, NULL, NULL, 0}, ++ {"pidfile directory", P_STRING, P_GLOBAL, &Globals.szPidDir, NULL, NULL, 0}, + #ifdef WITH_UTMP + {"utmp directory", P_STRING, P_GLOBAL, &Globals.szUtmpDir, NULL, NULL, 0}, + {"wtmp directory", P_STRING, P_GLOBAL, &Globals.szWtmpDir, NULL, NULL, 0}, +@@ -1231,6 +1234,7 @@ + string_set(&Globals.szPasswdProgram, PASSWD_PROGRAM); + string_set(&Globals.szPrintcapname, PRINTCAP_NAME); + string_set(&Globals.szLockDir, LOCKDIR); ++ string_set(&Globals.szPidDir, PIDFILEDIR); + #ifdef WITH_UTMP + string_set(&Globals.szUtmpDir, ""); + string_set(&Globals.szWtmpDir, ""); +@@ -1481,6 +1485,7 @@ + FN_GLOBAL_STRING(lp_deleteprinter_cmd, &Globals.szDeletePrinterCommand) + FN_GLOBAL_STRING(lp_os2_driver_map, &Globals.szOs2DriverMap) + FN_GLOBAL_STRING(lp_lockdir, &Globals.szLockDir) ++FN_GLOBAL_STRING(lp_piddir, &Globals.szPidDir) + #ifdef WITH_UTMP + FN_GLOBAL_STRING(lp_utmpdir, &Globals.szUtmpDir) + FN_GLOBAL_STRING(lp_wtmpdir, &Globals.szWtmpDir) |