svn commit: samba r18289 - in branches/SAMBA_4_0/source/lib/replace: .
Author: tridge Date: 2006-09-09 06:24:13 + (Sat, 09 Sep 2006) New Revision: 18289 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18289 Log: don't check for inline till we've worked out the main compiler flags Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 Changeset: Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 06:22:57 UTC (rev 18288) +++ branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 06:24:13 UTC (rev 18289) @@ -14,9 +14,9 @@ dnl needed before AC_TRY_COMPILE AC_ISC_POSIX AC_USE_SYSTEM_EXTENSIONS -AC_C_INLINE AC_PROG_CC_C99 AC_PROG_CC +AC_C_INLINE AC_PROG_INSTALL AH_VERBATIM([_XOPEN_SOURCE_EXTENDED],
svn commit: samba r18288 - in branches/SAMBA_4_0/source/lib/replace: .
Author: tridge Date: 2006-09-09 06:22:57 + (Sat, 09 Sep 2006) New Revision: 18288 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18288 Log: autoconf already has a C99 test builtin! If this works well, we can remove our own test Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 Changeset: Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 03:45:04 UTC (rev 18287) +++ branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 06:22:57 UTC (rev 18288) @@ -15,6 +15,7 @@ AC_ISC_POSIX AC_USE_SYSTEM_EXTENSIONS AC_C_INLINE +AC_PROG_CC_C99 AC_PROG_CC AC_PROG_INSTALL
svn commit: samba r18287 - in branches/SAMBA_4_0/source/lib/replace: .
Author: tridge Date: 2006-09-09 03:45:04 + (Sat, 09 Sep 2006) New Revision: 18287 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18287 Log: add support for the -qlanglvl=extc99 and -qlanglvl=stdc99 flags, needed on AIX 5.2 for C99 structures Modified: branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4 Changeset: Modified: branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4 2006-09-09 03:29:40 UTC (rev 18286) +++ branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4 2006-09-09 03:45:04 UTC (rev 18287) @@ -29,6 +29,24 @@ [AC_MSG_RESULT(yes); c99_init=yes],[AC_MSG_RESULT(no)]) fi if test x"$c99_init" = x"no"; then +AC_MSG_CHECKING(for C99 designated initializers with -qlanglvl=extc99) +CFLAGS="$saved_CFLAGS -qlanglvl=extc99"; +AC_TRY_COMPILE([#include ], + [ struct foo {int x;char y;}; + struct foo bar = { .y = 'X', .x = 1 }; + ], + [AC_MSG_RESULT(yes); c99_init=yes],[AC_MSG_RESULT(no)]) +fi +if test x"$c99_init" = x"no"; then +AC_MSG_CHECKING(for C99 designated initializers with -qlanglvl=stdc99) +CFLAGS="$saved_CFLAGS -qlanglvl=stdc99"; +AC_TRY_COMPILE([#include ], + [ struct foo {int x;char y;}; + struct foo bar = { .y = 'X', .x = 1 }; + ], + [AC_MSG_RESULT(yes); c99_init=yes],[AC_MSG_RESULT(no)]) +fi +if test x"$c99_init" = x"no"; then AC_MSG_CHECKING(for C99 designated initializers with -c99) CFLAGS="$saved_CFLAGS -c99" AC_TRY_COMPILE([#include ],
svn commit: samba r18286 - in branches/SAMBA_4_0/source/lib/ldb: .
Author: tridge Date: 2006-09-09 03:29:40 + (Sat, 09 Sep 2006) New Revision: 18286 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18286 Log: ldb now needs install-sh too Added: branches/SAMBA_4_0/source/lib/ldb/install-sh Changeset: Added: branches/SAMBA_4_0/source/lib/ldb/install-sh === --- branches/SAMBA_4_0/source/lib/ldb/install-sh2006-09-09 03:28:49 UTC (rev 18285) +++ branches/SAMBA_4_0/source/lib/ldb/install-sh2006-09-09 03:29:40 UTC (rev 18286) @@ -0,0 +1,238 @@ +#! /bin/sh +# +# install - install a program, script, or datafile +# This comes from X11R5. +# +# Calling this script install-sh is preferred over install.sh, to prevent +# `make' implicit rules from creating a file called install from it +# when there is no Makefile. +# +# This script is compatible with the BSD install script, but was written +# from scratch. +# + + +# set DOITPROG to echo to test this script + +# Don't use :- since 4.3BSD and earlier shells don't like it. +doit="${DOITPROG-}" + + +# put in absolute paths if you don't have them in your path; or use env. vars. + +mvprog="${MVPROG-mv}" +cpprog="${CPPROG-cp}" +chmodprog="${CHMODPROG-chmod}" +chownprog="${CHOWNPROG-chown}" +chgrpprog="${CHGRPPROG-chgrp}" +stripprog="${STRIPPROG-strip}" +rmprog="${RMPROG-rm}" +mkdirprog="${MKDIRPROG-mkdir}" + +transformbasename="" +transform_arg="" +instcmd="$mvprog" +chmodcmd="$chmodprog 0755" +chowncmd="" +chgrpcmd="" +stripcmd="" +rmcmd="$rmprog -f" +mvcmd="$mvprog" +src="" +dst="" +dir_arg="" + +while [ x"$1" != x ]; do +case $1 in + -c) instcmd="$cpprog" + shift + continue;; + + -d) dir_arg=true + shift + continue;; + + -m) chmodcmd="$chmodprog $2" + shift + shift + continue;; + + -o) chowncmd="$chownprog $2" + shift + shift + continue;; + + -g) chgrpcmd="$chgrpprog $2" + shift + shift + continue;; + + -s) stripcmd="$stripprog" + shift + continue;; + + -t=*) transformarg=`echo $1 | sed 's/-t=//'` + shift + continue;; + + -b=*) transformbasename=`echo $1 | sed 's/-b=//'` + shift + continue;; + + *) if [ x"$src" = x ] + then + src=$1 + else + # this colon is to work around a 386BSD /bin/sh bug + : + dst=$1 + fi + shift + continue;; +esac +done + +if [ x"$src" = x ] +then + echo "install: no input file specified" + exit 1 +else + true +fi + +if [ x"$dir_arg" != x ]; then + dst=$src + src="" + + if [ -d $dst ]; then + instcmd=: + else + instcmd=mkdir + fi +else + +# Waiting for this to be detected by the "$instcmd $src $dsttmp" command +# might cause directories to be created, which would be especially bad +# if $src (and thus $dsttmp) contains '*'. + + if [ -f $src -o -d $src ] + then + true + else + echo "install: $src does not exist" + exit 1 + fi + + if [ x"$dst" = x ] + then + echo "install: no destination specified" + exit 1 + else + true + fi + +# If destination is a directory, append the input filename; if your system +# does not like double slashes in filenames, you may need to add some logic + + if [ -d $dst ] + then + dst="$dst"/`basename $src` + else + true + fi +fi + +## this sed command emulates the dirname command +dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` + +# Make sure that the destination directory exists. +# this part is taken from Noah Friedman's mkinstalldirs script + +# Skip lots of stat calls in the usual case. +if [ ! -d "$dstdir" ]; then +defaultIFS=' +' +IFS="${IFS-${defaultIFS}}" + +oIFS="${IFS}" +# Some sh's can't handle IFS=/ for some reason. +IFS='%' +set - `echo ${dstdir} | sed -e 's@/@[EMAIL PROTECTED]' -e '[EMAIL PROTECTED]@/@'` +IFS="${oIFS}" + +pathcomp='' + +while [ $# -ne 0 ] ; do + pathcomp="${pathcomp}${1}" + shift + + if [ ! -d "${pathcomp}" ] ; +then + $mkdirprog "${pathcomp}" + else + true + fi + + pathcomp="${pathcomp}/" +done +fi + +if [ x"$dir_arg" != x ] +then + $doit $instcmd $dst && + + if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && + if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && + if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && + if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi +else + +# If we're going to rename the final executable, determi
svn commit: samba r18285 - in branches/SAMBA_4_0/source/lib/tdb: .
Author: tridge Date: 2006-09-09 03:28:49 + (Sat, 09 Sep 2006) New Revision: 18285 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18285 Log: tdb now needs install-sh Added: branches/SAMBA_4_0/source/lib/tdb/install-sh Changeset: Added: branches/SAMBA_4_0/source/lib/tdb/install-sh === --- branches/SAMBA_4_0/source/lib/tdb/install-sh2006-09-09 03:16:05 UTC (rev 18284) +++ branches/SAMBA_4_0/source/lib/tdb/install-sh2006-09-09 03:28:49 UTC (rev 18285) @@ -0,0 +1,238 @@ +#! /bin/sh +# +# install - install a program, script, or datafile +# This comes from X11R5. +# +# Calling this script install-sh is preferred over install.sh, to prevent +# `make' implicit rules from creating a file called install from it +# when there is no Makefile. +# +# This script is compatible with the BSD install script, but was written +# from scratch. +# + + +# set DOITPROG to echo to test this script + +# Don't use :- since 4.3BSD and earlier shells don't like it. +doit="${DOITPROG-}" + + +# put in absolute paths if you don't have them in your path; or use env. vars. + +mvprog="${MVPROG-mv}" +cpprog="${CPPROG-cp}" +chmodprog="${CHMODPROG-chmod}" +chownprog="${CHOWNPROG-chown}" +chgrpprog="${CHGRPPROG-chgrp}" +stripprog="${STRIPPROG-strip}" +rmprog="${RMPROG-rm}" +mkdirprog="${MKDIRPROG-mkdir}" + +transformbasename="" +transform_arg="" +instcmd="$mvprog" +chmodcmd="$chmodprog 0755" +chowncmd="" +chgrpcmd="" +stripcmd="" +rmcmd="$rmprog -f" +mvcmd="$mvprog" +src="" +dst="" +dir_arg="" + +while [ x"$1" != x ]; do +case $1 in + -c) instcmd="$cpprog" + shift + continue;; + + -d) dir_arg=true + shift + continue;; + + -m) chmodcmd="$chmodprog $2" + shift + shift + continue;; + + -o) chowncmd="$chownprog $2" + shift + shift + continue;; + + -g) chgrpcmd="$chgrpprog $2" + shift + shift + continue;; + + -s) stripcmd="$stripprog" + shift + continue;; + + -t=*) transformarg=`echo $1 | sed 's/-t=//'` + shift + continue;; + + -b=*) transformbasename=`echo $1 | sed 's/-b=//'` + shift + continue;; + + *) if [ x"$src" = x ] + then + src=$1 + else + # this colon is to work around a 386BSD /bin/sh bug + : + dst=$1 + fi + shift + continue;; +esac +done + +if [ x"$src" = x ] +then + echo "install: no input file specified" + exit 1 +else + true +fi + +if [ x"$dir_arg" != x ]; then + dst=$src + src="" + + if [ -d $dst ]; then + instcmd=: + else + instcmd=mkdir + fi +else + +# Waiting for this to be detected by the "$instcmd $src $dsttmp" command +# might cause directories to be created, which would be especially bad +# if $src (and thus $dsttmp) contains '*'. + + if [ -f $src -o -d $src ] + then + true + else + echo "install: $src does not exist" + exit 1 + fi + + if [ x"$dst" = x ] + then + echo "install: no destination specified" + exit 1 + else + true + fi + +# If destination is a directory, append the input filename; if your system +# does not like double slashes in filenames, you may need to add some logic + + if [ -d $dst ] + then + dst="$dst"/`basename $src` + else + true + fi +fi + +## this sed command emulates the dirname command +dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` + +# Make sure that the destination directory exists. +# this part is taken from Noah Friedman's mkinstalldirs script + +# Skip lots of stat calls in the usual case. +if [ ! -d "$dstdir" ]; then +defaultIFS=' +' +IFS="${IFS-${defaultIFS}}" + +oIFS="${IFS}" +# Some sh's can't handle IFS=/ for some reason. +IFS='%' +set - `echo ${dstdir} | sed -e 's@/@[EMAIL PROTECTED]' -e '[EMAIL PROTECTED]@/@'` +IFS="${oIFS}" + +pathcomp='' + +while [ $# -ne 0 ] ; do + pathcomp="${pathcomp}${1}" + shift + + if [ ! -d "${pathcomp}" ] ; +then + $mkdirprog "${pathcomp}" + else + true + fi + + pathcomp="${pathcomp}/" +done +fi + +if [ x"$dir_arg" != x ] +then + $doit $instcmd $dst && + + if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && + if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && + if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && + if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi +else + +# If we're going to rename the final executable, determine t
svn commit: samba r18284 - in branches/SAMBA_4_0/source/lib/replace: .
Author: tridge Date: 2006-09-09 03:16:05 + (Sat, 09 Sep 2006) New Revision: 18284 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18284 Log: enable _XOPEN_SOURCE_EXTENDED to fix a HP-UX bug with the definition of sendfile() Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 Changeset: Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 02:52:41 UTC (rev 18283) +++ branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 03:16:05 UTC (rev 18284) @@ -18,6 +18,12 @@ AC_PROG_CC AC_PROG_INSTALL +AH_VERBATIM([_XOPEN_SOURCE_EXTENDED], +[/* Enable XOPEN extensions on systems that have them. */ +#ifndef _XOPEN_SOURCE_EXTENDED +# define _XOPEN_SOURCE_EXTENDED 1 +#endif]) + LIBREPLACE_C99_STRUCT_INIT([],[]) AC_SYS_LARGEFILE
svn commit: samba r18283 - in branches/SAMBA_4_0/source/lib: ldb replace talloc
Author: tridge Date: 2006-09-09 02:52:41 + (Sat, 09 Sep 2006) New Revision: 18283 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18283 Log: libreplace.m4 needs to be early in configure.ac in other packages too Modified: branches/SAMBA_4_0/source/lib/ldb/configure.ac branches/SAMBA_4_0/source/lib/replace/configure.ac branches/SAMBA_4_0/source/lib/replace/libreplace.m4 branches/SAMBA_4_0/source/lib/talloc/configure.ac Changeset: Modified: branches/SAMBA_4_0/source/lib/ldb/configure.ac === --- branches/SAMBA_4_0/source/lib/ldb/configure.ac 2006-09-09 02:35:38 UTC (rev 18282) +++ branches/SAMBA_4_0/source/lib/ldb/configure.ac 2006-09-09 02:52:41 UTC (rev 18283) @@ -13,7 +13,7 @@ AC_DEFUN([SMB_ENABLE], [echo -n ""]) AC_INIT(include/ldb.h) AC_CONFIG_SRCDIR([common/ldb.c]) -AC_PROG_CC +m4_include(libreplace.m4) if test "$ac_cv_prog_gcc" = yes; then CFLAGS="$CFLAGS -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings" @@ -29,8 +29,6 @@ LIBS="$LIBS -lgcov" fi -AC_SYS_LARGEFILE -AC_FUNC_MMAP AC_PATH_PROG(XSLTPROC,xsltproc) AC_PATH_PROG(DOXYGEN,doxygen) AC_PATH_PROG(GCOV,gcov) @@ -48,7 +46,6 @@ TESTS="" EXTRA_OBJ="" -m4_include(libreplace.m4) m4_include(libpopt.m4) m4_include(libtalloc.m4) m4_include(libtdb.m4) Modified: branches/SAMBA_4_0/source/lib/replace/configure.ac === --- branches/SAMBA_4_0/source/lib/replace/configure.ac 2006-09-09 02:35:38 UTC (rev 18282) +++ branches/SAMBA_4_0/source/lib/replace/configure.ac 2006-09-09 02:52:41 UTC (rev 18283) @@ -5,8 +5,6 @@ AC_INIT(dlfcn.c) AC_CONFIG_SRCDIR([dlfcn.c]) AC_CONFIG_HEADER(config.h) -AC_PROG_INSTALL -AC_PROG_CC if test "$ac_cv_prog_gcc" = yes; then CFLAGS="$CFLAGS -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings" Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 02:35:38 UTC (rev 18282) +++ branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 02:52:41 UTC (rev 18283) @@ -16,6 +16,7 @@ AC_USE_SYSTEM_EXTENSIONS AC_C_INLINE AC_PROG_CC +AC_PROG_INSTALL LIBREPLACE_C99_STRUCT_INIT([],[]) @@ -30,6 +31,7 @@ AC_C_BIGENDIAN AC_HEADER_STDC + AC_CHECK_SIZEOF(off_t,cross) AC_CHECK_SIZEOF(size_t,cross) AC_CHECK_SIZEOF(ssize_t,cross) Modified: branches/SAMBA_4_0/source/lib/talloc/configure.ac === --- branches/SAMBA_4_0/source/lib/talloc/configure.ac 2006-09-09 02:35:38 UTC (rev 18282) +++ branches/SAMBA_4_0/source/lib/talloc/configure.ac 2006-09-09 02:52:41 UTC (rev 18283) @@ -2,21 +2,16 @@ AC_INIT(talloc.h) AC_CONFIG_SRCDIR([talloc.c]) AC_SUBST(datarootdir) -AC_PROG_CC -if test "x$GCC" = "xyes"; then - CFLAGS="$CFLAGS -Wall -W" -fi -AC_PROG_INSTALL +AC_CONFIG_HEADER(config.h) + +m4_include(libreplace.m4) +m4_include(libtalloc.m4) + AC_PATH_PROG(XSLTPROC,xsltproc) DOC_TARGET="" if test -n "$XSLTPROC"; then DOC_TARGET=doc fi AC_SUBST(DOC_TARGET) -AC_CONFIG_HEADER(config.h) -AC_SYS_LARGEFILE -m4_include(libreplace.m4) -m4_include(libtalloc.m4) - AC_OUTPUT(Makefile talloc.pc)
svn commit: samba r18282 - in branches/SAMBA_4_0/source: .
Author: tridge Date: 2006-09-09 02:35:38 + (Sat, 09 Sep 2006) New Revision: 18282 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18282 Log: dynconfig.o build rule needs cflags.pl too Modified: branches/SAMBA_4_0/source/dynconfig.mk Changeset: Modified: branches/SAMBA_4_0/source/dynconfig.mk === --- branches/SAMBA_4_0/source/dynconfig.mk 2006-09-09 02:32:12 UTC (rev 18281) +++ branches/SAMBA_4_0/source/dynconfig.mk 2006-09-09 02:35:38 UTC (rev 18282) @@ -14,7 +14,7 @@ ./dynconfig.o: dynconfig.c Makefile @echo Compiling $< - @$(CC) $(CFLAGS) $(PICFLAG) $(PATH_FLAGS) -c $< -o $@ + @$(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) $(PATH_FLAGS) -c $< -o $@ # dynconfig defines used for binaries in bin/, when configure ran in developer # mode:
svn commit: samba r18281 - in branches/SAMBA_4_0/source: lib/smbreadline script
Author: tridge Date: 2006-09-09 02:32:12 + (Sat, 09 Sep 2006) New Revision: 18281 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18281 Log: a workaround for an infinite dependency loop in the dependency generation for smbreadline.d. The problem was caused by extra_flags.txt having ./lib/smbreadline/smbreadline.o but the build using lib/smbreadline/smbreadline.o, which means cflags.pl didn't match the target. Hopefully the workaround can be removed when metze or jelmer wake up and give me a hint on how to make SMB_SUBSYSTEM() not add the ./ prefix :-) Modified: branches/SAMBA_4_0/source/lib/smbreadline/smbreadline.c branches/SAMBA_4_0/source/script/cflags.pl Changeset: Modified: branches/SAMBA_4_0/source/lib/smbreadline/smbreadline.c === --- branches/SAMBA_4_0/source/lib/smbreadline/smbreadline.c 2006-09-09 02:12:09 UTC (rev 18280) +++ branches/SAMBA_4_0/source/lib/smbreadline/smbreadline.c 2006-09-09 02:32:12 UTC (rev 18281) @@ -21,9 +21,9 @@ #include "includes.h" #include "pstring.h" -#include "lib/replace/system/filesys.h" -#include "lib/replace/system/select.h" -#include "lib/replace/system/readline.h" +#include "system/filesys.h" +#include "system/select.h" +#include "system/readline.h" /*** Similar to sys_select() but catch EINTR and continue. Modified: branches/SAMBA_4_0/source/script/cflags.pl === --- branches/SAMBA_4_0/source/script/cflags.pl 2006-09-09 02:12:09 UTC (rev 18280) +++ branches/SAMBA_4_0/source/script/cflags.pl 2006-09-09 02:32:12 UTC (rev 18281) @@ -7,13 +7,15 @@ use strict; my $target = shift; +my $target2 = "./$target"; sub check_flags($) { my ($name)[EMAIL PROTECTED]; open (IN, "extra_cflags.txt"); while ( =~ /^([^:]+): (.*)$/) { - next unless (grep(/^$target$/, (split / /, $1))); + next unless (grep(/^$target$/, (split / /, $1)) || +grep(/^$target2$/, (split / /, $1))); $_ = $2; s/^CFLAGS\+=//; print "$_ ";
svn commit: samba r18280 - in branches/SAMBA_4_0/source: lib/replace lib/tdb libcli rpc_server/unixinfo
Author: tridge Date: 2006-09-09 02:12:09 + (Sat, 09 Sep 2006) New Revision: 18280 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18280 Log: more portability tidyups, ensuring we use libreplace everywhere Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 branches/SAMBA_4_0/source/lib/tdb/configure.ac branches/SAMBA_4_0/source/libcli/libcli.h branches/SAMBA_4_0/source/rpc_server/unixinfo/dcesrv_unixinfo.c Changeset: Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 02:06:01 UTC (rev 18279) +++ branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 02:12:09 UTC (rev 18280) @@ -1,11 +1,3 @@ -dnl needed before AC_TRY_COMPILE -AC_ISC_POSIX -AC_USE_SYSTEM_EXTENSIONS - -AC_C_INLINE - -LIBREPLACE_C99_STRUCT_INIT([],[]) - dnl find the libreplace sources. This is meant to work both for dnl libreplace standalone builds, and builds of packages using libreplace libreplacedir="" @@ -19,6 +11,14 @@ LIBREPLACEOBJ="dlfcn.o getpass.o replace.o snprintf.o timegm.o" AC_SUBST(LIBREPLACEOBJ) +dnl needed before AC_TRY_COMPILE +AC_ISC_POSIX +AC_USE_SYSTEM_EXTENSIONS +AC_C_INLINE +AC_PROG_CC + +LIBREPLACE_C99_STRUCT_INIT([],[]) + AC_SYS_LARGEFILE dnl Add #include for broken IRIX header files @@ -30,6 +30,10 @@ AC_C_BIGENDIAN AC_HEADER_STDC +AC_CHECK_SIZEOF(off_t,cross) +AC_CHECK_SIZEOF(size_t,cross) +AC_CHECK_SIZEOF(ssize_t,cross) +AC_FUNC_MMAP AC_CHECK_HEADERS([stdint.h inttypes.h]) AC_CHECK_TYPE(uint_t, unsigned int) Modified: branches/SAMBA_4_0/source/lib/tdb/configure.ac === --- branches/SAMBA_4_0/source/lib/tdb/configure.ac 2006-09-09 02:06:01 UTC (rev 18279) +++ branches/SAMBA_4_0/source/lib/tdb/configure.ac 2006-09-09 02:12:09 UTC (rev 18280) @@ -5,12 +5,6 @@ AC_INIT(include/tdb.h) AC_CONFIG_SRCDIR([common/tdb.c]) AC_CONFIG_HEADER(include/config.h) -AC_PROG_CC -AC_SYS_LARGEFILE -AC_CHECK_SIZEOF(off_t,cross) -AC_CHECK_SIZEOF(size_t,cross) -AC_CHECK_SIZEOF(ssize_t,cross) -AC_FUNC_MMAP m4_include(libreplace.m4) m4_include(libtdb.m4) AC_OUTPUT(Makefile tdb.pc) Modified: branches/SAMBA_4_0/source/libcli/libcli.h === --- branches/SAMBA_4_0/source/libcli/libcli.h 2006-09-09 02:06:01 UTC (rev 18279) +++ branches/SAMBA_4_0/source/libcli/libcli.h 2006-09-09 02:12:09 UTC (rev 18280) @@ -22,7 +22,7 @@ #ifndef __LIBCLI_H__ #define __LIBCLI_H__ -#include +#include "core.h" #include "librpc/gen_ndr/nbt.h" /* Modified: branches/SAMBA_4_0/source/rpc_server/unixinfo/dcesrv_unixinfo.c === --- branches/SAMBA_4_0/source/rpc_server/unixinfo/dcesrv_unixinfo.c 2006-09-09 02:06:01 UTC (rev 18279) +++ branches/SAMBA_4_0/source/rpc_server/unixinfo/dcesrv_unixinfo.c 2006-09-09 02:12:09 UTC (rev 18280) @@ -26,10 +26,8 @@ #include "librpc/gen_ndr/ndr_unixinfo.h" #include "lib/events/events.h" #include "dsdb/samdb/samdb.h" +#include "system/passwd.h" -#include -#include - static NTSTATUS unixinfo_SidToUid(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, struct unixinfo_SidToUid *r)
svn commit: samba r18279 - in branches/SAMBA_4_0/source: .
Author: tridge Date: 2006-09-09 02:06:01 + (Sat, 09 Sep 2006) New Revision: 18279 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18279 Log: libreplace.m4 needs to come first or autoconf complains, as libreplace checks for global system flags Modified: branches/SAMBA_4_0/source/configure.ac Changeset: Modified: branches/SAMBA_4_0/source/configure.ac === --- branches/SAMBA_4_0/source/configure.ac 2006-09-09 01:49:38 UTC (rev 18278) +++ branches/SAMBA_4_0/source/configure.ac 2006-09-09 02:06:01 UTC (rev 18279) @@ -10,8 +10,8 @@ AC_CONFIG_HEADER(include/config_tmp.h) # Configuration rules. +m4_include(lib/replace/libreplace.m4) m4_include(build/m4/env.m4) -m4_include(lib/replace/libreplace.m4) SMB_EXT_LIB(DL, $LIBDL) m4_include(lib/replace/win32/config.m4) m4_include(lib/replace/repdir/config.m4)
svn commit: samba r18278 - in branches/SAMBA_4_0/source: include lib/replace
Author: tridge Date: 2006-09-09 01:49:38 + (Sat, 09 Sep 2006) New Revision: 18278 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18278 Log: move more header checks and _GNU_SOURCE into libreplace Modified: branches/SAMBA_4_0/source/include/includes.h branches/SAMBA_4_0/source/lib/replace/libreplace.m4 branches/SAMBA_4_0/source/lib/replace/replace.h Changeset: Modified: branches/SAMBA_4_0/source/include/includes.h === --- branches/SAMBA_4_0/source/include/includes.h2006-09-09 01:21:10 UTC (rev 18277) +++ branches/SAMBA_4_0/source/include/includes.h2006-09-09 01:49:38 UTC (rev 18278) @@ -64,25 +64,13 @@ #endif #endif -#define _GNU_SOURCE /* Use GNU extensions */ - /* mark smb_panic() as noreturn, so static analysers know that it is used like abort */ _PUBLIC_ void smb_panic(const char *why) NORETURN_ATTRIBUTE; -#include -#include -#include -#include -#include +#include "system/time.h" +#include "system/wait.h" -#ifdef HAVE_STRING_H -#include -#endif - -#include -#include - #define _PRINTF_ATTRIBUTE(a1, a2) PRINTF_ATTRIBUTE(a1, a2) /* Lists, trees, caching, database... */ Modified: branches/SAMBA_4_0/source/lib/replace/libreplace.m4 === --- branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 01:21:10 UTC (rev 18277) +++ branches/SAMBA_4_0/source/lib/replace/libreplace.m4 2006-09-09 01:49:38 UTC (rev 18278) @@ -1,5 +1,6 @@ dnl needed before AC_TRY_COMPILE AC_ISC_POSIX +AC_USE_SYSTEM_EXTENSIONS AC_C_INLINE @@ -57,7 +58,7 @@ AC_CHECK_FUNCS(pipe strftime srandom random srand rand usleep setbuffer) -AC_CHECK_HEADERS(stdbool.h) +AC_CHECK_HEADERS(stdbool.h stddef.h) AC_CHECK_TYPE(bool, [AC_DEFINE(HAVE_BOOL, 1, [Whether the bool type is available])],, Modified: branches/SAMBA_4_0/source/lib/replace/replace.h === --- branches/SAMBA_4_0/source/lib/replace/replace.h 2006-09-09 01:21:10 UTC (rev 18277) +++ branches/SAMBA_4_0/source/lib/replace/replace.h 2006-09-09 01:49:38 UTC (rev 18278) @@ -61,6 +61,14 @@ #include #endif +#ifdef HAVE_SYS_TYPES_H +#include +#endif + +#ifdef HAVE_STDDEF_H +#include +#endif + #ifndef HAVE_STRERROR extern char *sys_errlist[]; #define strerror(i) sys_errlist[i]
svn commit: samba r18277 - in branches/SAMBA_4_0/source/script/tests: .
Author: tridge Date: 2006-09-09 01:21:10 + (Sat, 09 Sep 2006) New Revision: 18277 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18277 Log: on some of our slower hosts we need more than 2700 seconds for smbd to complete all tests Modified: branches/SAMBA_4_0/source/script/tests/test_functions.sh Changeset: Modified: branches/SAMBA_4_0/source/script/tests/test_functions.sh === --- branches/SAMBA_4_0/source/script/tests/test_functions.sh2006-09-08 21:10:14 UTC (rev 18276) +++ branches/SAMBA_4_0/source/script/tests/test_functions.sh2006-09-09 01:21:10 UTC (rev 18277) @@ -21,7 +21,7 @@ echo -n "STARTING SMBD..." (( if [ -z "$SMBD_MAXTIME" ]; then - SMBD_MAXTIME=2700 + SMBD_MAXTIME=5400 fi $SMBD_VALGRIND $SRCDIR/bin/smbd --maximum-runtime=$SMBD_MAXTIME -d1 -s $CONFFILE -M single -i --leak-report-full < $SMBD_TEST_FIFO > $SMBD_TEST_LOG 2>&1; ret=$?;
Build status as of Sat Sep 9 00:00:02 2006
URL: http://build.samba.org/ --- /home/build/master/cache/broken_results.txt.old 2006-09-08 00:00:05.0 + +++ /home/build/master/cache/broken_results.txt 2006-09-09 00:00:21.0 + @@ -1,4 +1,4 @@ -Build status as of Fri Sep 8 00:00:02 2006 +Build status as of Sat Sep 9 00:00:02 2006 Build counts: Tree Total Broken Panic @@ -6,16 +6,16 @@ build_farm 0 0 0 ccache 42 9 0 distcc 42 7 0 -ldb 38 9 0 -libreplace 36 2 0 +ldb 38 8 0 +libreplace 37 3 0 lorikeet-heimdal 3 1 0 ppp 19 0 0 rsync40 5 0 samba1 0 0 samba-docs 0 0 0 -samba4 44 29 7 -samba_3_043 17 1 -smb-build31 3 0 +samba4 44 25 7 +samba_3_043 17 0 +smb-build30 3 0 talloc 42 4 0 tdb 39 7 0
svn commit: samba r18276 - in branches/SAMBA_3_0_23/source/nsswitch: .
Author: idra Date: 2006-09-08 21:10:14 + (Fri, 08 Sep 2006) New Revision: 18276 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18276 Log: merge uid2sid and gid2sid async calls for SAMBA_3_0 Modified: branches/SAMBA_3_0_23/source/nsswitch/winbindd_async.c branches/SAMBA_3_0_23/source/nsswitch/winbindd_dual.c branches/SAMBA_3_0_23/source/nsswitch/winbindd_group.c branches/SAMBA_3_0_23/source/nsswitch/winbindd_nss.h branches/SAMBA_3_0_23/source/nsswitch/winbindd_sid.c branches/SAMBA_3_0_23/source/nsswitch/winbindd_user.c Changeset: Modified: branches/SAMBA_3_0_23/source/nsswitch/winbindd_async.c === --- branches/SAMBA_3_0_23/source/nsswitch/winbindd_async.c 2006-09-08 17:21:15 UTC (rev 18275) +++ branches/SAMBA_3_0_23/source/nsswitch/winbindd_async.c 2006-09-08 21:10:14 UTC (rev 18276) @@ -1469,3 +1469,119 @@ do_async_domain(mem_ctx, domain, &request, query_user_recv, cont, private_data); } + +/* The following uid2sid/gid2sid functions has been contributed by + * Keith Reynolds <[EMAIL PROTECTED]> */ + +static void winbindd_uid2sid_recv(TALLOC_CTX *mem_ctx, BOOL success, + struct winbindd_response *response, + void *c, void *private_data) +{ + void (*cont)(void *priv, BOOL succ, const char *sid) = c; + + if (!success) { + DEBUG(5, ("Could not trigger uid2sid\n")); + cont(private_data, False, NULL); + return; + } + + if (response->result != WINBINDD_OK) { + DEBUG(5, ("uid2sid returned an error\n")); + cont(private_data, False, NULL); + return; + } + + cont(private_data, True, response->data.sid.sid); +} + +void winbindd_uid2sid_async(TALLOC_CTX *mem_ctx, uid_t uid, + void (*cont)(void *private_data, BOOL success, const char *sid), + void *private_data) +{ + struct winbindd_request request; + + ZERO_STRUCT(request); + request.cmd = WINBINDD_DUAL_UID2SID; + request.data.uid = uid; + do_async(mem_ctx, idmap_child(), &request, winbindd_uid2sid_recv, cont, private_data); +} + +enum winbindd_result winbindd_dual_uid2sid(struct winbindd_domain *domain, + struct winbindd_cli_state *state) +{ + DOM_SID sid; + NTSTATUS result; + + DEBUG(3,("[%5lu]: uid to sid %lu\n", +(unsigned long)state->pid, +(unsigned long) state->request.data.uid)); + + /* Find sid for this uid and return it, possibly ask the slow remote idmap */ + result = idmap_uid_to_sid(&sid, state->request.data.uid, ID_EMPTY); + + if (NT_STATUS_IS_OK(result)) { + sid_to_string(state->response.data.sid.sid, &sid); + state->response.data.sid.type = SID_NAME_USER; + return WINBINDD_OK; + } + + return WINBINDD_ERROR; +} + +static void winbindd_gid2sid_recv(TALLOC_CTX *mem_ctx, BOOL success, + struct winbindd_response *response, + void *c, void *private_data) +{ + void (*cont)(void *priv, BOOL succ, const char *sid) = c; + + if (!success) { + DEBUG(5, ("Could not trigger gid2sid\n")); + cont(private_data, False, NULL); + return; + } + + if (response->result != WINBINDD_OK) { + DEBUG(5, ("gid2sid returned an error\n")); + cont(private_data, False, NULL); + return; + } + + cont(private_data, True, response->data.sid.sid); +} + +void winbindd_gid2sid_async(TALLOC_CTX *mem_ctx, gid_t gid, + void (*cont)(void *private_data, BOOL success, const char *sid), + void *private_data) +{ + struct winbindd_request request; + + ZERO_STRUCT(request); + request.cmd = WINBINDD_DUAL_GID2SID; + request.data.gid = gid; + do_async(mem_ctx, idmap_child(), &request, winbindd_gid2sid_recv, cont, private_data); +} + +enum winbindd_result winbindd_dual_gid2sid(struct winbindd_domain *domain, + struct winbindd_cli_state *state) +{ + DOM_SID sid; + NTSTATUS result; + + DEBUG(3,("[%5lu]: gid %lu to sid\n", + (unsigned long)state->pid, + (unsigned long) state->request.data.gid)); + + /* Find sid for this gid and return it, possibly ask the slow remote idmap */ + result = idmap_gid_to_sid(&sid, state->request.data.gid, ID_EMPTY); + + if (NT_STATUS_IS_OK(result)) { + sid_to_string(state->response.data.sid.sid, &sid); + DEBUG(10, ("[%5lu]: retrieved sid: %s\n", + (unsigned long)state->pid, +
Rev 9140: Convert some more tests to use the new UI API. in file:///home/jelmer/bzr.samba/4.0-unittest/
revno: 9140 committer: Jelmer Vernooij <[EMAIL PROTECTED]> branch nick: unittest timestamp: Fri 2006-09-08 19:45:09 +0200 message: Convert some more tests to use the new UI API. removed: source/torture/nbt/browse.c modified: source/torture/config.mk source/torture/nbt/dgram.c source/torture/nbt/nbt.c source/torture/nbt/query.c source/torture/nbt/register.c
svn commit: samba r18275 - in branches/SAMBA_3_0/source: . include librpc/gen_ndr
Author: jerry Date: 2006-09-08 17:21:15 + (Fri, 08 Sep 2006) New Revision: 18275 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18275 Log: add auto generated dfs code Added: branches/SAMBA_3_0/source/librpc/gen_ndr/cli_dfs.c branches/SAMBA_3_0/source/librpc/gen_ndr/cli_dfs.h branches/SAMBA_3_0/source/librpc/gen_ndr/dfs.h branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_dfs.c branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_dfs.h Modified: branches/SAMBA_3_0/source/Makefile.in branches/SAMBA_3_0/source/include/smb.h Changeset: Sorry, the patch is too large (4612 lines) to include; please use WebSVN to see it! WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18275
svn commit: samba r18274 - in branches/SAMBA_3_0/source/librpc: gen_ndr ndr
Author: jerry Date: 2006-09-08 15:22:38 + (Fri, 08 Sep 2006) New Revision: 18274 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18274 Log: Cleanup unnecessary empty headers and add a comment why the remaining ones are needed Removed: branches/SAMBA_3_0/source/librpc/ndr/ndr_dcerpc.h branches/SAMBA_3_0/source/librpc/ndr/ndr_misc.h branches/SAMBA_3_0/source/librpc/ndr/ndr_security.h Modified: branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_dcerpc.h branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_security.h Changeset: Modified: branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_dcerpc.h === --- branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_dcerpc.h 2006-09-08 14:48:40 UTC (rev 18273) +++ branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_dcerpc.h 2006-09-08 15:22:38 UTC (rev 18274) @@ -0,0 +1,2 @@ +/* empty header to deal with pidl */ + Modified: branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_security.h === --- branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_security.h 2006-09-08 14:48:40 UTC (rev 18273) +++ branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_security.h 2006-09-08 15:22:38 UTC (rev 18274) @@ -0,0 +1,2 @@ +/* empty header to deal with pidl */ + Deleted: branches/SAMBA_3_0/source/librpc/ndr/ndr_dcerpc.h === Deleted: branches/SAMBA_3_0/source/librpc/ndr/ndr_misc.h === Deleted: branches/SAMBA_3_0/source/librpc/ndr/ndr_security.h ===
Rev 9139: [merge] upstream 4.0 in file:///home/jelmer/bzr.samba/4.0-unittest/
revno: 9139 committer: Jelmer Vernooij <[EMAIL PROTECTED]> branch nick: unittest timestamp: Fri 2006-09-08 16:50:43 +0200 message: [merge] upstream 4.0 modified: source/auth/gensec/cyrus_sasl.c source/auth/gensec/gensec.c source/auth/gensec/gensec.h source/auth/gensec/gensec_gssapi.c source/auth/gensec/gensec_krb5.c source/auth/gensec/schannel.c source/auth/gensec/spnego.c source/auth/ntlmssp/ntlmssp.c source/build/m4/check_cc.m4 source/build/m4/check_ld.m4 source/build/smb_build/input.pm source/dsdb/samdb/ldb_modules/entryUUID.c source/dsdb/samdb/ldb_modules/password_hash.c source/lib/ldb/common/ldb.c source/lib/ldb/tests/init_slapd.sh source/libcli/composite/composite.c source/libcli/ldap/ldap_client.c source/main.mk source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm source/rpc_server/samr/dcesrv_samr.c source/script/tests/mktestsetup.sh source/script/tests/selftest.sh source/script/tests/test_cifsdd.sh source/script/tests/test_pidl.sh source/scripting/libjs/provision.js merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 13:55:13 + message: print out the failing command for .ho files too metze merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 13:47:45 + message: we should bail out in configure if C99 structs are not support tridge: I think we should create macros in libreplace_macros.m4 and call them in check_cc.m4 instead of running the tests in libreplace.m4. Maybe the macros should remember if they're called and then they're skipped in libreplace.m4 inside samba4 metze merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 13:37:22 + message: print out the failling command metze merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 13:11:03 + message: print the full list of flags metze merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 12:48:51 + message: fix typos metze merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 12:28:11 + message: print out the version of gcc metze merged: svn-v1:[EMAIL PROTECTED] committer: metze timestamp: Fri 2006-09-08 11:42:47 + message: fix the build on systems with broken readdir this is just a short term hack we should move the stuff from lib/replace/config.mk into a lib/replace/samba.m4 and dynamicly generate the OBJ_FILES list for LIBREPLACE and get rid of REPLACE_REPDIR metze merged: svn-v1:[EMAIL PROTECTED] committer: tridge timestamp: Fri 2006-09-08 06:57:01 + message: need to use .priority not .order here merged: svn-v1:[EMAIL PROTECTED] committer: abartlet timestamp: Fri 2006-09-08 06:21:02 + message: Order the GENSEC modules, with unknown modules last. Andrew Bartlett merged: svn-v1:[EMAIL PROTECTED] committer: tridge timestamp: Fri 2006-09-08 06:04:10 + message: use the right status variable merged: svn-v1:[EMAIL PROTECTED] committer: abartlet timestamp: Fri 2006-09-08 05:45:23 + message: Remove the SMB_ASSERT(), as these are not talloc()'ed structures. Andrew Bartlett merged: svn-v1:[EMAIL PROTECTED] committer: tridge timestamp: Fri 2006-09-08 05:43:08 + message: reverted r18231 Jelmer, older versions of gcc don't support visibility("default"). See for example the CentOS build here: http://build.samba.org/?function=View+Build;host=lithium;tree=samba4;compiler=gcc;revision=18253 Is there some other way you can think of to do this? merged: svn-v1:[EMAIL PROTECTED] committer: abartlet timestamp: Fri 200
svn commit: samba r18273 - in branches/SAMBA_4_0/source/build/m4: .
Author: metze Date: 2006-09-08 14:48:40 + (Fri, 08 Sep 2006) New Revision: 18273 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18273 Log: AC_PROG_LD_GNU needs LD defined already metze Modified: branches/SAMBA_4_0/source/build/m4/check_ld.m4 Changeset: Modified: branches/SAMBA_4_0/source/build/m4/check_ld.m4 === --- branches/SAMBA_4_0/source/build/m4/check_ld.m4 2006-09-08 14:32:36 UTC (rev 18272) +++ branches/SAMBA_4_0/source/build/m4/check_ld.m4 2006-09-08 14:48:40 UTC (rev 18273) @@ -7,7 +7,9 @@ dnl AC_PATH_PROG(PROG_LD,ld) +LD=${PROG_LD} AC_PROG_LD_GNU +LD="" AC_PATH_PROG(PROG_AR, ar) AC_SUBST(STLD)
svn commit: samba r18272 - in branches/SAMBA_4_0/source/lib/ldb/common: .
Author: idra Date: 2006-09-08 14:32:36 + (Fri, 08 Sep 2006) New Revision: 18272 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18272 Log: Couldn't resist to change this. What we want to do here is to just make sure res is freed. Well let's just do so explicitly, the steal cofused me initially while reading the code. This way it is clear what we want to do. Simo. Modified: branches/SAMBA_4_0/source/lib/ldb/common/ldb.c Changeset: Modified: branches/SAMBA_4_0/source/lib/ldb/common/ldb.c === --- branches/SAMBA_4_0/source/lib/ldb/common/ldb.c 2006-09-08 14:28:06 UTC (rev 18271) +++ branches/SAMBA_4_0/source/lib/ldb/common/ldb.c 2006-09-08 14:32:36 UTC (rev 18272) @@ -163,11 +163,11 @@ ret = ldb_search(ldb, ldb_dn_new(tmp_ctx), LDB_SCOPE_BASE, "(objectClass=*)", attrs, &res); if (ret == LDB_SUCCESS) { - talloc_steal(tmp_ctx, res); if (res->count == 1) { basedn = ldb_msg_find_attr_as_dn(ldb, res->msgs[0], "defaultNamingContext"); ldb_set_opaque(ldb, "default_baseDN", basedn); } + talloc_free(res); } talloc_free(tmp_ctx);
svn commit: samba r18271 - in branches/SAMBA_3_0/source: . auth groupdb include lib libads libmsrpc librpc/gen_ndr librpc/ndr libsmb modules nsswitch passdb python rpc_client rpc_parse rpc_server rpcc
Author: jerry Date: 2006-09-08 14:28:06 + (Fri, 08 Sep 2006) New Revision: 18271 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18271 Log: Big change: * autogenerate lsa ndr code * rename 'enum SID_NAME_USE' to 'enum lsa_SidType' * merge a log more security descriptor functions from gen_ndr/ndr_security.c in SAMBA_4_0 The most embarassing thing is the "#define strlen_m strlen" We need a real implementation in SAMBA_3_0 which I'll work on after this code is in. Added: branches/SAMBA_3_0/source/librpc/gen_ndr/cli_lsa.c branches/SAMBA_3_0/source/librpc/gen_ndr/cli_lsa.h branches/SAMBA_3_0/source/librpc/gen_ndr/lsa.h branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_lsa.c branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_lsa.h Modified: branches/SAMBA_3_0/source/Makefile.in branches/SAMBA_3_0/source/auth/auth_util.c branches/SAMBA_3_0/source/groupdb/mapping.c branches/SAMBA_3_0/source/include/charset.h branches/SAMBA_3_0/source/include/includes.h branches/SAMBA_3_0/source/include/mapping.h branches/SAMBA_3_0/source/include/passdb.h branches/SAMBA_3_0/source/include/smb.h branches/SAMBA_3_0/source/lib/util_sid.c branches/SAMBA_3_0/source/libads/ads_utils.c branches/SAMBA_3_0/source/libmsrpc/cac_lsarpc.c branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_unixinfo.c branches/SAMBA_3_0/source/librpc/ndr/ndr_misc.c branches/SAMBA_3_0/source/librpc/ndr/ndr_sec_helper.c branches/SAMBA_3_0/source/librpc/ndr/sid.c branches/SAMBA_3_0/source/libsmb/libsmbclient.c branches/SAMBA_3_0/source/modules/vfs_afsacl.c branches/SAMBA_3_0/source/nsswitch/wb_client.c branches/SAMBA_3_0/source/nsswitch/wbinfo.c branches/SAMBA_3_0/source/nsswitch/winbindd.h branches/SAMBA_3_0/source/nsswitch/winbindd_async.c branches/SAMBA_3_0/source/nsswitch/winbindd_cache.c branches/SAMBA_3_0/source/nsswitch/winbindd_creds.c branches/SAMBA_3_0/source/nsswitch/winbindd_group.c branches/SAMBA_3_0/source/nsswitch/winbindd_pam.c branches/SAMBA_3_0/source/nsswitch/winbindd_passdb.c branches/SAMBA_3_0/source/nsswitch/winbindd_reconnect.c branches/SAMBA_3_0/source/nsswitch/winbindd_rpc.c branches/SAMBA_3_0/source/nsswitch/winbindd_sid.c branches/SAMBA_3_0/source/nsswitch/winbindd_user.c branches/SAMBA_3_0/source/nsswitch/winbindd_util.c branches/SAMBA_3_0/source/passdb/lookup_sid.c branches/SAMBA_3_0/source/passdb/passdb.c branches/SAMBA_3_0/source/passdb/pdb_get_set.c branches/SAMBA_3_0/source/passdb/pdb_interface.c branches/SAMBA_3_0/source/passdb/pdb_ldap.c branches/SAMBA_3_0/source/python/py_lsa.c branches/SAMBA_3_0/source/rpc_client/cli_lsarpc.c branches/SAMBA_3_0/source/rpc_parse/parse_samr.c branches/SAMBA_3_0/source/rpc_server/srv_lsa_nt.c branches/SAMBA_3_0/source/rpc_server/srv_samr_nt.c branches/SAMBA_3_0/source/rpcclient/cmd_lsarpc.c branches/SAMBA_3_0/source/smbd/lanman.c branches/SAMBA_3_0/source/smbd/service.c branches/SAMBA_3_0/source/smbd/share_access.c branches/SAMBA_3_0/source/utils/net_groupmap.c branches/SAMBA_3_0/source/utils/net_lookup.c branches/SAMBA_3_0/source/utils/net_rpc.c branches/SAMBA_3_0/source/utils/net_rpc_rights.c branches/SAMBA_3_0/source/utils/net_sam.c branches/SAMBA_3_0/source/utils/net_util.c branches/SAMBA_3_0/source/utils/netlookup.c branches/SAMBA_3_0/source/utils/smbcacls.c branches/SAMBA_3_0/source/utils/smbcquotas.c Changeset: Sorry, the patch is too large (17840 lines) to include; please use WebSVN to see it! WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18271
svn commit: samba r18270 - in branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR: .
Author: jelmer Date: 2006-09-08 14:25:52 + (Fri, 08 Sep 2006) New Revision: 18270 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18270 Log: Samba3 has _PUBLIC_ now. Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm Changeset: Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm === --- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm 2006-09-08 14:23:44 UTC (rev 18269) +++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm 2006-09-08 14:25:52 UTC (rev 18270) @@ -2380,11 +2380,6 @@ pidl choose_header("librpc/gen_ndr/ndr_dcerpc.h", "gen_ndr/ndr_dcerpc.h"); pidl choose_header("librpc/rpc/dcerpc.h", "dcerpc.h"); #FIXME: This shouldn't be here! } - - # Samba3 doesn't have _PUBLIC - if (is_intree() == 3) { - pidl "#define _PUBLIC_"; - } } #
svn commit: samba r18269 - in branches/SAMBA_3_0/source/librpc/gen_ndr: .
Author: metze Date: 2006-09-08 14:23:44 + (Fri, 08 Sep 2006) New Revision: 18269 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18269 Log: regenerate idl output metze Modified: branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_unixinfo.c Changeset: Modified: branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_unixinfo.c === --- branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_unixinfo.c 2006-09-08 14:06:39 UTC (rev 18268) +++ branches/SAMBA_3_0/source/librpc/gen_ndr/ndr_unixinfo.c 2006-09-08 14:23:44 UTC (rev 18269) @@ -1,10 +1,7 @@ /* parser auto-generated by pidl */ #include "includes.h" -/* define dummy __attribute__ for systems that don't have it */ -#if !(defined(__GNUC__) || defined(__GNUG__) || defined(__attribute__)) -#define __attribute__(p) /* nothing */ -#endif +#define _PUBLIC_ #include "librpc/gen_ndr/ndr_unixinfo.h" #include "librpc/gen_ndr/ndr_security.h" @@ -84,8 +81,7 @@ return NT_STATUS_OK; } -__attribute__((visibility("default"))) -void ndr_print_unixinfo_GetPWUidInfo(struct ndr_print *ndr, const char *name, const struct unixinfo_GetPWUidInfo *r) +_PUBLIC_ void ndr_print_unixinfo_GetPWUidInfo(struct ndr_print *ndr, const char *name, const struct unixinfo_GetPWUidInfo *r) { ndr_print_struct(ndr, name, "unixinfo_GetPWUidInfo"); ndr->depth++; @@ -141,8 +137,7 @@ return NT_STATUS_OK; } -__attribute__((visibility("default"))) -void ndr_print_unixinfo_SidToUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToUid *r) +_PUBLIC_ void ndr_print_unixinfo_SidToUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToUid *r) { ndr_print_struct(ndr, name, "unixinfo_SidToUid"); ndr->depth++; @@ -204,8 +199,7 @@ return NT_STATUS_OK; } -__attribute__((visibility("default"))) -void ndr_print_unixinfo_UidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_UidToSid *r) +_PUBLIC_ void ndr_print_unixinfo_UidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_UidToSid *r) { ndr_print_struct(ndr, name, "unixinfo_UidToSid"); ndr->depth++; @@ -267,8 +261,7 @@ return NT_STATUS_OK; } -__attribute__((visibility("default"))) -void ndr_print_unixinfo_SidToGid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToGid *r) +_PUBLIC_ void ndr_print_unixinfo_SidToGid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_SidToGid *r) { ndr_print_struct(ndr, name, "unixinfo_SidToGid"); ndr->depth++; @@ -330,8 +323,7 @@ return NT_STATUS_OK; } -__attribute__((visibility("default"))) -void ndr_print_unixinfo_GidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GidToSid *r) +_PUBLIC_ void ndr_print_unixinfo_GidToSid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GidToSid *r) { ndr_print_struct(ndr, name, "unixinfo_GidToSid"); ndr->depth++; @@ -456,8 +448,7 @@ return NT_STATUS_OK; } -__attribute__((visibility("default"))) -void ndr_print_unixinfo_GetPWUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GetPWUid *r) +_PUBLIC_ void ndr_print_unixinfo_GetPWUid(struct ndr_print *ndr, const char *name, int flags, const struct unixinfo_GetPWUid *r) { uint32_t cntr_uids_0; uint32_t cntr_infos_1;
Rev 9138: Add torture context as first argument to macros in file:///home/jelmer/bzr.samba/4.0-unittest/
revno: 9138 committer: Jelmer Vernooij <[EMAIL PROTECTED]> branch nick: unittest timestamp: Fri 2006-09-08 16:21:52 +0200 message: Add torture context as first argument to macros modified: source/lib/crypto/sha1test.c source/lib/talloc/testsuite.c source/torture/auth/ntlmssp.c source/torture/auth/pac.c source/torture/local/binding_string.c source/torture/local/event.c source/torture/local/iconv.c source/torture/local/idtree.c source/torture/local/irpc.c source/torture/local/messaging.c source/torture/local/ndr.c source/torture/local/registry.c source/torture/local/resolve.c source/torture/local/sddl.c source/torture/local/socket.c source/torture/local/torture.c source/torture/local/util_file.c source/torture/local/util_strlist.c source/torture/rpc/atsvc.c source/torture/rpc/dfs.c source/torture/rpc/echo.c source/torture/rpc/eventlog.c source/torture/rpc/rpc.c source/torture/rpc/unixinfo.c source/torture/rpc/wkssvc.c source/torture/torture.c source/torture/ui.c source/torture/ui.h
Re: svn commit: samba r18245 - in branches/SAMBA_4_0/source/lib/ldb/common: .
Sorry, I should drink more coffe in the morning! I just realized that you steal it on tmp_ctx, not ldb, and that this actually fixes the memory leak, doh! Simo. On Fri, 2006-09-08 at 10:19 -0400, simo wrote: > Andrew, can you revert this? > ldb_msg_find_attr_as_dn() guarantees that basedn is talloc-ed on the ldb > context. It is completely useless to steal the whole structure and keep > all its memory around. > > Simo. > > On Fri, 2006-09-08 at 04:04 +, [EMAIL PROTECTED] wrote: > > Author: abartlet > > Date: 2006-09-08 04:04:30 + (Fri, 08 Sep 2006) > > New Revision: 18245 > > > > WebSVN: > > http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18245 > > > > Log: > > Ensure we don't keep the rootdse record around (steal it onto the > > correct memory context). > > > > Andrew Bartlett > > > > Modified: > >branches/SAMBA_4_0/source/lib/ldb/common/ldb.c > > > > > > Changeset: > > Modified: branches/SAMBA_4_0/source/lib/ldb/common/ldb.c > > === > > --- branches/SAMBA_4_0/source/lib/ldb/common/ldb.c 2006-09-08 03:28:39 UTC > > (rev 18244) > > +++ branches/SAMBA_4_0/source/lib/ldb/common/ldb.c 2006-09-08 04:04:30 UTC > > (rev 18245) > > @@ -162,12 +162,14 @@ > > tmp_ctx = talloc_new(ldb); > > ret = ldb_search(ldb, ldb_dn_new(tmp_ctx), LDB_SCOPE_BASE, > > "(objectClass=*)", attrs, &res); > > - if (ret == LDB_SUCCESS && res->count == 1) { > > - basedn = ldb_msg_find_attr_as_dn(ldb, res->msgs[0], > > "defaultNamingContext"); > > + if (ret == LDB_SUCCESS) { > > + talloc_steal(tmp_ctx, res); > > + if (res->count == 1) { > > + basedn = ldb_msg_find_attr_as_dn(ldb, res->msgs[0], > > "defaultNamingContext"); > > + ldb_set_opaque(ldb, "default_baseDN", basedn); > > + } > > } > > > > - ldb_set_opaque(ldb, "default_baseDN", basedn); > > - > > talloc_free(tmp_ctx); > > return basedn; > > } -- Simo Sorce Samba Team GPL Compliance Officer email: [EMAIL PROTECTED] http://samba.org
Re: svn commit: samba r18245 - in branches/SAMBA_4_0/source/lib/ldb/common: .
Andrew, can you revert this? ldb_msg_find_attr_as_dn() guarantees that basedn is talloc-ed on the ldb context. It is completely useless to steal the whole structure and keep all its memory around. Simo. On Fri, 2006-09-08 at 04:04 +, [EMAIL PROTECTED] wrote: > Author: abartlet > Date: 2006-09-08 04:04:30 + (Fri, 08 Sep 2006) > New Revision: 18245 > > WebSVN: > http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18245 > > Log: > Ensure we don't keep the rootdse record around (steal it onto the > correct memory context). > > Andrew Bartlett > > Modified: >branches/SAMBA_4_0/source/lib/ldb/common/ldb.c > > > Changeset: > Modified: branches/SAMBA_4_0/source/lib/ldb/common/ldb.c > === > --- branches/SAMBA_4_0/source/lib/ldb/common/ldb.c2006-09-08 03:28:39 UTC > (rev 18244) > +++ branches/SAMBA_4_0/source/lib/ldb/common/ldb.c2006-09-08 04:04:30 UTC > (rev 18245) > @@ -162,12 +162,14 @@ > tmp_ctx = talloc_new(ldb); > ret = ldb_search(ldb, ldb_dn_new(tmp_ctx), LDB_SCOPE_BASE, >"(objectClass=*)", attrs, &res); > - if (ret == LDB_SUCCESS && res->count == 1) { > - basedn = ldb_msg_find_attr_as_dn(ldb, res->msgs[0], > "defaultNamingContext"); > + if (ret == LDB_SUCCESS) { > + talloc_steal(tmp_ctx, res); > + if (res->count == 1) { > + basedn = ldb_msg_find_attr_as_dn(ldb, res->msgs[0], > "defaultNamingContext"); > + ldb_set_opaque(ldb, "default_baseDN", basedn); > + } > } > > - ldb_set_opaque(ldb, "default_baseDN", basedn); > - > talloc_free(tmp_ctx); > return basedn; > } -- Simo Sorce Samba Team GPL Compliance Officer email: [EMAIL PROTECTED] http://samba.org
svn commit: samba r18268 - in branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR: .
Author: metze Date: 2006-09-08 14:06:39 + (Fri, 08 Sep 2006) New Revision: 18268 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18268 Log: for samba3 define _PUBLIC_ empty metze Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm Changeset: Modified: branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm === --- branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm 2006-09-08 13:55:13 UTC (rev 18267) +++ branches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR/Parser.pm 2006-09-08 14:06:39 UTC (rev 18268) @@ -2380,6 +2380,11 @@ pidl choose_header("librpc/gen_ndr/ndr_dcerpc.h", "gen_ndr/ndr_dcerpc.h"); pidl choose_header("librpc/rpc/dcerpc.h", "dcerpc.h"); #FIXME: This shouldn't be here! } + + # Samba3 doesn't have _PUBLIC + if (is_intree() == 3) { + pidl "#define _PUBLIC_"; + } } #
svn commit: samba r18267 - in branches/SAMBA_4_0/source: .
Author: metze Date: 2006-09-08 13:55:13 + (Fri, 08 Sep 2006) New Revision: 18267 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18267 Log: print out the failing command for .ho files too metze Modified: branches/SAMBA_4_0/source/main.mk Changeset: Modified: branches/SAMBA_4_0/source/main.mk === --- branches/SAMBA_4_0/source/main.mk 2006-09-08 13:47:45 UTC (rev 18266) +++ branches/SAMBA_4_0/source/main.mk 2006-09-08 13:55:13 UTC (rev 18267) @@ -318,10 +318,6 @@ .SUFFIXES: .x .c .et .y .l .d .o .h .h.gch .a .so .1 .1.xml .3 .3.xml .5 .5.xml .7 .7.xml .8 .8.xml .ho .idl .hd -.c.ho: - @echo "Compiling $< with host compiler" - @$(HOSTCC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) -c $< -o $@ - .c.d: @echo "Generating dependencies for $<" @$(CC) -M -MG -MP -MT $(<:.c=.o) -MT $@ `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $< -o $@ @@ -345,6 +341,13 @@ echo "$(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@" 1>&2;\ $(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@ >/dev/null 2>&1 +.c.ho: + @echo "Compiling $< with host compiler" + @$(HOSTCC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) -c $< -o $@ && exit 0;\ + echo "The following command failed:" 1>&2;\ + echo "$(HOSTCC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) -c $< -o $@" 1>&2;\ + $(HOSTCC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) -c $< -o $@ >/dev/null 2>&1 + .h.h.gch: @echo "Precompiling $<" @$(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@
svn commit: samba r18266 - in branches/SAMBA_4_0/source/build/m4: .
Author: metze Date: 2006-09-08 13:47:45 + (Fri, 08 Sep 2006) New Revision: 18266 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18266 Log: we should bail out in configure if C99 structs are not support tridge: I think we should create macros in libreplace_macros.m4 and call them in check_cc.m4 instead of running the tests in libreplace.m4. Maybe the macros should remember if they're called and then they're skipped in libreplace.m4 inside samba4 metze Modified: branches/SAMBA_4_0/source/build/m4/check_cc.m4 Changeset: Modified: branches/SAMBA_4_0/source/build/m4/check_cc.m4 === --- branches/SAMBA_4_0/source/build/m4/check_cc.m4 2006-09-08 13:37:22 UTC (rev 18265) +++ branches/SAMBA_4_0/source/build/m4/check_cc.m4 2006-09-08 13:47:45 UTC (rev 18266) @@ -29,8 +29,20 @@ CFLAGS="${CFLAGS} -g" fi +dnl needed before AC_TRY_COMPILE +AC_ISC_POSIX +# check if the compiler handles c99 struct initialization +LIBREPLACE_C99_STRUCT_INIT(samba_cv_c99_struct_initialization=yes, + samba_cv_c99_struct_initialization=no) + +if test x"$samba_cv_c99_struct_initialization" != x"yes"; then + AC_MSG_WARN([C compiler does not support c99 struct initialization!]) + AC_MSG_ERROR([Please Install gcc from http://gcc.gnu.org/]) +fi + + # check if the compiler can handle negative enum values # and don't truncate the values to INT_MAX # a runtime test is needed here
svn commit: samba r18265 - in branches/SAMBA_4_0/source: .
Author: metze Date: 2006-09-08 13:37:22 + (Fri, 08 Sep 2006) New Revision: 18265 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18265 Log: print out the failling command metze Modified: branches/SAMBA_4_0/source/main.mk Changeset: Modified: branches/SAMBA_4_0/source/main.mk === --- branches/SAMBA_4_0/source/main.mk 2006-09-08 13:11:03 UTC (rev 18264) +++ branches/SAMBA_4_0/source/main.mk 2006-09-08 13:37:22 UTC (rev 18265) @@ -340,7 +340,10 @@ $(CC_CHECKER) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@; \ fi @echo "Compiling $<" - @$(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@ + @$(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@ && exit 0;\ + echo "The following command failed:" 1>&2;\ + echo "$(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@" 1>&2;\ + $(CC) `$(PERL) $(srcdir)/script/cflags.pl [EMAIL PROTECTED] $(CFLAGS) $(PICFLAG) -c $< -o $@ >/dev/null 2>&1 .h.h.gch: @echo "Precompiling $<"
svn commit: samba r18264 - in branches/SAMBA_4_0/source: .
Author: metze Date: 2006-09-08 13:11:03 + (Fri, 08 Sep 2006) New Revision: 18264 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18264 Log: print the full list of flags metze Modified: branches/SAMBA_4_0/source/main.mk Changeset: Modified: branches/SAMBA_4_0/source/main.mk === --- branches/SAMBA_4_0/source/main.mk 2006-09-08 13:00:48 UTC (rev 18263) +++ branches/SAMBA_4_0/source/main.mk 2006-09-08 13:11:03 UTC (rev 18264) @@ -66,11 +66,18 @@ showflags: @echo 'Samba will be compiled with flags:' - @echo ' CFLAGS = $(CFLAGS)' - @echo ' LDFLAGS = $(LDFLAGS)' + @echo ' CPP= $(CPP)' + @echo ' CPPFLAGS = $(CPPFLAGS)' + @echo ' CC = $(CC)' + @echo ' CFLAGS = $(CFLAGS)' + @echo ' PICFLAG= $(PICFLAG)' + @echo ' LD = $(LD)' + @echo ' LDFLAGS= $(LDFLAGS)' + @echo ' STLD = $(STLD)' @echo ' STLD_FLAGS = $(STLD_FLAGS)' + @echo ' SHLD = $(SHLD)' @echo ' SHLD_FLAGS = $(SHLD_FLAGS)' - @echo ' LIBS = $(LIBS)' + @echo ' SHLIBEXT = $(SHLIBEXT)' # The permissions to give the executables INSTALLPERMS = 0755
svn commit: samba r18263 - in branches/tmp/vl-messaging/source: include lib
Author: jmcd Date: 2006-09-08 13:00:48 + (Fri, 08 Sep 2006) New Revision: 18263 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18263 Log: >From Aleksey Fedoseev: Add database traverse for lockd-based locking, allowing locks to be seen in smbstatus. Modified: branches/tmp/vl-messaging/source/include/messages.h branches/tmp/vl-messaging/source/lib/dbwrap_msg.c branches/tmp/vl-messaging/source/lib/messages.c Changeset: Modified: branches/tmp/vl-messaging/source/include/messages.h === --- branches/tmp/vl-messaging/source/include/messages.h 2006-09-08 12:48:51 UTC (rev 18262) +++ branches/tmp/vl-messaging/source/include/messages.h 2006-09-08 13:00:48 UTC (rev 18263) @@ -88,6 +88,7 @@ #define MSG_DB_STORE5005 #define MSG_DB_DELETE 5006 #define MSG_DB_REINIT 5007 +#define MSG_DB_TRAVERSE5008 /* Flags to classify messages - used in message_send_all() */ /* Sender will filter by flag. */ Modified: branches/tmp/vl-messaging/source/lib/dbwrap_msg.c === --- branches/tmp/vl-messaging/source/lib/dbwrap_msg.c 2006-09-08 12:48:51 UTC (rev 18262) +++ branches/tmp/vl-messaging/source/lib/dbwrap_msg.c 2006-09-08 13:00:48 UTC (rev 18263) @@ -445,13 +445,59 @@ return 0; } +static void handle_traverse_return(int msg_type, struct process_id pid, + void *buf, size_t len); + static int db_msg_traverse(struct db_context *db, int (*fn)(TDB_DATA key, TDB_DATA value, void *private_data), void *private_data) { - /* TODO... but traverse will be VERY expensive */ - return -1; + struct db_msg_ctx *ctx = talloc_get_type_abort(db->private_data, + struct db_msg_ctx); + TDB_DATA null_data; + TDB_DATA buf; + static BOOL traverse_msg_reg = False; + int count = 0; + + null_data.dsize = 0; + null_data.dptr = NULL; + buf = msg_pack_data(ctx, ctx->db_index, null_data); + + if(buf.dptr == NULL) { + return -1; + } + + if(!traverse_msg_reg) { + message_register(MSG_DB_TRAVERSE, handle_traverse_return); + traverse_msg_reg = True; + } + + message_send_pid(ctx->lockd, MSG_DB_TRAVERSE, +buf.dptr, buf.dsize, False); + + TALLOC_FREE(buf.dptr); + + SMB_ASSERT(ctx->record == NULL); + + wait_for_return(ctx); + + while(ctx->record != NULL) { + count++; + + if(fn && fn(ctx->record->key, ctx->record->value, private_data)) { + /* break the traversal */ + TALLOC_FREE(ctx->record); + message_deregister(MSG_DB_TRAVERSE); + traverse_msg_reg = False; + break; + } + + TALLOC_FREE(ctx->record); + wait_for_return(ctx); + } + + return count; } static BOOL db_msg_reinit(struct db_context *db) @@ -584,6 +630,70 @@ ctx->record = result; } +static void handle_traverse_return(int msg_type, struct process_id pid, + void *buf, size_t len) +{ + struct db_record *result; + struct db_msg_ctx *ctx = ctx_list; + uint8_t idx; + TDB_DATA key, value; + + DEBUG(10, ("msg_traverse received with len %d\n", len)); + + if(!msg_unpack_double_data((const char *)buf, len, NULL, &idx, &key, &value)) { + DEBUG(2, ("Unpacking error\n")); + return ; + } + + while(ctx) { + if(ctx->db_index == idx) break; + ctx = ctx->next; + } + + if(ctx == NULL) { + DEBUG(2, ("Bad database index %d\n", idx)); + return ; + } + + ctx->received = True; + ctx->record = NULL; + + if(key.dsize > 0) { + result = TALLOC_ZERO_P(ctx, struct db_record); + if (result == NULL) { + DEBUG(0, ("talloc failed\n")); + return ; + } + + result->key.dsize = key.dsize; + result->key.dptr = (char *)talloc_memdup( + result, key.dptr, key.dsize); + + TALLOC_FREE(key.dptr); + + if (result->key.dptr == NULL) { + DEBUG(0, ("talloc failed\n")); + TALLOC_FREE(result); + TALLOC_FREE(value.dptr); + return ; + } + + if(value.dsize > 0) { + result->value.dsiz
svn commit: samba r18262 - in branches/SAMBA_4_0/source/build/m4: .
Author: metze Date: 2006-09-08 12:48:51 + (Fri, 08 Sep 2006) New Revision: 18262 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18262 Log: fix typos metze Modified: branches/SAMBA_4_0/source/build/m4/check_ld.m4 Changeset: Modified: branches/SAMBA_4_0/source/build/m4/check_ld.m4 === --- branches/SAMBA_4_0/source/build/m4/check_ld.m4 2006-09-08 12:28:11 UTC (rev 18261) +++ branches/SAMBA_4_0/source/build/m4/check_ld.m4 2006-09-08 12:48:51 UTC (rev 18262) @@ -46,7 +46,7 @@ SHLD_FLAGS="-shared -Wl,-Bsymbolic" fi LDFLAGS="-Wl,--export-dynamic" - PICFLAGS="-fPIC" + PICFLAG="-fPIC" SONAMEFLAG="-Wl,-soname=" ;; *solaris*) @@ -54,13 +54,13 @@ SHLD_FLAGS="-G" SONAMEFLAG="-h " if test "${GCC}" = "yes"; then - PICFLAGS="-fPIC" + PICFLAG="-fPIC" SONAMEFLAG="-Wl,-soname=" if test "${ac_cv_prog_gnu_ld}" = "yes"; then LDFLAGS="-Wl,-E" fi else - PICFLAGS="-KPIC" + PICFLAG="-KPIC" ## ${CFLAGS} added for building 64-bit shared ## libs using Sun's Compiler SHLD_FLAGS="-G \${CFLAGS}" @@ -70,19 +70,19 @@ BLDSHARED="true" SHLD_FLAGS="-G" SONAMEFLAG="-Wl,-h," - PICFLAGS="-KPIC" # Is this correct for SunOS + PICFLAG="-KPIC" # Is this correct for SunOS ;; *netbsd* | *freebsd* | *dragonfly* ) BLDSHARED="true" LDFLAGS="-Wl,--export-dynamic" SONAMEFLAG="-Wl,-soname," - PICFLAGS="-fPIC -DPIC" + PICFLAG="-fPIC -DPIC" ;; *openbsd*) BLDSHARED="true" LDFLAGS="-Wl,-Bdynamic" SONAMEFLAG="-Wl,-soname," - PICFLAGS="-fPIC" + PICFLAG="-fPIC" ;; *irix*) BLDSHARED="true" @@ -90,9 +90,9 @@ SONAMEFLAG="-soname " SHLD="${PROG_LD}" if test "${GCC}" = "yes"; then - PICFLAGS="-fPIC" + PICFLAG="-fPIC" else - PICFLAGS="-KPIC" + PICFLAG="-KPIC" fi ;; *aix*) @@ -100,7 +100,7 @@ SHLD_FLAGS="-Wl,-G,-bexpall" LDFLAGS="-Wl,-brtl,-bexpall,-bbigtoc" # as AIX code is always position independent... - PICFLAGS="-O2" + PICFLAG="-O2" ;; *hpux*) # Use special PIC flags for the native HP-UX compiler. @@ -108,10 +108,10 @@ BLDSHARED="true" SHLD_FLAGS="-b -Wl,-B,symbolic,-b,-z" SONAMEFLAG="-Wl,+h " - PICFLAGS="+z" + PICFLAG="+z" elif test "${GCC}" = "yes"; then BLDSHARED="true" # I hope this is correct - PICFLAGS="-fPIC" + PICFLAG="-fPIC" fi if test "$host_cpu" = "ia64"; then SHLIBEXT="so" @@ -124,12 +124,12 @@ *osf*) BLDSHARED="true" SONAMEFLAG="-Wl,-soname," - PICFLAGS="-fPIC" + PICFLAG="-fPIC" ;; *unixware*) BLDSHARED="true" SONAMEFLAG="-Wl,-soname," - PICFLAGS="-KPIC" + PICFLAG="-KPIC" ;; *darwin*) BLDSHARED="true"
svn commit: samba r18261 - in branches/SAMBA_4_0/source/build/m4: .
Author: metze Date: 2006-09-08 12:28:11 + (Fri, 08 Sep 2006) New Revision: 18261 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18261 Log: print out the version of gcc metze Modified: branches/SAMBA_4_0/source/build/m4/check_cc.m4 Changeset: Modified: branches/SAMBA_4_0/source/build/m4/check_cc.m4 === --- branches/SAMBA_4_0/source/build/m4/check_cc.m4 2006-09-08 11:42:47 UTC (rev 18260) +++ branches/SAMBA_4_0/source/build/m4/check_cc.m4 2006-09-08 12:28:11 UTC (rev 18261) @@ -14,6 +14,12 @@ AC_MSG_ERROR([Please Install gcc from http://gcc.gnu.org/]) fi +if test x"$GCC" = x"yes" ; then + AC_MSG_CHECKING([for version of gcc]) + GCC_VERSION=`$CC -dumpversion` + AC_MSG_RESULT(${GCC_VERSION}) +fi + # # Set the debug symbol option if we have # --enable-*developer or --enable-debug
svn commit: samba r18260 - in branches/SAMBA_4_0/source/build/smb_build: .
Author: metze Date: 2006-09-08 11:42:47 + (Fri, 08 Sep 2006) New Revision: 18260 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18260 Log: fix the build on systems with broken readdir this is just a short term hack we should move the stuff from lib/replace/config.mk into a lib/replace/samba.m4 and dynamicly generate the OBJ_FILES list for LIBREPLACE and get rid of REPLACE_REPDIR metze Modified: branches/SAMBA_4_0/source/build/smb_build/input.pm Changeset: Modified: branches/SAMBA_4_0/source/build/smb_build/input.pm === --- branches/SAMBA_4_0/source/build/smb_build/input.pm 2006-09-08 08:47:07 UTC (rev 18259) +++ branches/SAMBA_4_0/source/build/smb_build/input.pm 2006-09-08 11:42:47 UTC (rev 18260) @@ -36,6 +36,7 @@ return if ($part->{NAME} eq "LIBREPLACE"); return if ($part->{NAME} eq "LIBREPLACE_HOSTCC"); + return if ($part->{NAME} eq "REPLACE_READDIR"); foreach my $n (@{$part->{PRIVATE_DEPENDENCIES}}) { return if ($n eq "LIBREPLACE");
Re: svn commit: samba r18231 - inbranches/SAMBA_4_0/source/pidl/lib/Parse/Pidl/Samba4/NDR: .
> Author: jelmer > Date: 2006-09-07 20:24:59 + (Thu, 07 Sep 2006) > New Revision: 18231 > > WebSVN: > http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18231 > > Log: > Don't use _PUBLIC_ but use __attribute__ directly instead. I think we should better use this: #ifndef _PUBLIC_ #define _PUBLIC_ #endif because __attribute__() is maybe supported, but not __attribute__(visibility()) metze
svn commit: samba r18259 - in branches/SAMBA_3_0/source/nsswitch: .
Author: gd Date: 2006-09-08 08:47:07 + (Fri, 08 Sep 2006) New Revision: 18259 WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18259 Log: Fix the non-krb5 builds. Guenther Modified: branches/SAMBA_3_0/source/nsswitch/winbindd_pam.c Changeset: Modified: branches/SAMBA_3_0/source/nsswitch/winbindd_pam.c === --- branches/SAMBA_3_0/source/nsswitch/winbindd_pam.c 2006-09-08 06:57:01 UTC (rev 18258) +++ branches/SAMBA_3_0/source/nsswitch/winbindd_pam.c 2006-09-08 08:47:07 UTC (rev 18259) @@ -846,6 +846,7 @@ return result; } +#ifdef HAVE_KRB5 /* FIXME: what else points out that the remote domain is AD ? */ if (!strequal(domain->name, domain->alt_name) && (state->request.flags & WBFLAG_PAM_KRB5)) { @@ -907,7 +908,7 @@ } } } - +#endif /* HAVE_KRB5 */ return NT_STATUS_OK; }