r10366: More scons fixes. Building et, asn1, lex and yacc files sort-of works now
authorJelmer Vernooij <jelmer@samba.org>
Tue, 20 Sep 2005 22:10:40 +0000 (22:10 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:38:32 +0000 (13:38 -0500)
(This used to be commit 22f18a84242e5e68a2d57b6d7ff77c089ee7434a)

16 files changed:
source4/SConstruct
source4/auth/SConscript
source4/build/scons/asn1.py
source4/build/scons/et.py
source4/build/scons/pidl.py
source4/build/scons/pkgconfig.py [new file with mode: 0644]
source4/build/smb_build/makefile.pm
source4/dynconfig.c
source4/heimdal_build/SConscript
source4/lib/SConscript
source4/lib/genrand.c
source4/lib/ldb/SConscript
source4/lib/registry/SConscript
source4/lib/socket_wrapper/SConscript
source4/lib/tls/SConscript
source4/param/loadparm.c

index fb23cc50663b6480f71586f83e63999402cd35a3..12d47ba89b2dde2b2f8b92eb718d24a0ea09c5a4 100644 (file)
@@ -7,21 +7,48 @@
 # Copyright (C) 2005 Jelmer Vernooij <jelmer@samba.org>
 # Published under the GNU GPL
 
+opts = Options(None, ARGUMENTS)
+opts.AddOptions(
+               BoolOption('developer','enable developer flags', 0),
+               PathOption('prefix','installation prefix','/usr/local/samba')
+)
+
 hostenv = Environment(
                toolpath=['build/scons','.'],
-               tools=['default','pidl','proto','et'],
+               tools=['default','pidl','proto','et','asn1'],
+               options=opts,
                CPPPATH=['#include','#','#lib'], 
                 CPPDEFINES={'_SAMBA_BUILD_': None},
                )
 
+if hostenv['developer']:
+       hostenv.Append(CCFLAGS=' -Wall')
+       hostenv.Append(CCFLAGS=' -Wshadow')
+       hostenv.Append(CCFLAGS=' -Werror-implicit-function-declaration')
+       hostenv.Append(CCFLAGS=' -Wstrict-prototypes')
+       hostenv.Append(CCFLAGS=' -Wpointer-arith')
+       hostenv.Append(CCFLAGS=' -Wcast-qual')
+       hostenv.Append(CCFLAGS=' -Wcast-align')
+       hostenv.Append(CCFLAGS=' -Wwrite-strings')
+       hostenv.Append(CCFLAGS=' -Wmissing-format-attribute')
+       hostenv.Append(CCFLAGS=' -Wformat=2')
+       hostenv.Append(CCFLAGS=' -Wno-format-y2k')
+       hostenv.Append(CCFLAGS=' -Wno-declaration-after-statement')
+
+
+
 hostenv.Append(CPPPATH = ['#heimdal_build', '#heimdal/lib/krb5',
                          '#heimdal/lib/hdb', '#heimdal/lib/gssapi',
                          '#heimdal/lib/asn1', '#heimdal/lib/des',
                          '#heimdal/kdc', '#heimdal/lib/roken',
                          '#heimdal/lib/com_err'])
 
+Export('hostenv')
+
 buildenv = hostenv
 
+Export('buildenv')
+
 cross_compiling = 0
 
 if cross_compiling:
@@ -30,10 +57,8 @@ if cross_compiling:
 
 dynenv = hostenv.Copy()
 
-bindir = "bindir"
-
 paths = { 
-       'BINDIR': bindir,
+       'BINDIR': "bin",
        'SBINDIR': "sbin",
        'CONFIGFILE': "cfg",
        'LOGFILEBASE': "lfb",
@@ -43,23 +68,53 @@ paths = {
        'SHLIBEXT': "ext",
        'LOCKDIR': "lockdir",
        'PIDDIR': "piddir",
-       'SMB_PASSWD_FILE': "smbpasswd",
        'PRIVATE_DIR': 'private',
        'SWATDIR': 'swat'
 }
 
+Export('paths')
+
+conf = hostenv.Configure()
+for h in ['sys/select.h','fcntl.h','sys/fcntl.h','sys/time.h'] + \
+       ['utime.h','grp.h','sys/id.h','limits.h','memory.h'] + \
+       ['compat.h','math.h','sys/param.h','ctype.h','sys/wait.h'] + \
+       ['sys/resource.h','sys/ioctl.h','sys/ipc.h','sys/mode.h'] + \
+       ['sys/mman.h','sys/filio.h','sys/priv.h','sys/shm.h','string.h'] + \
+       ['strings.h','stdlib.h','sys/vfs.h','sys/fs/s5param.h','sys/filsys.h'] + \
+       ['termios.h','termio.h','fnmatch.h','pwd.h','sys/termio.h'] + \
+       ['sys/time.h','sys/statfs.h','sys/statvfs.h','stdarg.h'] + \
+       ['security/pam_modules.h','security/_pam_macros.h','dlfcn.h'] + \
+       ['sys/syslog.h','syslog.h','stdint.h','inttypes.h','locale.h'] + \
+       ['shadow.h','nss.h','nss_common.h','ns_api.h','sys/security.h'] + \
+       ['security/pam_appl.h','sys/capability.h','syscall.h','sys/syscall.h'] + \
+       ['sys/acl.h']:
+       conf.CheckCHeader(h)
+
+for f in ['dlopen','dlsym','dlerror','waitpid','getcwd','strdup'] + \
+       ['strndup','strnlen','strerror','chroot','bzero','memset','strlcpy'] + \
+       ['strlcat','memmove','vsnprintf','snprintf','asprintf','vasprintf'] + \
+       ['setsid','pipe','crypt16','getauthuid','strftime','sigprocmask'] + \
+       ['sigblock','sigaction','innetgr','setnetgrent','getnetgrent'] + \
+       ['endnetgrent','initgroups','setgroups','sysconf','mktime','rename'] + \
+       ['ftruncate','chsize','getpwanam','setlinebuf','srandom','random'] + \
+       ['srand','rand','setenv','usleep','syslog','vsyslog','timegm'] + \
+       ['backtrace','setbuffer','pread','pwrite']:
+       conf.CheckFunc(f)
+
+conf.Finish()
+
 [dynenv.Append(CPPDEFINES = {p: '\\"%s\\"' % paths[p]}) for p in paths]
        
 dynconfig = dynenv.Object('dynconfig.c')
 Export('dynconfig')
 
 proto_files = []
+Export('proto_files')
 
 SConscript(
                dirs=['param','lib','torture','rpc_server','cldap_server','libcli',
                'nbt_server','client','ldap_server','libnet','nsswitch','web_server',
                'smbd','dsdb','heimdal_build','ntptr','kdc','smb_server','ntvfs',
-               'winbind','scripting','auth'],
-               exports='buildenv hostenv proto_files')
+               'winbind','scripting','auth'])
 
-hostenv.CProtoHeader(target='include/proto.h',source = proto_files)
+hostenv.CProtoHeader(target='include/proto.h',source=proto_files)
index 298092834b9153d58651b9e08e1067c42a2b15dc..34cff89bb3241b51555283bac685cf6a56ddf627 100644 (file)
@@ -6,7 +6,12 @@ hostenv.StaticLibrary('auth_winbind.c')
 hostenv.StaticLibrary('auth_domain.c')
 hostenv.StaticLibrary('auth_developer.c')
 hostenv.StaticLibrary('auth_unix.c')
+
+conf = hostenv.Configure()
+have_pam = conf.CheckLibWithHeader('pam', 'security/pam_appl.h', 'c', 'pam_start')
+conf.Finish()
+
 hostenv.StaticLibrary('pam_errors.c')
 hostenv.StaticLibrary('auth',['auth.c','auth_util.c','auth_sam_reply.c','ntlm_check.c'])
 
-SConscript(dirs=['ntlmssp','kerberos','gensec'],exports='hostenv')
+SConscript(dirs=['ntlmssp','kerberos','gensec'])
index 078ac74a55d501808bee954e1a1cca0758fb8499..f0068e20dd1180a0a46ea4a75afcb5b0b5329b78 100644 (file)
@@ -5,22 +5,29 @@ Tool-specific initialization for ASN1
 """
 
 import SCons.Defaults
-import SCons.Scanner.ASN1
 import SCons.Util
+import re
 
-asn1_scanner = SCons.Scanner.ASN1.ASN1Scan()
+output_re = re.compile(r'^([A-Za-z0-9_-]+)[ \t]*::=', re.M)
+
+def asn1_emitter(target,source,env):
+       targets = []
+       for s in source:
+               node = env.File(s)
+               contents = node.get_contents()
+               for j in output_re.findall(contents):
+                       targets.append(str(node.get_dir()) + '/asn1_' + j + '.c')
+       return targets, source
 
 asn1_builder = SCons.Builder.Builder(action='$ASN1COM',
                                      src_suffix = '.asn1',
                                      suffix='.c',
-                                     scanner = asn1_scanner)
+                                     emitter = asn1_emitter)
 
 def generate(env):
-    env['ASN1']          = 'FIXME'
-    env['PROTOCOM']       = '$ASN1 $SOURCE'
+    env['ASN1']          = './bin/asn1_compile'
+    env['ASN1COM']       = '$ASN1 $SOURCE'
     env['BUILDERS']['ASN1'] = asn1_builder
 
 def exists(env):
-       return env.Detect('FIXME')
-
-
+       return env.Detect('asn1_compile')
index ea251cd1426c507e8473a7a2afa4734ebc01de00..2864b32957e3633308ed2ced4b8445af7b561698 100644 (file)
@@ -13,21 +13,9 @@ et_builder = SCons.Builder.Builder(action='$ETCOM',
                                      suffix='.c')
 
 def generate(env):
-    env['ET']          = env.Detect('et_compile')
+    env['ET']          = './bin/compile_et'
     env['ETCOM']       = '$ET $SOURCE'
-    env['BUILDERS']['ET'] = et_builder
+    env['BUILDERS']['ErrorTable'] = et_builder
 
 def exists(env):
-       return env.Detect(['et_compile'])
-
-def generate(env):
-    """Add Builders and construction variables for lex to an Environment."""
-    c_file, cxx_file = SCons.Tool.createCFileBuilders(env)
-
-    c_file.add_action('.l', SCons.Defaults.LexAction)
-    cxx_file.add_action('.ll', SCons.Defaults.LexAction)
-
-    env['LEX']      = env.Detect('flex') or 'lex'
-    env['LEXFLAGS'] = SCons.Util.CLVar('')
-    env['LEXCOM']   = '$LEX $LEXFLAGS -t $SOURCES > $TARGET'
-    
+       return env.Detect(['./bin/compile_et'])
index 6bddea3ee4028400fe173b6c2447d25b69351d8f..68a2c2040e6760ddc577836a8c685d076cfbb74a 100644 (file)
@@ -5,10 +5,10 @@ Tool-specific initialization for pidl (Perl-based IDL compiler)
 """
 
 import SCons.Defaults
-import SCons.Scanner.IDL
 import SCons.Util
+import SCons.Scanner
 
-idl_scanner = SCons.Scanner.IDL.IDLScan()
+idl_scanner = SCons.Scanner.ClassicCPP("PIDLScan", '.idl', 'CPPPATH', r'depends\(([^,]+),+\)', SCons.Node.FS.default_fs)
 
 pidl_builder = SCons.Builder.Builder(action='$PIDLCOM',
                                      src_suffix = '.idl',
diff --git a/source4/build/scons/pkgconfig.py b/source4/build/scons/pkgconfig.py
new file mode 100644 (file)
index 0000000..6a0c82f
--- /dev/null
@@ -0,0 +1,13 @@
+# Based on the examples from the scons wiki
+
+def CheckPKGConfig(context, version):
+       context.Message('Checking for pkg-config... ')
+       ret = context.TryAction('pkg-config --atleast-pkgconfig-version=%s' % version)[0]
+       context.Result(ret)
+       return ret
+
+def CheckPackage(context, name):
+       context.Message('Checking for %s... ' % name)
+       ret = context.TryAction('pkg-config --exists \'%s\'' % name)[0]
+       context.Result(ret)
+       return ret
index 36183f210f9f9c1cfd9a81a32c386883b3a74f95..fdba441f637ad3d20740a6ab8939cc40c9343f28 100644 (file)
@@ -62,16 +62,12 @@ INSTALLPERMS = 0755
 CONFIGFILE = $(CONFIGDIR)/smb.conf
 LMHOSTSFILE = $(CONFIGDIR)/lmhosts
 
-# This is where smbpasswd et al go
-SMB_PASSWD_FILE = $(PRIVATEDIR)/smbpasswd
-
 PATH_FLAGS = -DCONFIGFILE=\"$(CONFIGFILE)\"  -DSBINDIR=\"$(SBINDIR)\" \
         -DBINDIR=\"$(BINDIR)\" -DLMHOSTSFILE=\"$(LMHOSTSFILE)\" \
         -DLOCKDIR=\"$(LOCKDIR)\" -DPIDDIR=\"$(PIDDIR)\" -DLIBDIR=\"$(LIBDIR)\" \
         -DLOGFILEBASE=\"$(LOGFILEBASE)\" -DSHLIBEXT=\"$(SHLIBEXT)\" \
         -DCONFIGDIR=\"$(CONFIGDIR)\" -DNCALRPCDIR=\"$(NCALRPCDIR)\" \
-        -DSWATDIR=\"$(SWATDIR)\" -DSMB_PASSWD_FILE=\"$(SMB_PASSWD_FILE)\" \
-        -DPRIVATE_DIR=\"$(PRIVATEDIR)\"
+        -DSWATDIR=\"$(SWATDIR)\" -DPRIVATE_DIR=\"$(PRIVATEDIR)\"
 __EOD__
 
        return $output;
index 096819f822c6eb0ba934636afe243f345206ee9a..20567dcafcc2adc65dbdba2780fa5fe72b183655 100644 (file)
@@ -70,6 +70,5 @@ const char *dyn_SHLIBEXT = SHLIBEXT;
 const char *dyn_LOCKDIR = LOCKDIR;
 const char *dyn_PIDDIR  = PIDDIR;
 
-const char *dyn_SMB_PASSWD_FILE = SMB_PASSWD_FILE;
 const char *dyn_PRIVATE_DIR = PRIVATE_DIR;
 const char *dyn_SWATDIR = SWATDIR;
index 86b571f8c2728f27bc8b78cc57c2af26efca2ed8..9724ae7425f1b6d7267aa6403572fd1288a145fe 100644 (file)
@@ -5,22 +5,14 @@ hostenv.StaticLibrary('heimdal_kdc',
         '../kdc/log.c','../kdc/misc.c','../kdc/524.c','../kdc/kerberos4.c',
         '../kdc/kaserver.c','../kdc/process.c'])
 
+hdb_asn1 = hostenv.ASN1('../heimdal/lib/hdb/hdb.asn1')
+gssapi_asn1 = hostenv.ASN1('../heimdal/lib/gssapi/spnego.asn1')
+k5_asn1 = hostenv.ASN1('../heimdal/lib/asn1/k5.asn1')
+
 hostenv.StaticLibrary('heimdal_hdb',
        ['../heimdal/lib/hdb/db.c','../heimdal/lib/hdb/hdb.c','../heimdal/lib/hdb/ext.c','../heimdal/lib/hdb/keys.c',
-       '../heimdal/lib/hdb/mkey.c','../heimdal/lib/hdb/ndbm.c','../heimdal/lib/hdb/asn1_Event.c',
-       '../heimdal/lib/hdb/asn1_GENERATION.c','../heimdal/lib/hdb/asn1_HDBFlags.c',
-       '../heimdal/lib/hdb/asn1_HDB_Ext_Aliases.c',
-       '../heimdal/lib/hdb/asn1_HDB_Ext_Constrained_delegation_acl.c',
-       '../heimdal/lib/hdb/asn1_HDB_Ext_Lan_Manager_OWF.c',
-       '../heimdal/lib/hdb/asn1_HDB_Ext_PKINIT_acl.c',
-       '../heimdal/lib/hdb/asn1_HDB_Ext_PKINIT_certificate.c',
-       '../heimdal/lib/hdb/asn1_HDB_Ext_Password.c',
-       '../heimdal/lib/hdb/asn1_HDB_extension.c',
-       '../heimdal/lib/hdb/asn1_HDB_extensions.c',
-       '../heimdal/lib/hdb/asn1_Key.c',
-       '../heimdal/lib/hdb/asn1_Salt.c',
-       '../heimdal/lib/hdb/asn1_hdb_entry.c',
-       '../heimdal/lib/hdb/hdb_err.c'])
+       '../heimdal/lib/hdb/mkey.c','../heimdal/lib/hdb/ndbm.c',hdb_asn1,
+       hostenv.ErrorTable('../heimdal/lib/hdb/hdb_err.et')])
 
 hostenv.StaticLibrary('heimdal_gssapi',
        ['../heimdal/lib/gssapi/init_sec_context.c','../heimdal/lib/gssapi/inquire_cred.c',
@@ -28,10 +20,8 @@ hostenv.StaticLibrary('heimdal_gssapi',
        '../heimdal/lib/gssapi/release_name.c','../heimdal/lib/gssapi/release_oid_set.c',
        '../heimdal/lib/gssapi/sequence.c','../heimdal/lib/gssapi/test_oid_set_member.c',
        '../heimdal/lib/gssapi/unwrap.c','../heimdal/lib/gssapi/verify_mic.c','../heimdal/lib/gssapi/wrap.c',
-       '../heimdal/lib/gssapi/address_to_krb5addr.c','../heimdal/lib/gssapi/asn1_ContextFlags.c',
-       '../heimdal/lib/gssapi/asn1_MechType.c','../heimdal/lib/gssapi/asn1_MechTypeList.c',
-       '../heimdal/lib/gssapi/asn1_NegotiationToken.c','../heimdal/lib/gssapi/asn1_NegTokenInit.c',
-       '../heimdal/lib/gssapi/asn1_NegTokenTarg.c','../heimdal/lib/gssapi/8003.c',
+       '../heimdal/lib/gssapi/address_to_krb5addr.c',
+       gssapi_asn1,'../heimdal/lib/gssapi/8003.c',
        '../heimdal/lib/gssapi/accept_sec_context.c','../heimdal/lib/gssapi/acquire_cred.c',
        '../heimdal/lib/gssapi/add_oid_set_member.c','../heimdal/lib/gssapi/arcfour.c',
        '../heimdal/lib/gssapi/ccache_name.c','../heimdal/lib/gssapi/copy_ccache.c','../heimdal/lib/gssapi/cfx.c',
@@ -72,42 +62,12 @@ hostenv.StaticLibrary('heimdal_krb5',
        '../heimdal/lib/krb5/set_default_realm.c','../heimdal/lib/krb5/store.c','../heimdal/lib/krb5/store_emem.c',
        '../heimdal/lib/krb5/store_fd.c','../heimdal/lib/krb5/store_mem.c','../heimdal/lib/krb5/ticket.c',
        '../heimdal/lib/krb5/time.c','../heimdal/lib/krb5/transited.c','../heimdal/lib/krb5/v4_glue.c',
-       '../heimdal/lib/krb5/version.c','../heimdal/lib/krb5/warn.c','../heimdal/lib/krb5/krb5_err.c',
-       '../heimdal/lib/krb5/heim_err.c','../heimdal/lib/krb5/k524_err.c'])
+       '../heimdal/lib/krb5/version.c','../heimdal/lib/krb5/warn.c',
+       hostenv.ErrorTable('../heimdal/lib/krb5/krb5_err.et'),
+       hostenv.ErrorTable('../heimdal/lib/krb5/heim_err.et'),
+       hostenv.ErrorTable('../heimdal/lib/krb5/k524_err.et')])
 
-hostenv.StaticLibrary('heimdal_asn1',
-       ['../heimdal/lib/asn1/der_get.c','../heimdal/lib/asn1/der_put.c','../heimdal/lib/asn1/der_free.c',
-       '../heimdal/lib/asn1/der_length.c','../heimdal/lib/asn1/der_copy.c','../heimdal/lib/asn1/der_cmp.c',
-       '../heimdal/lib/asn1/asn1_AD_IF_RELEVANT.c','../heimdal/lib/asn1/asn1_APOptions.c',
-       '../heimdal/lib/asn1/asn1_AP_REP.c','../heimdal/lib/asn1/asn1_AP_REQ.c','../heimdal/lib/asn1/asn1_AS_REP.c',
-       '../heimdal/lib/asn1/asn1_AS_REQ.c','../heimdal/lib/asn1/asn1_Authenticator.c',
-       '../heimdal/lib/asn1/asn1_AuthorizationData.c','../heimdal/lib/asn1/asn1_CBCParameter.c',
-       '../heimdal/lib/asn1/asn1_CKSUMTYPE.c','../heimdal/lib/asn1/asn1_ChangePasswdDataMS.c',
-       '../heimdal/lib/asn1/asn1_Checksum.c','../heimdal/lib/asn1/asn1_ENCTYPE.c',
-       '../heimdal/lib/asn1/asn1_ETYPE_INFO.c','../heimdal/lib/asn1/asn1_ETYPE_INFO2.c',
-       '../heimdal/lib/asn1/asn1_ETYPE_INFO2_ENTRY.c','../heimdal/lib/asn1/asn1_ETYPE_INFO_ENTRY.c',
-       '../heimdal/lib/asn1/asn1_EncAPRepPart.c','../heimdal/lib/asn1/asn1_EncASRepPart.c',
-       '../heimdal/lib/asn1/asn1_EncKDCRepPart.c','../heimdal/lib/asn1/asn1_EncKrbCredPart.c',
-       '../heimdal/lib/asn1/asn1_EncKrbPrivPart.c','../heimdal/lib/asn1/asn1_EncTGSRepPart.c',
-       '../heimdal/lib/asn1/asn1_EncTicketPart.c','../heimdal/lib/asn1/asn1_EncryptedData.c',
-       '../heimdal/lib/asn1/asn1_EncryptionKey.c','../heimdal/lib/asn1/asn1_EtypeList.c',
-       '../heimdal/lib/asn1/asn1_HostAddress.c','../heimdal/lib/asn1/asn1_HostAddresses.c',
-       '../heimdal/lib/asn1/asn1_KDCOptions.c','../heimdal/lib/asn1/asn1_KDC_REP.c',
-       '../heimdal/lib/asn1/asn1_KDC_REQ.c','../heimdal/lib/asn1/asn1_KDC_REQ_BODY.c',
-       '../heimdal/lib/asn1/asn1_KRB_CRED.c','../heimdal/lib/asn1/asn1_KRB_ERROR.c',
-       '../heimdal/lib/asn1/asn1_KRB_PRIV.c','../heimdal/lib/asn1/asn1_KerberosString.c',
-       '../heimdal/lib/asn1/asn1_KerberosTime.c','../heimdal/lib/asn1/asn1_KrbCredInfo.c',
-       '../heimdal/lib/asn1/asn1_LR_TYPE.c','../heimdal/lib/asn1/asn1_LastReq.c',
-       '../heimdal/lib/asn1/asn1_MESSAGE_TYPE.c','../heimdal/lib/asn1/asn1_METHOD_DATA.c',
-       '../heimdal/lib/asn1/asn1_NAME_TYPE.c','../heimdal/lib/asn1/asn1_PADATA_TYPE.c',
-       '../heimdal/lib/asn1/asn1_PA_DATA.c','../heimdal/lib/asn1/asn1_PA_ENC_TS_ENC.c',
-       '../heimdal/lib/asn1/asn1_PA_PAC_REQUEST.c','../heimdal/lib/asn1/asn1_Principal.c',
-       '../heimdal/lib/asn1/asn1_PrincipalName.c','../heimdal/lib/asn1/asn1_RC2CBCParameter.c',
-       '../heimdal/lib/asn1/asn1_Realm.c','../heimdal/lib/asn1/asn1_TGS_REP.c',
-       '../heimdal/lib/asn1/asn1_TGS_REQ.c','../heimdal/lib/asn1/asn1_Ticket.c',
-       '../heimdal/lib/asn1/asn1_TicketFlags.c','../heimdal/lib/asn1/asn1_TransitedEncoding.c',
-       '../heimdal/lib/asn1/asn1_err.c','../heimdal/lib/asn1/asn1_krb5int32.c',
-       '../heimdal/lib/asn1/asn1_krb5uint32.c'])
+hostenv.StaticLibrary('heimdal_asn1', k5_asn1)
 
 hostenv.StaticLibrary('heimdal_des',
        ['../heimdal/lib/des/aes.c','../heimdal/lib/des/des.c','../heimdal/lib/des/md4.c','../heimdal/lib/des/md5.c',
@@ -141,8 +101,8 @@ buildenv.Program('asn1_compile',
        '../heimdal/lib/asn1/gen_copy.c','../heimdal/lib/asn1/gen_decode.c',
        '../heimdal/lib/asn1/gen_encode.c','../heimdal/lib/asn1/gen_free.c',
        '../heimdal/lib/asn1/gen_glue.c','../heimdal/lib/asn1/gen_length.c',
-       '../heimdal/lib/asn1/hash.c','../heimdal/lib/asn1/lex.c',
-       '../heimdal/lib/asn1/parse.c','../heimdal/lib/roken/emalloc.c',
+       '../heimdal/lib/asn1/hash.c','../heimdal/lib/asn1/lex.l',
+       '../heimdal/lib/asn1/parse.y','../heimdal/lib/roken/emalloc.c',
        '../heimdal/lib/roken/getarg.c','../heimdal/lib/roken/setprogname.c',
        '../heimdal/lib/roken/strupr.c','../heimdal/lib/roken/getprogname.c',
        '../heimdal/lib/roken/get_window_size.c','../heimdal/lib/roken/estrdup.c',
@@ -151,7 +111,7 @@ buildenv.Program('asn1_compile',
        'lib/replace/snprintf.c','lib/replace/replace.c'])
 
 buildenv.Program('compile_et',
-       ['../heimdal/lib/vers/print_version.c','../heimdal/lib/com_err/lex.c','../heimdal/lib/com_err/parse.c',
+       ['../heimdal/lib/vers/print_version.c','../heimdal/lib/com_err/lex.l','../heimdal/lib/com_err/parse.y',
        '../heimdal/lib/com_err/compile_et.c','../heimdal/lib/roken/getarg.c',
        '../heimdal/lib/roken/get_window_size.c','../heimdal/lib/roken/getprogname.c',
        '../heimdal/lib/roken/strupr.c','../heimdal/lib/roken/setprogname.c','heimdal_build/replace.c',
index 8833028dbd0135e727acd070956c97ff85387ef4..9c5631082907be70611a1cc01d100a2dea40a5ec 100644 (file)
@@ -21,5 +21,4 @@ hostenv.StaticLibrary('pidfile',['pidfile.c'])
 hostenv.StaticLibrary('unix_privs',['unix_privs.c'])
 
 SConscript(dirs=['replace','tdb','popt','cmdline','talloc','registry','charset', 'ldb','tls','samba3','socket','socket_wrapper','messaging','com','events',
-                  'appweb'],
-                  exports='hostenv')
+                  'appweb'])
index ca79116b6a43ece5e7f5a416be47579b46a09442..1149314d0b48d3e2925bc164df7816d9d92e8e7a 100644 (file)
@@ -167,7 +167,6 @@ static int do_reseed(BOOL use_fd, int fd)
        /* Add in some secret file contents */
 
        do_filehash("/etc/shadow", &seed_inbuf[0]);
-       do_filehash(lp_smb_passwd_file(), &seed_inbuf[16]);
 
        /*
         * Add the counter, time of day, and pid.
index 1ef1c5f9e6a3c92d412efaf5e84ec4994b56d48e..1079a441d8fe081bea4d951dbad471e89bcb71db 100644 (file)
@@ -9,6 +9,7 @@ hostenv.StaticLibrary('modules/ldb_map.c')
 
 conf = Configure(hostenv)
 have_sqlite3 = conf.CheckLibWithHeader("sqlite3","sqlite3.h",'c',"sqlite3_open()")
+have_popt = conf.CheckLibWithHeader("popt","popt.h",'c',"poptGetArgs(NULL);")
 conf.Finish()
 
 if have_sqlite3:
index 65aeb5b17a256fdd2cdb79246c35e24e2b2585f0..a90557532b8d039b8464bdd261fc92580d5a3187 100644 (file)
@@ -1,7 +1,12 @@
-Import('hostenv')
+Import('hostenv paths')
 #            tastes like -*- python -*-
 
 Import('talloc basic popt_common popt param')
 registry = hostenv.StaticLibrary('registry',
                        [basic,talloc,'common/reg_interface.c','common/reg_util.c'])
-hostenv.Program('regtree', ['tools/regtree.c',registry,talloc,basic,popt_common,popt,param])
+regtree = hostenv.Program('regtree', ['tools/regtree.c',registry,talloc,basic,popt_common,popt,param])
+regshell = hostenv.Program('regshell', ['tools/regshell.c',registry,talloc,basic,popt_common,popt,param])
+regpatch = hostenv.Program('regpatch', ['tools/regpatch.c',registry,talloc,basic,popt_common,popt,param])
+regdiff = hostenv.Program('regdiff', ['tools/regdiff.c',registry,talloc,basic,popt_common,popt,param])
+
+hostenv.Install(paths['BINDIR'], [regtree,regshell,regpatch,regdiff])
index 6ec9c338d368025e19d5f8735fe6a9f6356a05e7..ac9e0466b2f9270059eb8463119a161c9246cb9b 100644 (file)
@@ -1,2 +1,7 @@
 Import('hostenv')
 hostenv.StaticLibrary('socket_wrapper',['socket_wrapper.c'])
+
+opts = Options(None, ARGUMENTS)
+opts.AddOptions(
+       BoolOption('socket-wrapper','enable socket wrapper',0)
+)
index 6abcdff8218a4d09234e2420e844004c1eff6780..3b1a1d7d4ed6af14609cc916b1ea4b828442d4a5 100644 (file)
@@ -1,2 +1,6 @@
 Import('hostenv')
 hostenv.StaticLibrary('tls', ['tls.c', 'tlscert.c'])
+
+conf = hostenv.Configure()
+conf.CheckLibWithHeader('gnutls', 'gnutls/gnutls.h', 'c', 'gnutls_global_init()')
+conf.Finish()
index 8300f4598d34f1d3773d1c03ce50d39787bdd057..1ea1ac48cd90efe59f43f85960d5410cc29c903c 100644 (file)
@@ -117,7 +117,6 @@ typedef struct
        char *szPasswdChat;
        char *szLogFile;
        char *szConfigFile;
-       char *szSMBPasswdFile;
        char *szSAM_URL;
        char *szSPOOLSS_URL;
        char *szWINS_URL;
@@ -419,12 +418,10 @@ static struct parm_struct parm_table[] = {
        {"null passwords", P_BOOL, P_GLOBAL, &Globals.bNullPasswords, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"obey pam restrictions", P_BOOL, P_GLOBAL, &Globals.bObeyPamRestrictions, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"password server", P_LIST, P_GLOBAL, &Globals.szPasswordServers, NULL, NULL, FLAG_ADVANCED | FLAG_WIZARD | FLAG_DEVELOPER},
-       {"smb passwd file", P_STRING, P_GLOBAL, &Globals.szSMBPasswdFile, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"sam database", P_STRING, P_GLOBAL, &Globals.szSAM_URL, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"spoolss database", P_STRING, P_GLOBAL, &Globals.szSPOOLSS_URL, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"wins database", P_STRING, P_GLOBAL, &Globals.szWINS_URL, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"private dir", P_STRING, P_GLOBAL, &Globals.szPrivateDir, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
-       
        {"passwd chat", P_STRING, P_GLOBAL, &Globals.szPasswdChat, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"password level", P_INTEGER, P_GLOBAL, &Globals.pwordlevel, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
        {"lanman auth", P_BOOL, P_GLOBAL, &Globals.bLanmanAuth, NULL, NULL, FLAG_ADVANCED | FLAG_DEVELOPER},
@@ -614,7 +611,6 @@ static void init_globals(void)
        do_parameter("server services", "smb rpc nbt ldap cldap web kdc", NULL);
        do_parameter("ntptr providor", "simple_ldb", NULL);
        do_parameter("auth methods", "anonymous sam_ignoredomain", NULL);
-       do_parameter("smb passwd file", dyn_SMB_PASSWD_FILE, NULL);
        do_parameter("private dir", dyn_PRIVATE_DIR, NULL);
        do_parameter("sam database", "sam.ldb", NULL);
        do_parameter("spoolss database", "spoolss.ldb", NULL);
@@ -817,7 +813,6 @@ FN_GLOBAL_STRING(lp_unix_charset, &Globals.unix_charset)
 FN_GLOBAL_STRING(lp_display_charset, &Globals.display_charset)
 FN_GLOBAL_STRING(lp_logfile, &Globals.szLogFile)
 FN_GLOBAL_STRING(lp_configfile, &Globals.szConfigFile)
-FN_GLOBAL_STRING(lp_smb_passwd_file, &Globals.szSMBPasswdFile)
 FN_GLOBAL_STRING(lp_sam_url, &Globals.szSAM_URL)
 FN_GLOBAL_STRING(lp_spoolss_url, &Globals.szSPOOLSS_URL)
 FN_GLOBAL_STRING(lp_wins_url, &Globals.szWINS_URL)