[SCM] Samba Shared Repository - branch master updated

Kai Blin kai at samba.org
Sun May 30 15:30:52 MDT 2010


The branch, master has been updated
       via  e4a9bdc... s3-waf: Fix the build after rebase
       via  209555e... s3-waf: support avahi builds
       via  04d251a... build: Also replace '-' by '_' when creating header defines
       via  8e2b69c... s3-waf: Add more darwin-specific options
      from  5a0b3cf... s4:tests/python/passwords.py - fix filter

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit e4a9bdc39f499c7bfb04c00bc986c4894cf8e49a
Author: Kai Blin <kai at samba.org>
Date:   Sun May 30 23:27:08 2010 +0200

    s3-waf: Fix the build after rebase

commit 209555ef09bf57aa79f164f6e85a16e5b4977609
Author: Kai Blin <kai at samba.org>
Date:   Fri May 28 15:56:32 2010 +0200

    s3-waf: support avahi builds

commit 04d251a8476b8cf267667fc108f2f8c213fceb54
Author: Kai Blin <kai at samba.org>
Date:   Fri May 28 15:50:26 2010 +0200

    build: Also replace '-' by '_' when creating header defines
    
    Tridge, please check

commit 8e2b69ca46739960354b90c6ef843e68bb4e2330
Author: Kai Blin <kai at samba.org>
Date:   Wed May 26 13:44:43 2010 +0200

    s3-waf: Add more darwin-specific options

-----------------------------------------------------------------------

Summary of changes:
 buildtools/wafsamba/samba_autoconf.py |    1 +
 source3/wscript                       |   14 ++++++++++++++
 source3/wscript_build                 |   16 ++++++++++------
 3 files changed, 25 insertions(+), 6 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildtools/wafsamba/samba_autoconf.py b/buildtools/wafsamba/samba_autoconf.py
index 743f420..3551e02 100644
--- a/buildtools/wafsamba/samba_autoconf.py
+++ b/buildtools/wafsamba/samba_autoconf.py
@@ -84,6 +84,7 @@ def CHECK_HEADER(conf, h, add_headers=False, lib=None):
         return False
     d = h.upper().replace('/', '_')
     d = d.replace('.', '_')
+    d = d.replace('-', '_')
     d = 'HAVE_%s' % d
     if CONFIG_SET(conf, d):
         if add_headers:
diff --git a/source3/wscript b/source3/wscript
index e2e6f4d..a011a52 100644
--- a/source3/wscript
+++ b/source3/wscript
@@ -48,6 +48,7 @@ def set_options(opt):
     opt.SAMBA3_ADD_OPTION('sendfile-support')
     opt.SAMBA3_ADD_OPTION('utmp')
     opt.SAMBA3_ADD_OPTION('pthreadpool', with_name="enable", without_name="disable")
+    opt.SAMBA3_ADD_OPTION('avahi', with_name="enable", without_name="disable")
 
 
 def configure(conf):
@@ -532,6 +533,17 @@ return 0;
                         msg="Checking whether pututline returns pointer")
         conf.DEFINE('WITH_UTMP', 1)
 
+    if Options.options.with_avahi:
+        conf.env.with_avahi = True
+        if not conf.CHECK_HEADERS('avahi-common/watch.h avahi-client/client.h'): conf.env.with_avahi = False
+        if not conf.CHECK_FUNCS_IN('avahi_client_new', 'avahi-client'): conf.env.with_avahi = False
+        if not conf.CHECK_FUNCS_IN('avahi_strerror', 'avahi-common'): conf.env.with_avahi = False
+        if conf.env.with_avahi:
+            conf.DEFINE('WITH_AVAHI_SUPPORT', 1)
+    else:
+        conf.SET_TARGET_TYPE('avahi-common', 'EMPTY')
+        conf.SET_TARGET_TYPE('avahi-client', 'EMPTY')
+
     # FIXME: these should be tests for features, but the old build system just
     # checks for OSes.
     import sys
@@ -547,7 +559,9 @@ return 0;
             conf.DEFINE('QNX', '1')
         conf.DEFINE('STAT_ST_BLOCKSIZE', '512')
     elif (host_os.rfind('darwin') > -1):
+        conf.DEFINE('DARWINOS', 1)
         conf.DEFINE('STAT_ST_BLOCKSIZE', '512')
+        conf.ADD_CFLAGS('-fno-common')
     # FIXME: Add more checks here.
     else:
         print "Unknown host_os '%s', please report this to samba-technical at samba.org" % host_os
diff --git a/source3/wscript_build b/source3/wscript_build
index 770877e..4619327 100644
--- a/source3/wscript_build
+++ b/source3/wscript_build
@@ -23,7 +23,7 @@ AFS_SRC = 'lib/afs.c'
 
 AFS_SETTOKEN_SRC = 'lib/afs_settoken.c'
 
-AVAHI_SRC = '' # TODO: fix
+AVAHI_SRC = 'lib/avahi.c smbd/avahi_register.c'
 
 SERVER_MUTEX_SRC = 'lib/server_mutex.c'
 
@@ -149,7 +149,7 @@ LIB_SRC = '''${LIBSAMBAUTIL_SRC} ${UTIL_SRC} ${CRYPTO_SRC}
           lib/bitmap.c lib/dprintf.c ${UTIL_REG_SRC}
           lib/wins_srv.c
           lib/util_str.c lib/clobber.c lib/util_sid.c lib/util_uuid.c
-          lib/util_unistr.c lib/util_file.c
+          lib/util_unistr.c lib/util_file.c lib/util_names.c
           lib/util.c lib/util_sock.c lib/sock_exec.c lib/util_sec.c
           lib/substitute.c lib/dbwrap_util.c
           lib/ms_fnmatch.c lib/select.c lib/errmap_unix.c
@@ -663,11 +663,11 @@ LIBSMBCONF_SRC = '''../lib/smbconf/smbconf.c ../lib/smbconf/smbconf_util.c
 
 MANGLE_SRC = '''smbd/mangle.c smbd/mangle_hash.c smbd/mangle_hash2.c'''
 
-SMBD_SRC_MAIN = '''smbd/server.c'''
+SMBD_SRC_MAIN = '''smbd/server.c smbd/server_exit.c'''
 
 BUILDOPT_SRC = '''smbd/build_options.c'''
 
-SMBD_SRC_SRV = '''smbd/files.c smbd/connection.c
+SMBD_SRC_SRV = '''smbd/server_reload.c smbd/files.c smbd/connection.c
                smbd/utmp.c smbd/session.c smbd/map_username.c
                smbd/dfree.c smbd/dir.c smbd/password.c smbd/conn.c
                smbd/share_access.c smbd/fileio.c
@@ -715,7 +715,7 @@ SMBD_SRC_BASE = '''${SMBD_SRC_SRV}
                 ${PROFILE_SRC} ${PRINTBACKEND_SRC}
                 ${OPLOCK_SRC} ${NOTIFY_SRC} ${FNAME_UTIL_SRC}
                 ${LIBMSRPC_SRC}
-                ${LIBMSRPC_GEN_SRC} ${AVAHI_SRC} ${LIBADS_SRC}
+                ${LIBMSRPC_GEN_SRC} ${LIBADS_SRC}
                 ${LIBADS_SERVER_SRC} ${REG_FULL_SRC}
                 ${BUILDOPT_SRC}
                 ${LIBNET_SRC} ${LIBSMBCONF_SRC}
@@ -851,6 +851,10 @@ bld.SAMBA_SUBSYSTEM('ASN1_UTIL',
                     deps='talloc',
                     local_include=False)
 
+bld.SAMBA_SUBSYSTEM('AVAHI',
+                    source=AVAHI_SRC,
+                    enabled=bld.env.with_avahi)
+
 bld.SAMBA_SUBSYSTEM('GROUPDB',
                     source=GROUPDB_SRC)
 
@@ -919,7 +923,7 @@ bld.SAMBA_BINARY('smbd/smbd',
                  source=SMBD_SRC,
                  deps='''tdb DYNCONFIG tevent dl krb5 ldap gssapi gssapi_krb5
                  NSS_WRAPPER LIBWBCLIENT crypt nsl cups cap resolv ZLIB PASSDB
-                 PARAM_WITHOUT_REG LIBS LIBSMB POPT_SAMBA KRBCLIENT''',
+                 PARAM_WITHOUT_REG LIBS LIBSMB POPT_SAMBA KRBCLIENT AVAHI''',
                  install_path='${SBINDIR}',
                  vars=locals())
 


-- 
Samba Shared Repository


More information about the samba-cvs mailing list