From 7c96ca88c4e6fc5bd9b0c585b0700cc04e0f517c Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 15:23:26 +0100 Subject: Formatting fixes. (This used to be commit bc0fab89e325ebb6ab870b1c3f4b263c50631b70) --- source4/scripting/python/samba/provision.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source4') diff --git a/source4/scripting/python/samba/provision.py b/source4/scripting/python/samba/provision.py index d30eaf3d7f..3e88b68509 100644 --- a/source4/scripting/python/samba/provision.py +++ b/source4/scripting/python/samba/provision.py @@ -335,9 +335,9 @@ def setup_samdb_partitions(samdb_path, setup_path, message, lp, session_info, schemadn_ldb = ldap_backend if ldap_backend_type == "fedora-ds": - backend_modules = ["nsuniqueid","paged_searches"] + backend_modules = ["nsuniqueid", "paged_searches"] elif ldap_backend_type == "openldap": - backend_modules = ["normalise","entryuuid","paged_searches"] + backend_modules = ["normalise", "entryuuid", "paged_searches"] elif serverrole == "domain controller": backend_modules = ["repl_meta_data"] else: @@ -695,6 +695,7 @@ def setup_samdb(path, setup_path, session_info, credentials, lp, samdb.transaction_commit() return samdb + FILL_FULL = "FULL" FILL_NT4SYNC = "NT4SYNC" FILL_DRS = "DRS" -- cgit From a53beee0343e9fccc8f5b31fba1f293bdb6763da Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 15:40:42 +0100 Subject: Add static header for gencache. (This used to be commit 58c25657bf552a11e7c522602805ba961de94cf2) --- source4/lib/basic.mk | 6 +-- source4/lib/gencache/gencache.h | 94 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 95 insertions(+), 5 deletions(-) create mode 100644 source4/lib/gencache/gencache.h (limited to 'source4') diff --git a/source4/lib/basic.mk b/source4/lib/basic.mk index 8653779044..53eb0d038f 100644 --- a/source4/lib/basic.mk +++ b/source4/lib/basic.mk @@ -18,15 +18,11 @@ include tdr/config.mk include dbwrap/config.mk include crypto/config.mk -################################################ -# Start SUBSYSTEM LIBCOMPRESSION [SUBSYSTEM::LIBCOMPRESSION] OBJ_FILES = compression/mszip.o -# End SUBSYSTEM LIBCOMPRESION -################################################ [SUBSYSTEM::GENCACHE] -PRIVATE_PROTO_HEADER = gencache/gencache.h +PUBLIC_HEADERS = gencache/gencache.h OBJ_FILES = gencache/gencache.o PRIVATE_DEPENDENCIES = TDB_WRAP diff --git a/source4/lib/gencache/gencache.h b/source4/lib/gencache/gencache.h new file mode 100644 index 0000000000..1481676fd9 --- /dev/null +++ b/source4/lib/gencache/gencache.h @@ -0,0 +1,94 @@ +#ifndef __LIB_GENCACHE_GENCACHE_H__ +#define __LIB_GENCACHE_GENCACHE_H__ + +/** + * Cache initialisation function. Opens cache tdb file or creates + * it if does not exist. + * + * @return true on successful initialisation of the cache or + * false on failure + **/ +bool gencache_init(struct loadparm_context *lp_ctx); + +/** + * Cache shutdown function. Closes opened cache tdb file. + * + * @return true on successful closing the cache or + * false on failure during cache shutdown + **/ +bool gencache_shutdown(void); + +/** + * Set an entry in the cache file. If there's no such + * one, then add it. + * + * @param keystr string that represents a key of this entry + * @param value text representation value being cached + * @param timeout time when the value is expired + * + * @retval true when entry is successfuly stored + * @retval false on failure + **/ +bool gencache_set(const char *keystr, const char *value, time_t timeout); + +/** + * Set existing entry to the cache file. + * + * @param keystr string that represents a key of this entry + * @param valstr text representation value being cached + * @param timeout time when the value is expired + * + * @retval true when entry is successfuly set + * @retval false on failure + **/ +bool gencache_set_only(const char *keystr, const char *valstr, time_t timeout); + +/** + * Delete one entry from the cache file. + * + * @param keystr string that represents a key of this entry + * + * @retval true upon successful deletion + * @retval false in case of failure + **/ +bool gencache_del(const char *keystr); + +/** + * Get existing entry from the cache file. + * + * @param keystr string that represents a key of this entry + * @param valstr buffer that is allocated and filled with the entry value + * buffer's disposing must be done outside + * @param timeout pointer to a time_t that is filled with entry's + * timeout + * + * @retval true when entry is successfuly fetched + * @retval false for failure + **/ +bool gencache_get(const char *keystr, char **valstr, time_t *timeout); + +/** + * Iterate through all entries which key matches to specified pattern + * + * @param fn pointer to the function that will be supplied with each single + * matching cache entry (key, value and timeout) as an arguments + * @param data void pointer to an arbitrary data that is passed directly to the fn + * function on each call + * @param keystr_pattern pattern the existing entries' keys are matched to + * + **/ +void gencache_iterate(void (*fn)(const char* key, const char *value, time_t timeout, void* dptr), + void* data, const char* keystr_pattern); + +/******************************************************************** + lock a key +********************************************************************/ +int gencache_lock_entry( const char *key ); + +/******************************************************************** + unlock a key +********************************************************************/ +void gencache_unlock_entry( const char *key ); + +#endif /* __LIB_GENCACHE_GENCACHE_H__ */ + -- cgit From f5e94378967a3f5059fcf1fd09eaae68ef7ccfae Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 16:22:05 +0100 Subject: Simplify handling of plugin installation. (This used to be commit 8f1270dd5c7688f023cf24215fa229da213e760c) --- source4/Makefile | 4 ++++ source4/build/smb_build/makefile.pm | 29 ++++++++++++++++------------- 2 files changed, 20 insertions(+), 13 deletions(-) (limited to 'source4') diff --git a/source4/Makefile b/source4/Makefile index a99dc825f1..e5399e4c32 100644 --- a/source4/Makefile +++ b/source4/Makefile @@ -122,6 +122,8 @@ installbin:: $(SBIN_PROGS) $(BIN_PROGS) $(TORTURE_PROGS) installdirs $(DESTDIR)$(TORTUREDIR) \ $(TORTURE_PROGS) +installplugins:: + installlib:: $(INSTALLABLE_SHARED_LIBS) $(STATIC_LIBS) installdirs @$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(SHLIBEXT)" $(INSTALLABLE_SHARED_LIBS) #@$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(STLIBEXT)" $(STATIC_LIBS) @@ -165,6 +167,8 @@ uninstallheader:: uninstallman:: @$(SHELL) $(srcdir)/script/uninstallman.sh $(DESTDIR)$(mandir) $(MANPAGES) +uninstallplugins:: + config.status: @echo "config.status does not exist. Please run ./configure." @/bin/false diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 7fd31a5114..427828128a 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -32,8 +32,6 @@ sub new($$$) $self->{headers} = []; $self->{shared_modules} = []; $self->{plugins} = []; - $self->{install_plugins} = ""; - $self->{uninstall_plugins} = ""; $self->{pc_files} = []; $self->{proto_headers} = []; $self->{output} = ""; @@ -154,16 +152,24 @@ sub SharedModule($$) } else { push (@{$self->{shared_modules}}, "$ctx->{TARGET_SHARED_LIBRARY}"); push (@{$self->{plugins}}, "$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}"); - $self->{install_plugins} .= "\t\@echo Installing $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME} as \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"; - $self->{install_plugins} .= "\t\@mkdir -p \$(DESTDIR)\$(modulesdir)/$sane_subsystem/\n"; - $self->{install_plugins} .= "\t\@cp $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME} \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"; - $self->{uninstall_plugins} .= "\t\@echo Uninstalling \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"; - $self->{uninstall_plugins} .= "\t\@-rm \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"; + $self->output("installplugins:: $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}\n"); + $self->output("\t\@echo Installing $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME} as \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"); + $self->output("\t\@mkdir -p \$(DESTDIR)\$(modulesdir)/$sane_subsystem/\n"); + $self->output("\t\@cp $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME} \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"); if (defined($ctx->{ALIASES})) { foreach (@{$ctx->{ALIASES}}) { - $self->{install_plugins} .= "\t\@rm -f \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$_.\$(SHLIBEXT)\n"; - $self->{install_plugins} .= "\t\@ln -fs $ctx->{LIBRARY_REALNAME} \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$_.\$(SHLIBEXT)\n"; - $self->{uninstall_plugins} .= "\t\@-rm \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$_.\$(SHLIBEXT)\n"; + $self->output("\t\@rm -f \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$_.\$(SHLIBEXT)\n"); + $self->output("\t\@ln -fs $ctx->{LIBRARY_REALNAME} \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$_.\$(SHLIBEXT)\n"); + } + } + + $self->output("uninstallplugins::\n"); + $self->output("\t\@echo Uninstalling \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"); + $self->output("\t\@-rm \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"); + + if (defined($ctx->{ALIASES})) { + foreach (@{$ctx->{ALIASES}}) { + $self->output("\t\@-rm \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$_.\$(SHLIBEXT)\n"); } } } @@ -438,9 +444,6 @@ sub write($$) $self->output("SHARED_MODULES = " . array2oneperline($self->{shared_modules}) . "\n"); $self->output("PLUGINS = " . array2oneperline($self->{plugins}) . "\n"); - $self->output("\ninstallplugins: \$(PLUGINS)\n".$self->{install_plugins}."\n"); - $self->output("\nuninstallplugins:\n".$self->{uninstall_plugins}."\n"); - $self->_prepare_mk_files(); $self->output($self->{mkfile}); -- cgit From d803ff9e724cc91778c1b94a5b78ef935200adb8 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 16:33:04 +0100 Subject: Remove unused code. (This used to be commit 98d6095b9605ff4db61394719f29b3e38349c59f) --- source4/Makefile | 6 +++--- source4/build/smb_build/makefile.pm | 6 +----- 2 files changed, 4 insertions(+), 8 deletions(-) (limited to 'source4') diff --git a/source4/Makefile b/source4/Makefile index e5399e4c32..a2f0afc5f1 100644 --- a/source4/Makefile +++ b/source4/Makefile @@ -27,7 +27,7 @@ include data.mk DEFAULT_HEADERS = $(srcdir)/lib/util/dlinklist.h \ $(srcdir)/version.h -binaries:: $(BINARIES) +binaries:: libraries:: $(STATIC_LIBS) $(SHARED_LIBS) modules:: $(SHARED_MODULES) headers:: $(PUBLIC_HEADERS) $(DEFAULT_HEADERS) @@ -124,8 +124,8 @@ installbin:: $(SBIN_PROGS) $(BIN_PROGS) $(TORTURE_PROGS) installdirs installplugins:: -installlib:: $(INSTALLABLE_SHARED_LIBS) $(STATIC_LIBS) installdirs - @$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(SHLIBEXT)" $(INSTALLABLE_SHARED_LIBS) +installlib:: $(SHARED_LIBS) $(STATIC_LIBS) installdirs + @$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(SHLIBEXT)" $(SHARED_LIBS) #@$(SHELL) $(srcdir)/script/installlib.sh $(DESTDIR)$(libdir) "$(STLIBEXT)" $(STATIC_LIBS) installheader:: headers installdirs diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 427828128a..9c6d52cfef 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -28,7 +28,6 @@ sub new($$$) $self->{python_dsos} = []; $self->{python_pys} = []; $self->{shared_libs} = []; - $self->{installable_shared_libs} = []; $self->{headers} = []; $self->{shared_modules} = []; $self->{plugins} = []; @@ -243,7 +242,6 @@ sub SharedLibrary($$) my ($self,$ctx) = @_; push (@{$self->{shared_libs}}, "$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}") if (defined($ctx->{SO_VERSION})); - push (@{$self->{installable_shared_libs}}, "$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}") if (defined($ctx->{SO_VERSION})); $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); @@ -334,7 +332,7 @@ sub Binary($$) push (@{$self->{bin_progs}}, "$installdir/$ctx->{BINARY}"); } - push (@{$self->{binaries}}, "$localdir/$ctx->{BINARY}"); + $self->output("binaries:: $localdir/$ctx->{BINARY}\n"); $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); @@ -431,12 +429,10 @@ sub write($$) $self->output("MANPAGES = " . array2oneperline($self->{manpages})."\n"); $self->output("BIN_PROGS = " . array2oneperline($self->{bin_progs}) . "\n"); $self->output("SBIN_PROGS = " . array2oneperline($self->{sbin_progs}) . "\n"); - $self->output("BINARIES = " . array2oneperline($self->{binaries}) . "\n"); $self->output("STATIC_LIBS = " . array2oneperline($self->{static_libs}) . "\n"); $self->output("SHARED_LIBS = " . array2oneperline($self->{shared_libs}) . "\n"); $self->output("PYTHON_DSOS = " . array2oneperline($self->{python_dsos}) . "\n"); $self->output("PYTHON_PYS = " . array2oneperline($self->{python_pys}) . "\n"); - $self->output("INSTALLABLE_SHARED_LIBS = " . array2oneperline($self->{installable_shared_libs}) . "\n"); $self->output("PUBLIC_HEADERS = " . array2oneperline($self->{headers}) . "\n"); $self->output("PC_FILES = " . array2oneperline($self->{pc_files}) . "\n"); $self->output("ALL_OBJS = " . array2oneperline($self->{all_objs}) . "\n"); -- cgit From 8d7e2eb68c7c63ef36d24ce59953c20c2579aa5f Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 20:38:21 +0100 Subject: Reintroduce mergedobj support. (This used to be commit 1cf23c58411a9b8a9bb97016c27c10a218e73146) --- source4/build/smb_build/main.pl | 3 ++- source4/build/smb_build/makefile.pm | 18 ++++++++++++++++++ source4/build/smb_build/output.pm | 12 ++++++++++++ 3 files changed, 32 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index a85eab32de..4c09e32422 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -20,7 +20,7 @@ my $INPUT = {}; my $mkfile = smb_build::config_mk::run_config_mk($INPUT, $config::config{srcdir}, $config::config{builddir}, "main.mk"); my $subsys_output_type; -$subsys_output_type = ["STATIC_LIBRARY"]; +$subsys_output_type = ["MERGED_OBJ"]; my $library_output_type; if ($config::config{USESHARED} eq "true") { @@ -59,6 +59,7 @@ my $shared_libs_used = 0; foreach my $key (values %$OUTPUT) { next unless defined $key->{OUTPUT_TYPE}; + $mkenv->MergedObj($key) if grep(/MERGED_OBJ/, @{$key->{OUTPUT_TYPE}}); $mkenv->StaticLibrary($key) if grep(/STATIC_LIBRARY/, @{$key->{OUTPUT_TYPE}}); if (defined($key->{PC_FILE})) { push(@{$mkenv->{pc_files}}, "$key->{BASEDIR}/$key->{PC_FILE}"); diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 9c6d52cfef..6ea3b8d950 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -277,6 +277,24 @@ __EOD__ $self->output("\n"); } +sub MergedObj($$) +{ + my ($self, $ctx) = @_; + + $self->_prepare_list($ctx, "OBJ_LIST"); + $self->_prepare_list($ctx, "FULL_OBJ_LIST"); + push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); + $self->output(<< "__EOD__" +# +$ctx->{TARGET_MERGED_OBJ}: \$($ctx->{NAME}_FULL_OBJ_LIST) + \@echo Partially linking \$@ + \@mkdir -p bin/mergedobj + \@\$(LD) -r -o \$@ \$($ctx->{NAME}_FULL_OBJ_LIST) + +__EOD__ +); +} + sub StaticLibrary($$) { my ($self,$ctx) = @_; diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 4350370fbf..0ddb9e4efb 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -89,6 +89,17 @@ sub generate_shared_library($) $lib->{OUTPUT_SHARED_LIBRARY} = $lib->{TARGET_SHARED_LIBRARY}; } +sub generate_merged_obj($) +{ + my $lib = shift; + + my $link_name = $lib->{NAME}; + $link_name =~ s/^LIB//; + + $lib->{MERGED_OBJNAME} = lc($link_name).".o"; + $lib->{TARGET_MERGED_OBJ} = $lib->{OUTPUT_MERGED_OBJ} = "bin/mergedobj/$lib->{MERGED_OBJNAME}"; +} + sub generate_static_library($) { my $lib = shift; @@ -153,6 +164,7 @@ sub create_output($$) generate_binary($part) if grep(/BINARY/, @{$part->{OUTPUT_TYPE}}); generate_shared_library($part) if grep(/SHARED_LIBRARY/, @{$part->{OUTPUT_TYPE}}); generate_static_library($part) if grep(/STATIC_LIBRARY/, @{$part->{OUTPUT_TYPE}}); + generate_merged_obj($part) if grep(/MERGED_OBJ/, @{$part->{OUTPUT_TYPE}}); $part->{OUTPUT} = $part->{"OUTPUT_" . @{$part->{OUTPUT_TYPE}}[0]}; $part->{TARGET} = $part->{"TARGET_" . @{$part->{OUTPUT_TYPE}}[0]}; } -- cgit From f6dec9de4715892abab6cc9f75c2eb6c70f75947 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 20:48:08 +0100 Subject: Use standard variable for partial linking. (This used to be commit 949fca9540889bb640466fc21ca36d08f77066a3) --- source4/build/smb_build/input.pm | 1 + source4/build/smb_build/makefile.pm | 2 +- source4/rules.mk | 3 +++ 3 files changed, 5 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index 51c89a834f..02eafe2033 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -234,6 +234,7 @@ sub calc_unique_deps($$$$$$$$) if (defined ($dep->{OUTPUT_TYPE}) && ($withlibs or (@{$dep->{OUTPUT_TYPE}}[0] eq "INTEGRATED") or + (@{$dep->{OUTPUT_TYPE}}[0] eq "MERGED_OBJ") or (@{$dep->{OUTPUT_TYPE}}[0] eq "STATIC_LIBRARY"))) { push (@$busy, $dep->{NAME}); calc_unique_deps($dep->{NAME}, $INPUT, $dep->{PUBLIC_DEPENDENCIES}, $udeps, $withlibs, $forward, $pubonly, $busy); diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 6ea3b8d950..34092c69bd 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -289,7 +289,7 @@ sub MergedObj($$) $ctx->{TARGET_MERGED_OBJ}: \$($ctx->{NAME}_FULL_OBJ_LIST) \@echo Partially linking \$@ \@mkdir -p bin/mergedobj - \@\$(LD) -r -o \$@ \$($ctx->{NAME}_FULL_OBJ_LIST) + \$(PARTLINK) -o \$@ \$($ctx->{NAME}_FULL_OBJ_LIST) __EOD__ ); diff --git a/source4/rules.mk b/source4/rules.mk index 1ef751b00a..4e7841fa93 100644 --- a/source4/rules.mk +++ b/source4/rules.mk @@ -37,6 +37,9 @@ PCHCOMPILE = @$(CC) -Ilib/replace \ $(CFLAGS) `$(PERL) $(srcdir)/script/cflags.pl $@` \ $(PICFLAG) $(CPPFLAGS) -c $(FIRST_PREREQ) -o $@ +# Partial linking +PARTLINK = @$(PROG_LD) -r + include/config.h: @echo "include/config.h not present" @echo "You need to rerun ./autogen.sh and ./configure" -- cgit From fe5b7c4986b54985880fa8bc38248dab1cc5e9b0 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 20:56:46 +0100 Subject: Some more mergedobj fixes. (This used to be commit c481d88d37346885f7809f73035a2bc9f2468848) --- source4/build/smb_build/input.pm | 16 +++------------- source4/build/smb_build/makefile.pm | 1 + 2 files changed, 4 insertions(+), 13 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index 02eafe2033..825b033fb9 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -76,8 +76,6 @@ sub check_module($$$) die("Module $mod->{NAME} does not have a SUBSYSTEM set") if not defined($mod->{SUBSYSTEM}); - my $use_default = 0; - if (not exists($INPUT->{$mod->{SUBSYSTEM}}{INIT_FUNCTIONS})) { $INPUT->{$mod->{SUBSYSTEM}}{INIT_FUNCTIONS} = []; } @@ -126,9 +124,7 @@ sub check_library($$$) return if ($lib->{ENABLE} ne "YES"); - unless (defined($lib->{OUTPUT_TYPE})) { - $lib->{OUTPUT_TYPE} = $default_ot; - } + unless (defined($lib->{OUTPUT_TYPE})) { $lib->{OUTPUT_TYPE} = $default_ot; } if (defined($lib->{VERSION}) and not defined($lib->{SO_VERSION})) { print "$lib->{NAME}: Please specify SO_VERSION when specifying VERSION\n"; @@ -141,12 +137,8 @@ sub check_library($$$) } unless (defined($lib->{INIT_FUNCTION_TYPE})) { $lib->{INIT_FUNCTION_TYPE} = "NTSTATUS (*) (void)"; } - unless (defined($lib->{INIT_FUNCTION_SENTINEL})) { $lib->{INIT_FUNCTION_SENTINEL} = "NULL"; } - - unless(defined($lib->{INSTALLDIR})) { - $lib->{INSTALLDIR} = "LIBDIR"; - } + unless (defined($lib->{INSTALLDIR})) { $lib->{INSTALLDIR} = "LIBDIR"; } add_libreplace($lib); } @@ -281,9 +273,7 @@ sub check($$$$$) } } - foreach my $k (keys %$INPUT) { - my $part = $INPUT->{$k}; - + foreach my $part (values %$INPUT) { $part->{LINK_FLAGS} = []; $part->{FULL_OBJ_LIST} = ["\$($part->{NAME}_OBJ_LIST)"]; diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 34092c69bd..16b46ed343 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -281,6 +281,7 @@ sub MergedObj($$) { my ($self, $ctx) = @_; + $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); -- cgit From 0419da69d5a8ab606a49598692c050447e306663 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 16 Feb 2008 21:16:28 +0100 Subject: Prevent adding libreplace when not necessary. (This used to be commit 978eb6f1616122e13429b00268d03942afc41425) --- source4/build/smb_build/input.pm | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index 825b033fb9..ed584e185c 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -66,8 +66,6 @@ sub check_subsystem($$$) unless (defined($subsys->{INIT_FUNCTION_TYPE})) { $subsys->{INIT_FUNCTION_TYPE} = "NTSTATUS (*) (void)"; } unless (defined($subsys->{INIT_FUNCTION_SENTINEL})) { $subsys->{INIT_FUNCTION_SENTINEL} = "NULL"; } - - add_libreplace($subsys); } sub check_module($$$) @@ -111,11 +109,11 @@ sub check_module($$$) $sane_subsystem =~ s/^lib//; $mod->{INSTALLDIR} = "MODULESDIR/$sane_subsystem"; push (@{$mod->{PUBLIC_DEPENDENCIES}}, $mod->{SUBSYSTEM}); + add_libreplace($mod); } if (grep(/INTEGRATED/, @{$mod->{OUTPUT_TYPE}})) { push (@{$INPUT->{$mod->{SUBSYSTEM}}{INIT_FUNCTIONS}}, $mod->{INIT_FUNCTION}) if defined($mod->{INIT_FUNCTION}); } - add_libreplace($mod); } sub check_library($$$) -- cgit From e8cf95773df914e8d71dcc1ce713fe0cc723d946 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 11:50:07 +0100 Subject: Switch back to using static libraries for subsystems for now, since partial linking is still giving some problems. (This used to be commit 0d8ddae4964dc50e981e12b6a93235a50a0607ff) --- source4/build/smb_build/main.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index 4c09e32422..46a092d69f 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -20,7 +20,8 @@ my $INPUT = {}; my $mkfile = smb_build::config_mk::run_config_mk($INPUT, $config::config{srcdir}, $config::config{builddir}, "main.mk"); my $subsys_output_type; -$subsys_output_type = ["MERGED_OBJ"]; +#$subsys_output_type = ["MERGED_OBJ"]; +$subsys_output_type = ["STATIC_LIBRARY"]; my $library_output_type; if ($config::config{USESHARED} eq "true") { -- cgit From d7dc10468a2f14072a555154e65c87753f9e05cd Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 12:26:43 +0100 Subject: Eliminate duplicate variable. (This used to be commit f5b2b20cafc137604bc527ca6bb2bc8edab551e9) --- source4/Makefile | 2 +- source4/build/smb_build/makefile.pm | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) (limited to 'source4') diff --git a/source4/Makefile b/source4/Makefile index a2f0afc5f1..ea98b5e469 100644 --- a/source4/Makefile +++ b/source4/Makefile @@ -29,7 +29,7 @@ DEFAULT_HEADERS = $(srcdir)/lib/util/dlinklist.h \ binaries:: libraries:: $(STATIC_LIBS) $(SHARED_LIBS) -modules:: $(SHARED_MODULES) +modules:: $(PLUGINS) headers:: $(PUBLIC_HEADERS) $(DEFAULT_HEADERS) manpages:: $(MANPAGES) all:: showflags $(ALL_PREDEP) bin/asn1_compile bin/compile_et binaries modules pythonmods diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 16b46ed343..b7b56229f5 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -29,7 +29,6 @@ sub new($$$) $self->{python_pys} = []; $self->{shared_libs} = []; $self->{headers} = []; - $self->{shared_modules} = []; $self->{plugins} = []; $self->{pc_files} = []; $self->{proto_headers} = []; @@ -149,7 +148,6 @@ sub SharedModule($$) push (@{$self->{python_dsos}}, "$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}"); } else { - push (@{$self->{shared_modules}}, "$ctx->{TARGET_SHARED_LIBRARY}"); push (@{$self->{plugins}}, "$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}"); $self->output("installplugins:: $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}\n"); $self->output("\t\@echo Installing $ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME} as \$(DESTDIR)\$(modulesdir)/$sane_subsystem/$ctx->{LIBRARY_REALNAME}\n"); @@ -456,7 +454,6 @@ sub write($$) $self->output("PC_FILES = " . array2oneperline($self->{pc_files}) . "\n"); $self->output("ALL_OBJS = " . array2oneperline($self->{all_objs}) . "\n"); $self->output("PROTO_HEADERS = " . array2oneperline($self->{proto_headers}) . "\n"); - $self->output("SHARED_MODULES = " . array2oneperline($self->{shared_modules}) . "\n"); $self->output("PLUGINS = " . array2oneperline($self->{plugins}) . "\n"); $self->_prepare_mk_files(); -- cgit From e6514ceb2ffd7be93de483ed697cff47c9178864 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 12:35:39 +0100 Subject: Merge functions. (This used to be commit d318809f0db71f4a37033c3e9f0dce2ee5a69b07) --- source4/build/smb_build/makefile.pm | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index b7b56229f5..b84caa12d7 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -99,14 +99,12 @@ sub array2oneperline($) return $output; } -sub _prepare_list_ex($$$$$) +sub _prepare_list($$$) { - my ($self,$ctx,$var,$pre,$post) = @_; + my ($self,$ctx,$var) = @_; my @tmparr = (); - push(@tmparr, $pre) if defined($pre); push(@tmparr, @{$ctx->{$var}}) if defined($ctx->{$var}); - push(@tmparr, $post) if defined($post); my $tmplist = array2oneperline(\@tmparr); return if ($tmplist eq ""); @@ -114,13 +112,6 @@ sub _prepare_list_ex($$$$$) $self->output("$ctx->{NAME}_$var =$tmplist\n"); } -sub _prepare_list($$$) -{ - my ($self,$ctx,$var) = @_; - - $self->_prepare_list_ex($ctx, $var, undef, undef); -} - sub Integrated($$) { my ($self,$ctx) = @_; @@ -243,7 +234,6 @@ sub SharedLibrary($$) $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); -# $self->_prepare_list_ex($ctx, "LINK_FLAGS", "-Wl,--whole-archive", "-Wl,--no-whole-archive"); push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); -- cgit From 72642989e8863553b88185e5e33e602eb78d8516 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 12:45:27 +0100 Subject: Fix installation of gencache. (This used to be commit 96f073020fa6a5553222c7b05654d30fd13b5e69) --- source4/headermap.txt | 1 + 1 file changed, 1 insertion(+) (limited to 'source4') diff --git a/source4/headermap.txt b/source4/headermap.txt index acbe81328e..70ca92c01c 100644 --- a/source4/headermap.txt +++ b/source4/headermap.txt @@ -120,3 +120,4 @@ lib/util/wrap_xattr.h: wrap_xattr.h lib/events/events.h: events/events.h lib/events/events_internal.h: events/events_internal.h libcli/ldap/ldap_ndr.h: ldb/ldap_ndr.h +lib/gencache/gencache.h: gencache.h -- cgit From e5d7bd3821327b509ebf38232e8b972455829f88 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 13:10:30 +0100 Subject: Reenable partial linking (This used to be commit a7512fb059d5dcb6bf70418622206eec94153693) --- source4/build/smb_build/main.pl | 4 ++-- source4/heimdal_build/config.mk | 1 - source4/libcli/config.mk | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index 46a092d69f..ba25035ea5 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -20,8 +20,8 @@ my $INPUT = {}; my $mkfile = smb_build::config_mk::run_config_mk($INPUT, $config::config{srcdir}, $config::config{builddir}, "main.mk"); my $subsys_output_type; -#$subsys_output_type = ["MERGED_OBJ"]; -$subsys_output_type = ["STATIC_LIBRARY"]; +$subsys_output_type = ["MERGED_OBJ"]; +#$subsys_output_type = ["STATIC_LIBRARY"]; my $library_output_type; if ($config::config{USESHARED} eq "true") { diff --git a/source4/heimdal_build/config.mk b/source4/heimdal_build/config.mk index 604516ccf6..1e627967fb 100644 --- a/source4/heimdal_build/config.mk +++ b/source4/heimdal_build/config.mk @@ -412,7 +412,6 @@ OBJ_FILES = \ ../heimdal/lib/roken/estrdup.o \ ../heimdal/lib/roken/erealloc.o \ ../heimdal/lib/roken/simple_exec.o \ - ../heimdal/lib/roken/simple_exec.o \ ../heimdal/lib/roken/strcollect.o \ ../heimdal/lib/roken/rtbl.o \ replace.o diff --git a/source4/libcli/config.mk b/source4/libcli/config.mk index bd96d5e8f5..67620fac89 100644 --- a/source4/libcli/config.mk +++ b/source4/libcli/config.mk @@ -118,7 +118,7 @@ PUBLIC_DEPENDENCIES = LIBCLI_RAW LIBSAMBA-ERRORS LIBCLI_AUTH \ [SUBSYSTEM::LIBCLI_RAW] PRIVATE_PROTO_HEADER = raw/raw_proto.h PRIVATE_DEPENDENCIES = LIBCLI_COMPOSITE LP_RESOLVE gensec LIBCLI_RESOLVE LIBSECURITY LIBNDR -LDFLAGS = $(LIBCLI_SMB_COMPOSITE_OUTPUT) +#LDFLAGS = $(LIBCLI_SMB_COMPOSITE_OUTPUT) PUBLIC_DEPENDENCIES = samba-socket LIBPACKET gensec LIBCRYPTO CREDENTIALS OBJ_FILES = raw/rawfile.o \ raw/smb_signing.o \ -- cgit From 5e336bea1c68fafa97f67abf89c678d3cd7250b8 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 13:31:10 +0100 Subject: Add elements in the build system implicitly if they're unknown (so they can be regular make rules). (This used to be commit 1da14d5efe63b97719c81fcf4851c5b79609776b) --- source4/build/smb_build/input.pm | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index ed584e185c..f970d5b677 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -208,13 +208,26 @@ sub import_integrated($$) } } +sub add_implicit($$) +{ + my ($INPUT, $n) = @_; + + $INPUT->{$n} = { + TYPE => "MAKE_RULE", + NAME => $n, + TARGET => lc($n), + LIBS => "\$(".uc($n)."_LIBS)", + CFLAGS => "\$(".uc($n)."_CFLAG)" + }; +} + sub calc_unique_deps($$$$$$$$) { sub calc_unique_deps($$$$$$$$); my ($name, $INPUT, $deps, $udeps, $withlibs, $forward, $pubonly, $busy) = @_; foreach my $n (@$deps) { - die("Dependency unknown: $n (for $name)") unless (defined($INPUT->{$n})); + add_implicit($INPUT, $n) unless (defined($INPUT->{$n})); die("Recursive dependency: $n, list: " . join(',', @$busy)) if (grep (/^$n$/, @$busy)); next if (grep /^$n$/, @$udeps); my $dep = $INPUT->{$n}; -- cgit From 51b0a285f02e1bc6187e64514f3f59f546bbecc5 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 15:31:15 +0100 Subject: Avoid redetermining paths; use already stored values. (This used to be commit 0d223ddc39b7438dbce6716f1f00c29579a1f4c4) --- source4/build/smb_build/main.pl | 4 ++-- source4/build/smb_build/makefile.pm | 24 +++++++++--------------- source4/build/smb_build/output.pm | 18 +++++++++++------- source4/configure.ac | 4 ++-- source4/libcli/config.mk | 2 +- 5 files changed, 25 insertions(+), 27 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index ba25035ea5..46a092d69f 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -20,8 +20,8 @@ my $INPUT = {}; my $mkfile = smb_build::config_mk::run_config_mk($INPUT, $config::config{srcdir}, $config::config{builddir}, "main.mk"); my $subsys_output_type; -$subsys_output_type = ["MERGED_OBJ"]; -#$subsys_output_type = ["STATIC_LIBRARY"]; +#$subsys_output_type = ["MERGED_OBJ"]; +$subsys_output_type = ["STATIC_LIBRARY"]; my $library_output_type; if ($config::config{USESHARED} eq "true") { diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index b84caa12d7..dc9e1e9911 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -230,7 +230,7 @@ sub SharedLibrary($$) { my ($self,$ctx) = @_; - push (@{$self->{shared_libs}}, "$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}") if (defined($ctx->{SO_VERSION})); + push (@{$self->{shared_libs}}, $ctx->{RESULT_SHARED_LIBRARY}) if (defined($ctx->{SO_VERSION})); $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); @@ -252,8 +252,7 @@ sub SharedLibrary($$) $self->output(<< "__EOD__" # - -$ctx->{SHAREDDIR}/$ctx->{LIBRARY_REALNAME}: \$($ctx->{NAME}_DEPEND_LIST) \$($ctx->{NAME}_FULL_OBJ_LIST) +$ctx->{RESULT_SHARED_LIBRARY}: \$($ctx->{NAME}_DEPEND_LIST) \$($ctx->{NAME}_FULL_OBJ_LIST) \@echo Linking \$\@ \@mkdir -p $ctx->{SHAREDDIR} \@\$(SHLD) \$(SHLD_FLAGS) \$(INTERN_LDFLAGS) -o \$\@ \$(INSTALL_LINK_FLAGS) \\ @@ -275,7 +274,7 @@ sub MergedObj($$) push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); $self->output(<< "__EOD__" # -$ctx->{TARGET_MERGED_OBJ}: \$($ctx->{NAME}_FULL_OBJ_LIST) +$ctx->{RESULT_MERGED_OBJ}: \$($ctx->{NAME}_FULL_OBJ_LIST) \@echo Partially linking \$@ \@mkdir -p bin/mergedobj \$(PARTLINK) -o \$@ \$($ctx->{NAME}_FULL_OBJ_LIST) @@ -290,7 +289,7 @@ sub StaticLibrary($$) return unless (defined($ctx->{OBJ_FILES})); - push (@{$self->{static_libs}}, $ctx->{TARGET_STATIC_LIBRARY}) if ($ctx->{TYPE} eq "LIBRARY"); + push (@{$self->{static_libs}}, $ctx->{RESULT_STATIC_LIBRARY}) if ($ctx->{TYPE} eq "LIBRARY"); $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); $self->_prepare_list($ctx, "OBJ_LIST"); @@ -300,7 +299,7 @@ sub StaticLibrary($$) $self->output(<< "__EOD__" # -$ctx->{TARGET_STATIC_LIBRARY}: \$($ctx->{NAME}_FULL_OBJ_LIST) +$ctx->{RESULT_STATIC_LIBRARY}: \$($ctx->{NAME}_FULL_OBJ_LIST) \@echo Linking \$@ \@rm -f \$@ \@mkdir -p $ctx->{STATICDIR} @@ -323,23 +322,18 @@ sub Binary($$) { my ($self,$ctx) = @_; - my $installdir; my $extradir = ""; - my $localdir = "bin$extradir"; - - $installdir = "bin$extradir"; - push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); unless (defined($ctx->{INSTALLDIR})) { } elsif ($ctx->{INSTALLDIR} eq "SBINDIR") { - push (@{$self->{sbin_progs}}, "$installdir/$ctx->{BINARY}"); + push (@{$self->{sbin_progs}}, $ctx->{RESULT_BINARY}); } elsif ($ctx->{INSTALLDIR} eq "BINDIR") { - push (@{$self->{bin_progs}}, "$installdir/$ctx->{BINARY}"); + push (@{$self->{bin_progs}}, $ctx->{RESULT_BINARY}); } - $self->output("binaries:: $localdir/$ctx->{BINARY}\n"); + $self->output("binaries:: $ctx->{TARGET_BINARY}\n"); $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); @@ -347,7 +341,7 @@ sub Binary($$) $self->_prepare_list($ctx, "LINK_FLAGS"); $self->output(<< "__EOD__" -$installdir/$ctx->{BINARY}: \$($ctx->{NAME}_DEPEND_LIST) \$($ctx->{NAME}_FULL_OBJ_LIST) +$ctx->{RESULT_BINARY}: \$($ctx->{NAME}_DEPEND_LIST) \$($ctx->{NAME}_FULL_OBJ_LIST) \@echo Linking \$\@ __EOD__ ); diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 0ddb9e4efb..586ea121cb 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -85,8 +85,9 @@ sub generate_shared_library($) $lib->{LIBRARY_REALNAME} = "$lib->{LIBRARY_REALNAME}.\$($lib->{NAME}_VERSION)"; } - $lib->{TARGET_SHARED_LIBRARY} = "$lib->{SHAREDDIR}/$lib->{LIBRARY_REALNAME}"; - $lib->{OUTPUT_SHARED_LIBRARY} = $lib->{TARGET_SHARED_LIBRARY}; + $lib->{RESULT_SHARED_LIBRARY} = "$lib->{SHAREDDIR}/$lib->{LIBRARY_REALNAME}"; + $lib->{OUTPUT_SHARED_LIBRARY} = "-l$link_name"; + $lib->{TARGET_SHARED_LIBRARY} = $lib->{RESULT_SHARED_LIBRARY}; } sub generate_merged_obj($) @@ -97,7 +98,8 @@ sub generate_merged_obj($) $link_name =~ s/^LIB//; $lib->{MERGED_OBJNAME} = lc($link_name).".o"; - $lib->{TARGET_MERGED_OBJ} = $lib->{OUTPUT_MERGED_OBJ} = "bin/mergedobj/$lib->{MERGED_OBJNAME}"; + $lib->{RESULT_MERGED_OBJ} = $lib->{OUTPUT_MERGED_OBJ} = "bin/mergedobj/$lib->{MERGED_OBJNAME}"; + $lib->{TARGET_MERGED_OBJ} = $lib->{RESULT_MERGED_OBJ}; } sub generate_static_library($) @@ -113,11 +115,12 @@ sub generate_static_library($) $lib->{LIBRARY_NAME} = "lib".lc($link_name).".a"; if (defined($lib->{OBJ_FILES})) { - $lib->{TARGET_STATIC_LIBRARY} = "bin/static/$lib->{LIBRARY_NAME}"; + $lib->{RESULT_STATIC_LIBRARY} = "bin/static/$lib->{LIBRARY_NAME}"; + $lib->{TARGET_STATIC_LIBRARY} = $lib->{RESULT_STATIC_LIBRARY}; $lib->{STATICDIR} = 'bin/static'; $lib->{OUTPUT_STATIC_LIBRARY} = "-l".lc($link_name); } else { - $lib->{TARGET_STATIC_LIBRARY} = ""; + $lib->{RESULT_STATIC_LIBRARY} = ""; $lib->{OUTPUT_STATIC_LIBRARY} = ""; } } @@ -129,8 +132,9 @@ sub generate_binary($) $bin->{DEPEND_LIST} = []; push(@{$bin->{LINK_FLAGS}}, "\$($bin->{NAME}\_OBJ_LIST)"); - $bin->{DEBUGDIR} = "bin/"; - $bin->{TARGET_BINARY} = $bin->{OUTPUT_BINARY} = "$bin->{DEBUGDIR}/$bin->{NAME}"; + $bin->{DEBUGDIR} = "bin"; + $bin->{RESULT_BINARY} = $bin->{OUTPUT_BINARY} = "$bin->{DEBUGDIR}/$bin->{NAME}"; + $bin->{TARGET_BINARY} = $bin->{RESULT_BINARY}; $bin->{BINARY} = $bin->{NAME}; } diff --git a/source4/configure.ac b/source4/configure.ac index 17925dfa99..1c17126f4a 100644 --- a/source4/configure.ac +++ b/source4/configure.ac @@ -142,10 +142,10 @@ AC_SUBST(INTERN_LDFLAGS) AC_SUBST(INSTALL_LINK_FLAGS) if test $USESHARED = "true"; then - INTERN_LDFLAGS="-L\${builddir}/bin/shared" + INTERN_LDFLAGS="-L\${builddir}/bin/shared -L\${builddir}/bin/static" INSTALL_LINK_FLAGS="-Wl,-rpath-link,\${builddir}/bin/shared"; else - INTERN_LDFLAGS="-L\${builddir}/bin/static" + INTERN_LDFLAGS="-L\${builddir}/bin/static -L\${builddir}/bin/shared" fi builddir_headers="" diff --git a/source4/libcli/config.mk b/source4/libcli/config.mk index 67620fac89..bd96d5e8f5 100644 --- a/source4/libcli/config.mk +++ b/source4/libcli/config.mk @@ -118,7 +118,7 @@ PUBLIC_DEPENDENCIES = LIBCLI_RAW LIBSAMBA-ERRORS LIBCLI_AUTH \ [SUBSYSTEM::LIBCLI_RAW] PRIVATE_PROTO_HEADER = raw/raw_proto.h PRIVATE_DEPENDENCIES = LIBCLI_COMPOSITE LP_RESOLVE gensec LIBCLI_RESOLVE LIBSECURITY LIBNDR -#LDFLAGS = $(LIBCLI_SMB_COMPOSITE_OUTPUT) +LDFLAGS = $(LIBCLI_SMB_COMPOSITE_OUTPUT) PUBLIC_DEPENDENCIES = samba-socket LIBPACKET gensec LIBCRYPTO CREDENTIALS OBJ_FILES = raw/rawfile.o \ raw/smb_signing.o \ -- cgit From 80cbff3d011ad9264462812f57991ed0393b385e Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 16:02:33 +0100 Subject: Fix build with partial linking. (This used to be commit bfad9610c472e8d7e3656e19c8dbb6b85727dc13) --- source4/build/smb_build/main.pl | 3 +-- source4/build/smb_build/output.pm | 12 +++++++++--- source4/heimdal_build/config.mk | 13 ++++--------- source4/libcli/config.mk | 2 +- source4/nsswitch/config.mk | 3 ++- source4/param/config.mk | 5 +---- source4/smb_server/smb/config.mk | 1 - source4/smb_server/smb2/config.mk | 1 - 8 files changed, 18 insertions(+), 22 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index 46a092d69f..4c09e32422 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -20,8 +20,7 @@ my $INPUT = {}; my $mkfile = smb_build::config_mk::run_config_mk($INPUT, $config::config{srcdir}, $config::config{builddir}, "main.mk"); my $subsys_output_type; -#$subsys_output_type = ["MERGED_OBJ"]; -$subsys_output_type = ["STATIC_LIBRARY"]; +$subsys_output_type = ["MERGED_OBJ"]; my $library_output_type; if ($config::config{USESHARED} eq "true") { diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 586ea121cb..67b905ef55 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -97,9 +97,14 @@ sub generate_merged_obj($) my $link_name = $lib->{NAME}; $link_name =~ s/^LIB//; - $lib->{MERGED_OBJNAME} = lc($link_name).".o"; - $lib->{RESULT_MERGED_OBJ} = $lib->{OUTPUT_MERGED_OBJ} = "bin/mergedobj/$lib->{MERGED_OBJNAME}"; - $lib->{TARGET_MERGED_OBJ} = $lib->{RESULT_MERGED_OBJ}; + if (defined($lib->{OBJ_FILES})) { + $lib->{MERGED_OBJNAME} = lc($link_name).".o"; + $lib->{RESULT_MERGED_OBJ} = $lib->{OUTPUT_MERGED_OBJ} = "bin/mergedobj/$lib->{MERGED_OBJNAME}"; + $lib->{TARGET_MERGED_OBJ} = $lib->{RESULT_MERGED_OBJ}; + } else { + $lib->{TARGET_MERGED_OBJ} = ""; + $lib->{RESULT_MERGED_OBJ} = ""; + } } sub generate_static_library($) @@ -121,6 +126,7 @@ sub generate_static_library($) $lib->{OUTPUT_STATIC_LIBRARY} = "-l".lc($link_name); } else { $lib->{RESULT_STATIC_LIBRARY} = ""; + $lib->{TARGET_STATIC_LIBRARY} = ""; $lib->{OUTPUT_STATIC_LIBRARY} = ""; } } diff --git a/source4/heimdal_build/config.mk b/source4/heimdal_build/config.mk index 1e627967fb..b337fab2d0 100644 --- a/source4/heimdal_build/config.mk +++ b/source4/heimdal_build/config.mk @@ -15,8 +15,7 @@ OBJ_FILES = \ ../heimdal/kdc/digest.o \ ../heimdal/kdc/process.o \ ../heimdal/kdc/windc.o \ - ../heimdal/kdc/kx509.o \ - ../heimdal/lib/asn1/asn1_KRB5SignedPath.o + ../heimdal/kdc/kx509.o PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_KRB5 HEIMDAL_HDB HEIMDAL_HEIM_ASN1 HEIMDAL_DIGEST_ASN1 HEIMDAL_KX509_ASN1 PUBLIC_DEPENDENCIES = HEIMDAL_NTLM HEIMDAL_HCRYPTO # End SUBSYSTEM HEIMDAL_KDC @@ -31,9 +30,7 @@ PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_HCRYPTO HEIMDAL_KRB5 [SUBSYSTEM::HEIMDAL_HDB_KEYS] CFLAGS = -Iheimdal_build -Iheimdal/lib/hdb OBJ_FILES = \ - ../heimdal/lib/hdb/keys.o \ - ../heimdal/lib/hdb/asn1_Key.o \ - ../heimdal/lib/hdb/asn1_Salt.o + ../heimdal/lib/hdb/keys.o PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_HCRYPTO HEIMDAL_KRB5 ####################### @@ -278,9 +275,7 @@ OBJ_FILES = \ ../heimdal/lib/asn1/der_cmp.o \ ../heimdal/lib/asn1/extra.o \ ../heimdal/lib/asn1/timegm.o \ - ../heimdal/lib/asn1/asn1_err.o \ - ../heimdal/lib/asn1/asn1_krb5int32.o \ - ../heimdal/lib/asn1/asn1_krb5uint32.o + ../heimdal/lib/asn1/asn1_err.o PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_COM_ERR # End SUBSYSTEM HEIMDAL_KRB5 ####################### @@ -341,7 +336,7 @@ PRIVATE_DEPENDENCIES = \ HEIMDAL_CMS_ASN1 HEIMDAL_RFC2459_ASN1 \ HEIMDAL_OCSP_ASN1 HEIMDAL_PKCS8_ASN1 \ HEIMDAL_PKCS9_ASN1 HEIMDAL_PKCS12_ASN1 \ - HEIMDAL_PKINIT_ASN1 + HEIMDAL_PKINIT_ASN1 HEIMDAL_PKCS10_ASN1 OBJ_FILES = \ ../heimdal/lib/hx509/ca.o \ ../heimdal/lib/hx509/cert.o \ diff --git a/source4/libcli/config.mk b/source4/libcli/config.mk index bd96d5e8f5..67620fac89 100644 --- a/source4/libcli/config.mk +++ b/source4/libcli/config.mk @@ -118,7 +118,7 @@ PUBLIC_DEPENDENCIES = LIBCLI_RAW LIBSAMBA-ERRORS LIBCLI_AUTH \ [SUBSYSTEM::LIBCLI_RAW] PRIVATE_PROTO_HEADER = raw/raw_proto.h PRIVATE_DEPENDENCIES = LIBCLI_COMPOSITE LP_RESOLVE gensec LIBCLI_RESOLVE LIBSECURITY LIBNDR -LDFLAGS = $(LIBCLI_SMB_COMPOSITE_OUTPUT) +#LDFLAGS = $(LIBCLI_SMB_COMPOSITE_OUTPUT) PUBLIC_DEPENDENCIES = samba-socket LIBPACKET gensec LIBCRYPTO CREDENTIALS OBJ_FILES = raw/rawfile.o \ raw/smb_signing.o \ diff --git a/source4/nsswitch/config.mk b/source4/nsswitch/config.mk index 621939256c..e53e064272 100644 --- a/source4/nsswitch/config.mk +++ b/source4/nsswitch/config.mk @@ -10,7 +10,8 @@ OBJ_FILES = \ nsstest.o PRIVATE_DEPENDENCIES = \ LIBSAMBA-UTIL \ - LIBREPLACE_EXT + LIBREPLACE_EXT \ + LIBSAMBA-CONFIG # End BINARY nsstest ################################# diff --git a/source4/param/config.mk b/source4/param/config.mk index 8ded5f1a13..c3f50b13fe 100644 --- a/source4/param/config.mk +++ b/source4/param/config.mk @@ -1,7 +1,4 @@ -[LIBRARY::LIBSAMBA-CONFIG] -VERSION = 0.0.1 -SO_VERSION = 0 -PC_FILE = samba-config.pc +[SUBSYSTEM::LIBSAMBA-CONFIG] OBJ_FILES = loadparm.o \ params.o \ generic.o \ diff --git a/source4/smb_server/smb/config.mk b/source4/smb_server/smb/config.mk index ddadc29ddb..7927f295b9 100644 --- a/source4/smb_server/smb/config.mk +++ b/source4/smb_server/smb/config.mk @@ -16,6 +16,5 @@ OBJ_FILES = \ signing.o PUBLIC_DEPENDENCIES = \ ntvfs LIBPACKET CREDENTIALS -LDFLAGS = $(SMB_SERVER_OUTPUT) # End SUBSYSTEM SMB_PROTOCOL ####################### diff --git a/source4/smb_server/smb2/config.mk b/source4/smb_server/smb2/config.mk index b7d7cdc282..d5ba43b3a8 100644 --- a/source4/smb_server/smb2/config.mk +++ b/source4/smb_server/smb2/config.mk @@ -13,6 +13,5 @@ OBJ_FILES = \ keepalive.o PUBLIC_DEPENDENCIES = \ ntvfs LIBPACKET LIBCLI_SMB2 -LDFLAGS = $(SMB_SERVER_OUTPUT) # End SUBSYSTEM SMB2_PROTOCOL ####################### -- cgit From a44e0b245545597e4752e712446e6d8a3585648c Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 16:33:23 +0100 Subject: Simplify some more smb_build code. (This used to be commit 95b06bd8f2a91c9f3f9e9f05f7e2803d6b4100c7) --- source4/build/smb_build/input.pm | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index f970d5b677..f175b4c8c9 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -5,13 +5,10 @@ # Copyright (C) Jelmer Vernooij 2004 # Released under the GNU GPL -use smb_build::config; use strict; package smb_build::input; use File::Basename; -my $srcdir = $config::config{srcdir}; - sub strtrim($) { $_ = shift; @@ -60,10 +57,7 @@ sub check_subsystem($$$) my ($INPUT, $subsys, $default_ot) = @_; return if ($subsys->{ENABLE} ne "YES"); - unless(defined($subsys->{OUTPUT_TYPE})) { - $subsys->{OUTPUT_TYPE} = $default_ot; - } - + unless (defined($subsys->{OUTPUT_TYPE})) { $subsys->{OUTPUT_TYPE} = $default_ot; } unless (defined($subsys->{INIT_FUNCTION_TYPE})) { $subsys->{INIT_FUNCTION_TYPE} = "NTSTATUS (*) (void)"; } unless (defined($subsys->{INIT_FUNCTION_SENTINEL})) { $subsys->{INIT_FUNCTION_SENTINEL} = "NULL"; } } @@ -159,8 +153,8 @@ sub check_python($$$) $python->{OBJ_FILES} = ["$dirname$basename\_wrap.o"]; $python->{LIBRARY_REALNAME} = "_$basename.\$(SHLIBEXT)"; $python->{PYTHON_FILES} = ["$dirname$basename.py"]; - push (@{$python->{CFLAGS}}, $config::config{CFLAG_NO_UNUSED_MACROS}); - push (@{$python->{CFLAGS}}, $config::config{CFLAG_NO_CAST_QUAL}); + push (@{$python->{CFLAGS}}, "\$(CFLAG_NO_UNUSED_MACROS)"); + push (@{$python->{CFLAGS}}, "\$(CFLAG_NO_CAST_QUAL)"); $python->{INIT_FUNCTION} = "{ (char *)\"_$basename\", init_$basename }"; } else { my $basename = $python->{NAME}; -- cgit From 86be022079a1efe43604a263fa12aa73ef93efba Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 16:57:17 +0100 Subject: Remove mergedobj files during clean. (This used to be commit 78fb91ee672c15c7575e8f9db84c0524318bf8bd) --- source4/rules.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/rules.mk b/source4/rules.mk index 4e7841fa93..b6a54fae25 100644 --- a/source4/rules.mk +++ b/source4/rules.mk @@ -66,7 +66,7 @@ clean:: clean_pch @-rm -f $(BIN_PROGS) $(SBIN_PROGS) $(BINARIES) $(TORTURE_PROGS) @echo Removing libraries @-rm -f $(STATIC_LIBRARIES) $(SHARED_LIBRARIES) - @-rm -f bin/static/*.a bin/shared/*.$(SHLIBEXT) + @-rm -f bin/static/*.a bin/shared/*.$(SHLIBEXT) bin/mergedobj/*.o @echo Removing modules @-rm -f bin/modules/*/*.$(SHLIBEXT) @-rm -f bin/*_init_module.c -- cgit From 7dd064fcd9c41f19d43abaa9d994224b0e215edb Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 17:08:54 +0100 Subject: Factor out common code that generates object lists. (This used to be commit ef14e1ab3267263d65c4c41cd3c0dab3680f4104) --- source4/build/smb_build/main.pl | 7 ++----- source4/build/smb_build/makefile.pm | 12 ------------ source4/build/smb_build/output.pm | 2 +- 3 files changed, 3 insertions(+), 18 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index 4c09e32422..d4d18a5cb9 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -48,14 +48,11 @@ $config::config{LIBRARY_OUTPUT_TYPE} = $library_output_type; $config::config{MODULE_OUTPUT_TYPE} = $module_output_type; my $mkenv = new smb_build::makefile(\%config::config, $mkfile); +my $shared_libs_used = 0; foreach my $key (values %$OUTPUT) { - next unless defined $key->{OUTPUT_TYPE}; - - $mkenv->Integrated($key) if grep(/INTEGRATED/, @{$key->{OUTPUT_TYPE}}); + $mkenv->_prepare_list($key, "OBJ_LIST"); } -my $shared_libs_used = 0; - foreach my $key (values %$OUTPUT) { next unless defined $key->{OUTPUT_TYPE}; diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index dc9e1e9911..b06279ed10 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -112,13 +112,6 @@ sub _prepare_list($$$) $self->output("$ctx->{NAME}_$var =$tmplist\n"); } -sub Integrated($$) -{ - my ($self,$ctx) = @_; - - $self->_prepare_list($ctx, "OBJ_LIST"); -} - sub SharedModulePrimitives($$) { my ($self,$ctx) = @_; @@ -163,7 +156,6 @@ sub SharedModule($$) } $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); - $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); @@ -221,7 +213,6 @@ sub SharedLibraryPrimitives($$) if (not grep(/STATIC_LIBRARY/, @{$ctx->{OUTPUT_TYPE}})) { $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); - $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); } } @@ -269,7 +260,6 @@ sub MergedObj($$) my ($self, $ctx) = @_; $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); - $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); $self->output(<< "__EOD__" @@ -292,7 +282,6 @@ sub StaticLibrary($$) push (@{$self->{static_libs}}, $ctx->{RESULT_STATIC_LIBRARY}) if ($ctx->{TYPE} eq "LIBRARY"); $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); - $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); @@ -335,7 +324,6 @@ sub Binary($$) $self->output("binaries:: $ctx->{TARGET_BINARY}\n"); - $self->_prepare_list($ctx, "OBJ_LIST"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 67b905ef55..33493eca2c 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -201,7 +201,7 @@ sub create_output($$) push(@{$part->{LINK_FLAGS}}, "\$($elem->{NAME}_OUTPUT)") if defined($elem->{OUTPUT}); push(@{$part->{LINK_FLAGS}}, @{$elem->{LIBS}}) if defined($elem->{LIBS}); push(@{$part->{LINK_FLAGS}},@{$elem->{LDFLAGS}}) if defined($elem->{LDFLAGS}); - push(@{$part->{DEPEND_LIST}}, $elem->{TARGET}) if defined($elem->{TARGET}); + push(@{$part->{DEPEND_LIST}}, $elem->{TARGET}) if defined($elem->{TARGET}); } } -- cgit From 3f63d2fe4d3dc02d98e8b025c0992316f34be7c6 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 17:24:29 +0100 Subject: Fix unresolved symbols. (This used to be commit dbcecb6d8fe3e13cc4da003adeda7623b746b751) --- source4/heimdal_build/config.mk | 3 ++- source4/kdc/config.mk | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) (limited to 'source4') diff --git a/source4/heimdal_build/config.mk b/source4/heimdal_build/config.mk index b337fab2d0..b68fe84f90 100644 --- a/source4/heimdal_build/config.mk +++ b/source4/heimdal_build/config.mk @@ -31,7 +31,8 @@ PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_HCRYPTO HEIMDAL_KRB5 CFLAGS = -Iheimdal_build -Iheimdal/lib/hdb OBJ_FILES = \ ../heimdal/lib/hdb/keys.o -PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_HCRYPTO HEIMDAL_KRB5 +PRIVATE_DEPENDENCIES = HEIMDAL_ROKEN HEIMDAL_HCRYPTO HEIMDAL_KRB5 \ + HEIMDAL_HDB_ASN1 ####################### # Start SUBSYSTEM HEIMDAL_HDB diff --git a/source4/kdc/config.mk b/source4/kdc/config.mk index c787343515..479cb36296 100644 --- a/source4/kdc/config.mk +++ b/source4/kdc/config.mk @@ -22,7 +22,8 @@ OBJ_FILES = \ hdb-ldb.o \ pac-glue.o PRIVATE_DEPENDENCIES = \ - LIBLDB auth_sam auth_sam_reply KERBEROS CREDENTIALS + LIBLDB auth_sam auth_sam_reply KERBEROS CREDENTIALS \ + HEIMDAL_HDB_ASN1 # End SUBSYSTEM KDC ####################### -- cgit From 5022db874b93f896f6e828f762f65a5d41619d61 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 17:28:24 +0100 Subject: Simplify handling of ALL_OBJS. (This used to be commit 5512c61d75d1a5404d58ba777720e62089bf45a1) --- source4/build/smb_build/main.pl | 1 + source4/build/smb_build/makefile.pm | 9 --------- 2 files changed, 1 insertion(+), 9 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index d4d18a5cb9..375962bde9 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -51,6 +51,7 @@ my $mkenv = new smb_build::makefile(\%config::config, $mkfile); my $shared_libs_used = 0; foreach my $key (values %$OUTPUT) { $mkenv->_prepare_list($key, "OBJ_LIST"); + push(@{$mkenv->{all_objs}}, "\$($key->{NAME}_OBJ_LIST)"); } foreach my $key (values %$OUTPUT) { diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index b06279ed10..52149083b1 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -160,8 +160,6 @@ sub SharedModule($$) $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); - push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); - if (defined($ctx->{INIT_FUNCTION}) and $ctx->{TYPE} ne "PYTHON") { my $init_fn = $ctx->{INIT_FUNCTION_TYPE}; $init_fn =~ s/\(\*\)/init_module/; @@ -226,8 +224,6 @@ sub SharedLibrary($$) $self->_prepare_list($ctx, "DEPEND_LIST"); $self->_prepare_list($ctx, "LINK_FLAGS"); - push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); - my $soarg = ""; my $lns = ""; if ($self->{config}->{SONAMEFLAG} ne "#" and defined($ctx->{LIBRARY_SONAME})) { @@ -261,7 +257,6 @@ sub MergedObj($$) $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); - push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); $self->output(<< "__EOD__" # $ctx->{RESULT_MERGED_OBJ}: \$($ctx->{NAME}_FULL_OBJ_LIST) @@ -284,8 +279,6 @@ sub StaticLibrary($$) $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); $self->_prepare_list($ctx, "FULL_OBJ_LIST"); - push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); - $self->output(<< "__EOD__" # $ctx->{RESULT_STATIC_LIBRARY}: \$($ctx->{NAME}_FULL_OBJ_LIST) @@ -313,8 +306,6 @@ sub Binary($$) my $extradir = ""; - push(@{$self->{all_objs}}, "\$($ctx->{NAME}_FULL_OBJ_LIST)"); - unless (defined($ctx->{INSTALLDIR})) { } elsif ($ctx->{INSTALLDIR} eq "SBINDIR") { push (@{$self->{sbin_progs}}, $ctx->{RESULT_BINARY}); -- cgit From 6e0522c3cae9c99b589db67727ee1256c6da82ef Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 18:55:37 +0100 Subject: Build complete static libraries. (This used to be commit 34e26f4eecdf5bca340133942b242969c4c16dff) --- source4/build/smb_build/dot.pl | 2 +- source4/build/smb_build/input.pm | 26 ++------------------------ source4/build/smb_build/main.pl | 8 ++------ source4/build/smb_build/makefile.pm | 7 ++++--- source4/build/smb_build/output.pm | 12 ++++++++---- 5 files changed, 17 insertions(+), 38 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/dot.pl b/source4/build/smb_build/dot.pl index 82f89c081a..e50ee50f95 100755 --- a/source4/build/smb_build/dot.pl +++ b/source4/build/smb_build/dot.pl @@ -44,7 +44,7 @@ my $name = "samba4"; my $only; if (defined($subsys)) { my $DEPEND = smb_build::input::check($INPUT, \%config::enabled, - "STATIC_LIBRARY", "SHARED_LIBRARY", "SHARED_LIBRARY"); + "MERGED_OBJ", "SHARED_LIBRARY", "SHARED_LIBRARY"); die("No such subsystem $subsys") unless (defined($DEPEND->{$subsys})); diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index f175b4c8c9..95902dfcbf 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -105,8 +105,9 @@ sub check_module($$$) push (@{$mod->{PUBLIC_DEPENDENCIES}}, $mod->{SUBSYSTEM}); add_libreplace($mod); } - if (grep(/INTEGRATED/, @{$mod->{OUTPUT_TYPE}})) { + if (grep(/MERGED_OBJ/, @{$mod->{OUTPUT_TYPE}})) { push (@{$INPUT->{$mod->{SUBSYSTEM}}{INIT_FUNCTIONS}}, $mod->{INIT_FUNCTION}) if defined($mod->{INIT_FUNCTION}); + unshift (@{$INPUT->{$mod->{SUBSYSTEM}}{PRIVATE_DEPENDENCIES}}, $mod->{NAME}); } } @@ -181,27 +182,6 @@ sub check_binary($$) add_libreplace($bin); } -sub import_integrated($$) -{ - my ($lib, $depend) = @_; - - foreach my $mod (values %$depend) { - next if(not defined($mod->{OUTPUT_TYPE})); - next if(not grep(/INTEGRATED/, @{$mod->{OUTPUT_TYPE}})); - next if(not defined($mod->{SUBSYSTEM})); - next if($mod->{SUBSYSTEM} ne $lib->{NAME}); - next if($mod->{ENABLE} ne "YES"); - - push (@{$lib->{FULL_OBJ_LIST}}, "\$($mod->{NAME}_OBJ_LIST)"); - push (@{$lib->{LINK_FLAGS}}, "\$($mod->{NAME}_LINK_FLAGS)"); - push (@{$lib->{CFLAGS}}, @{$mod->{CFLAGS}}) if defined($mod->{CFLAGS}); - push (@{$lib->{PUBLIC_DEPENDENCIES}}, @{$mod->{PUBLIC_DEPENDENCIES}}) if defined($mod->{PUBLIC_DEPENDENCIES}); - push (@{$lib->{PRIVATE_DEPENDENCIES}}, @{$mod->{PRIVATE_DEPENDENCIES}}) if defined($mod->{PRIVATE_DEPENDENCIES}); - - $mod->{ENABLE} = "NO"; - } -} - sub add_implicit($$) { my ($INPUT, $n) = @_; @@ -230,7 +210,6 @@ sub calc_unique_deps($$$$$$$$) if (defined ($dep->{OUTPUT_TYPE}) && ($withlibs or - (@{$dep->{OUTPUT_TYPE}}[0] eq "INTEGRATED") or (@{$dep->{OUTPUT_TYPE}}[0] eq "MERGED_OBJ") or (@{$dep->{OUTPUT_TYPE}}[0] eq "STATIC_LIBRARY"))) { push (@$busy, $dep->{NAME}); @@ -302,7 +281,6 @@ sub check($$$$$) if (defined($part->{INIT_FUNCTIONS})) { push (@{$part->{LINK_FLAGS}}, "\$(DYNEXP)"); } - import_integrated($part, $INPUT); } foreach my $part (values %$INPUT) { diff --git a/source4/build/smb_build/main.pl b/source4/build/smb_build/main.pl index 375962bde9..3ed0327d6d 100644 --- a/source4/build/smb_build/main.pl +++ b/source4/build/smb_build/main.pl @@ -19,8 +19,7 @@ use strict; my $INPUT = {}; my $mkfile = smb_build::config_mk::run_config_mk($INPUT, $config::config{srcdir}, $config::config{builddir}, "main.mk"); -my $subsys_output_type; -$subsys_output_type = ["MERGED_OBJ"]; +my $subsys_output_type = ["MERGED_OBJ"]; my $library_output_type; if ($config::config{USESHARED} eq "true") { @@ -35,7 +34,7 @@ my $module_output_type; if ($config::config{USESHARED} eq "true") { $module_output_type = ["SHARED_LIBRARY"]; } else { - $module_output_type = ["INTEGRATED"]; + $module_output_type = ["MERGED_OBJ"]; } my $DEPEND = smb_build::input::check($INPUT, \%config::enabled, @@ -43,9 +42,6 @@ my $DEPEND = smb_build::input::check($INPUT, \%config::enabled, $library_output_type, $module_output_type); my $OUTPUT = output::create_output($DEPEND, \%config::config); -$config::config{SUBSYSTEM_OUTPUT_TYPE} = $subsys_output_type; -$config::config{LIBRARY_OUTPUT_TYPE} = $library_output_type; -$config::config{MODULE_OUTPUT_TYPE} = $module_output_type; my $mkenv = new smb_build::makefile(\%config::config, $mkfile); my $shared_libs_used = 0; diff --git a/source4/build/smb_build/makefile.pm b/source4/build/smb_build/makefile.pm index 52149083b1..d11e761ce1 100644 --- a/source4/build/smb_build/makefile.pm +++ b/source4/build/smb_build/makefile.pm @@ -255,14 +255,15 @@ sub MergedObj($$) { my ($self, $ctx) = @_; + return unless defined($ctx->{OUTPUT}); + $self->output("$ctx->{NAME}_OUTPUT = $ctx->{OUTPUT}\n"); - $self->_prepare_list($ctx, "FULL_OBJ_LIST"); $self->output(<< "__EOD__" # -$ctx->{RESULT_MERGED_OBJ}: \$($ctx->{NAME}_FULL_OBJ_LIST) +$ctx->{RESULT_MERGED_OBJ}: \$($ctx->{NAME}_OBJ_LIST) \@echo Partially linking \$@ \@mkdir -p bin/mergedobj - \$(PARTLINK) -o \$@ \$($ctx->{NAME}_FULL_OBJ_LIST) + \$(PARTLINK) -o \$@ \$($ctx->{NAME}_OBJ_LIST) __EOD__ ); diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 33493eca2c..3d5f4466ca 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -136,7 +136,7 @@ sub generate_binary($) my $bin = shift; $bin->{DEPEND_LIST} = []; - push(@{$bin->{LINK_FLAGS}}, "\$($bin->{NAME}\_OBJ_LIST)"); + push(@{$bin->{LINK_FLAGS}}, "\$($bin->{NAME}\_FULL_OBJ_LIST)"); $bin->{DEBUGDIR} = "bin"; $bin->{RESULT_BINARY} = $bin->{OUTPUT_BINARY} = "$bin->{DEBUGDIR}/$bin->{NAME}"; @@ -198,10 +198,14 @@ sub create_output($$) my $elem = $depend->{$_}; next if $elem == $part; - push(@{$part->{LINK_FLAGS}}, "\$($elem->{NAME}_OUTPUT)") if defined($elem->{OUTPUT}); push(@{$part->{LINK_FLAGS}}, @{$elem->{LIBS}}) if defined($elem->{LIBS}); - push(@{$part->{LINK_FLAGS}},@{$elem->{LDFLAGS}}) if defined($elem->{LDFLAGS}); - push(@{$part->{DEPEND_LIST}}, $elem->{TARGET}) if defined($elem->{TARGET}); + push(@{$part->{LINK_FLAGS}}, @{$elem->{LDFLAGS}}) if defined($elem->{LDFLAGS}); + if (defined($elem->{OUTPUT_TYPE}) and @{$elem->{OUTPUT_TYPE}}[0] eq "MERGED_OBJ") { + push (@{$part->{FULL_OBJ_LIST}}, $elem->{TARGET}); + } else { + push(@{$part->{LINK_FLAGS}}, "\$($elem->{NAME}_OUTPUT)") if defined($elem->{OUTPUT}); + push(@{$part->{DEPEND_LIST}}, $elem->{TARGET}) if defined($elem->{TARGET}); + } } } -- cgit From 602f4635da0935abffdda2a29ec302a775fdbe62 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 19:06:17 +0100 Subject: Get rid of 'INTEGRATED' build of modules - now replaced by 'MERGED_OBJ' (This used to be commit 269cbf84d8b7dbf3bc88adc04ae283dc908af5ac) --- source4/auth/gensec/config.mk | 2 +- source4/auth/ntlmssp/config.mk | 2 +- source4/build/smb_build/input.pm | 4 ++-- source4/lib/socket/config.mk | 4 ++-- source4/ntvfs/posix/config.mk | 2 +- source4/rpc_server/config.mk | 4 ++-- source4/scripting/ejs/config.mk | 20 ++++++++++---------- source4/torture/config.mk | 2 +- 8 files changed, 20 insertions(+), 20 deletions(-) (limited to 'source4') diff --git a/source4/auth/gensec/config.mk b/source4/auth/gensec/config.mk index a53dff8bfe..9aab2c704e 100644 --- a/source4/auth/gensec/config.mk +++ b/source4/auth/gensec/config.mk @@ -62,7 +62,7 @@ INIT_FUNCTION = gensec_schannel_init OBJ_FILES = schannel.o \ schannel_sign.o PRIVATE_DEPENDENCIES = SCHANNELDB NDR_SCHANNEL CREDENTIALS LIBNDR -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ # End MODULE gensec_schannel ################################################ diff --git a/source4/auth/ntlmssp/config.mk b/source4/auth/ntlmssp/config.mk index 544850264a..9033384b1f 100644 --- a/source4/auth/ntlmssp/config.mk +++ b/source4/auth/ntlmssp/config.mk @@ -13,6 +13,6 @@ OBJ_FILES = ntlmssp.o \ ntlmssp_client.o \ ntlmssp_server.o PRIVATE_DEPENDENCIES = MSRPC_PARSE CREDENTIALS -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ # End MODULE gensec_ntlmssp ################################################ diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index 95902dfcbf..9cc374fa79 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -73,11 +73,11 @@ sub check_module($$$) } if (!(defined($INPUT->{$mod->{SUBSYSTEM}}))) { - $mod->{ENABLE} = "NO"; - return; + die("Unknown subsystem $mod->{SUBSYSTEM} for module $mod->{NAME}"); } if ($INPUT->{$mod->{SUBSYSTEM}} eq "NO") { + warn("Disabling module $mod->{NAME} because subsystem $mod->{SUBSYSTEM} is disabled"); $mod->{ENABLE} = "NO"; return; } diff --git a/source4/lib/socket/config.mk b/source4/lib/socket/config.mk index fe64c90b81..5a7a62d8ae 100644 --- a/source4/lib/socket/config.mk +++ b/source4/lib/socket/config.mk @@ -13,7 +13,7 @@ PRIVATE_DEPENDENCIES = LIBSAMBA-UTIL EXT_SOCKET EXT_NSL # Start MODULE socket_ip [MODULE::socket_ip] SUBSYSTEM = samba-socket -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ OBJ_FILES = \ socket_ip.o PRIVATE_DEPENDENCIES = EXT_SOCKET EXT_NSL LIBSAMBA-ERRORS @@ -24,7 +24,7 @@ PRIVATE_DEPENDENCIES = EXT_SOCKET EXT_NSL LIBSAMBA-ERRORS # Start MODULE socket_unix [MODULE::socket_unix] SUBSYSTEM = samba-socket -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ OBJ_FILES = \ socket_unix.o PRIVATE_DEPENDENCIES = EXT_SOCKET EXT_NSL diff --git a/source4/ntvfs/posix/config.mk b/source4/ntvfs/posix/config.mk index 6588be11ae..6879940337 100644 --- a/source4/ntvfs/posix/config.mk +++ b/source4/ntvfs/posix/config.mk @@ -31,7 +31,7 @@ PRIVATE_DEPENDENCIES = LIBAIO_LINUX # Start MODULE ntvfs_posix [MODULE::ntvfs_posix] SUBSYSTEM = ntvfs -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = ntvfs_posix_init PRIVATE_PROTO_HEADER = vfs_posix_proto.h OBJ_FILES = \ diff --git a/source4/rpc_server/config.mk b/source4/rpc_server/config.mk index d794b9470d..0032a867d1 100644 --- a/source4/rpc_server/config.mk +++ b/source4/rpc_server/config.mk @@ -108,7 +108,7 @@ PRIVATE_DEPENDENCIES = \ [MODULE::dcerpc_winreg] INIT_FUNCTION = dcerpc_server_winreg_init SUBSYSTEM = dcerpc_server -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ OBJ_FILES = \ winreg/rpc_winreg.o PRIVATE_DEPENDENCIES = \ @@ -155,7 +155,7 @@ PRIVATE_DEPENDENCIES = \ [MODULE::dcerpc_spoolss] INIT_FUNCTION = dcerpc_server_spoolss_init SUBSYSTEM = dcerpc_server -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ OBJ_FILES = \ spoolss/dcesrv_spoolss.o PRIVATE_DEPENDENCIES = \ diff --git a/source4/scripting/ejs/config.mk b/source4/scripting/ejs/config.mk index 5de17263b7..f99f37ecad 100644 --- a/source4/scripting/ejs/config.mk +++ b/source4/scripting/ejs/config.mk @@ -4,13 +4,13 @@ OBJ_FILES = \ [MODULE::smbcalls_config] OBJ_FILES = smbcalls_config.o -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_config [MODULE::smbcalls_ldb] OBJ_FILES = smbcalls_ldb.o -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_ldb PRIVATE_DEPENDENCIES = LIBLDB SAMDB LIBNDR @@ -18,38 +18,38 @@ PRIVATE_DEPENDENCIES = LIBLDB SAMDB LIBNDR [MODULE::smbcalls_reg] OBJ_FILES = smbcalls_reg.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_reg PRIVATE_DEPENDENCIES = registry SAMDB LIBNDR [MODULE::smbcalls_nbt] OBJ_FILES = smbcalls_nbt.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_nbt [MODULE::smbcalls_rand] OBJ_FILES = smbcalls_rand.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_random [MODULE::smbcalls_nss] OBJ_FILES = smbcalls_nss.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_nss PRIVATE_DEPENDENCIES = NSS_WRAPPER [MODULE::smbcalls_data] OBJ_FILES = smbcalls_data.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_datablob [MODULE::smbcalls_auth] OBJ_FILES = smbcalls_auth.o -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = smbcalls INIT_FUNCTION = smb_setup_ejs_auth PRIVATE_DEPENDENCIES = auth @@ -57,13 +57,13 @@ PRIVATE_DEPENDENCIES = auth [MODULE::smbcalls_string] OBJ_FILES = smbcalls_string.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_string [MODULE::smbcalls_sys] OBJ_FILES = smbcalls_sys.o SUBSYSTEM = smbcalls -OUTPUT_TYPE = INTEGRATED +OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_system include ejsnet/config.mk diff --git a/source4/torture/config.mk b/source4/torture/config.mk index 7ab4658dc1..a11b94b639 100644 --- a/source4/torture/config.mk +++ b/source4/torture/config.mk @@ -113,7 +113,7 @@ OBJ_FILES = ndr/ndr.o \ [MODULE::torture_rpc] # TORTURE_NET and TORTURE_NBT use functions from torture_rpc... -#OUTPUT_TYPE = INTEGRATED +#OUTPUT_TYPE = MERGED_OBJ SUBSYSTEM = torture INIT_FUNCTION = torture_rpc_init PRIVATE_PROTO_HEADER = \ -- cgit From c5487903df0f770600d0e96bfb26e00f8254c82f Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 19:19:54 +0100 Subject: Be a little bit less strict about recursive dependencies. (This used to be commit 0bb89968299f90df00861a8982eefca182ed7f8d) --- source4/build/smb_build/input.pm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index 9cc374fa79..d636ecc898 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -202,9 +202,12 @@ sub calc_unique_deps($$$$$$$$) foreach my $n (@$deps) { add_implicit($INPUT, $n) unless (defined($INPUT->{$n})); - die("Recursive dependency: $n, list: " . join(',', @$busy)) if (grep (/^$n$/, @$busy)); - next if (grep /^$n$/, @$udeps); my $dep = $INPUT->{$n}; + if (grep (/^$n$/, @$busy)) { + next if (@{$dep->{OUTPUT_TYPE}}[0] eq "MERGED_OBJ"); + die("Recursive dependency: $n, list: " . join(',', @$busy)); + } + next if (grep /^$n$/, @$udeps); push (@{$udeps}, $dep->{NAME}) if $forward; -- cgit From 094769618e180cae404f5951b969e9c6c778e421 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 19:46:27 +0100 Subject: Use implicit build system element creation for external libraries. (This used to be commit 3b08f190c9dd4567e684c804a22e2612f405bbec) --- source4/build/m4/public.m4 | 22 ++++------------------ source4/build/smb_build/config_mk.pm | 2 -- source4/build/smb_build/input.pm | 13 ++++++++----- source4/build/smb_build/output.pm | 2 +- 4 files changed, 13 insertions(+), 26 deletions(-) (limited to 'source4') diff --git a/source4/build/m4/public.m4 b/source4/build/m4/public.m4 index d045cf42b7..f3d262e07a 100644 --- a/source4/build/m4/public.m4 +++ b/source4/build/m4/public.m4 @@ -8,7 +8,7 @@ dnl SMB_SUBSYSTEM(name,obj_files,required_subsystems) dnl dnl SMB_EXT_LIB_FROM_PKGCONFIG(name,pkg-config name,[ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND]) dnl -dnl SMB_EXT_LIB(name,libs,cflags,cppflags,ldflags,pcname) +dnl SMB_EXT_LIB(name,libs,cflags,cppflags,ldflags) dnl dnl SMB_ENABLE(name,default_build) dnl @@ -40,7 +40,7 @@ ENABLE = YES " ]) -dnl SMB_LIBRARY(name,obj_files,required_subsystems,version,so_version,cflags,ldflags,pcname) +dnl SMB_LIBRARY(name,obj_files,required_subsystems,version,so_version,cflags,ldflags) AC_DEFUN([SMB_LIBRARY], [ MAKE_SETTINGS="$MAKE_SETTINGS @@ -60,7 +60,6 @@ VERSION = $4 SO_VERSION = $5 CFLAGS = \$($1_CFLAGS) LDFLAGS = \$($1_LDFLAGS) -PC_NAME = $8 ENABLE = YES # End Library $1 ################################### @@ -104,8 +103,7 @@ AC_DEFUN([SMB_EXT_LIB_FROM_PKGCONFIG], [`$PKG_CONFIG --libs-only-l '$2'`], [`$PKG_CONFIG --cflags-only-other '$2'`], [`$PKG_CONFIG --cflags-only-I '$2'`], - [`$PKG_CONFIG --libs-only-other '$2'` `$PKG_CONFIG --libs-only-L '$2'`], - [ $2 ]) + [`$PKG_CONFIG --libs-only-other '$2'` `$PKG_CONFIG --libs-only-L '$2'`]) ac_cv_$1_found=yes else @@ -137,7 +135,7 @@ include $1 " ]) -dnl SMB_EXT_LIB(name,libs,cflags,cppflags,ldflags,pcname) +dnl SMB_EXT_LIB(name,libs,cflags,cppflags,ldflags) AC_DEFUN([SMB_EXT_LIB], [ MAKE_SETTINGS="$MAKE_SETTINGS @@ -147,18 +145,6 @@ $1_CPPFLAGS = $4 $1_LDFLAGS = $5 " -SMB_INFO_EXT_LIBS="$SMB_INFO_EXT_LIBS -################################### -# Start Ext Lib $1 -@<:@EXT_LIB::$1@:>@ -LIBS = \$($1_LIBS) -CFLAGS = \$($1_CFLAGS) -CPPFLAGS = \$($1_CPPFLAGS) -LDFLAGS = \$($1_LDFLAGS) -PC_NAME = $6 -# End Ext Lib $1 -################################### -" ]) dnl SMB_ENABLE(name,default_build) diff --git a/source4/build/smb_build/config_mk.pm b/source4/build/smb_build/config_mk.pm index aa075490bc..ed05a4e4d9 100644 --- a/source4/build/smb_build/config_mk.pm +++ b/source4/build/smb_build/config_mk.pm @@ -18,7 +18,6 @@ my $section_types = { "CFLAGS" => "list", "CPPFLAGS" => "list", "LDFLAGS" => "list", - "PC_NAME" => "string", }, "PYTHON" => { SWIG_FILE => "string", @@ -90,7 +89,6 @@ my $section_types = { "SO_VERSION" => "string", "LIBRARY_REALNAME" => "string", - "PC_NAME" => "string", "PC_FILE" => "string", "INIT_FUNCTION_TYPE" => "string", diff --git a/source4/build/smb_build/input.pm b/source4/build/smb_build/input.pm index d636ecc898..da90e9db48 100644 --- a/source4/build/smb_build/input.pm +++ b/source4/build/smb_build/input.pm @@ -92,7 +92,7 @@ sub check_module($$$) if (not defined($mod->{OUTPUT_TYPE})) { if ($INPUT->{$mod->{SUBSYSTEM}}->{TYPE} eq "EXT_LIB") { - $mod->{OUTPUT_TYPE} = ["SHARED_LIBRARY"]; + $mod->{OUTPUT_TYPE} = undef; } else { $mod->{OUTPUT_TYPE} = $default_ot; } @@ -163,7 +163,7 @@ sub check_python($$$) $python->{LIBRARY_REALNAME} = "$basename.\$(SHLIBEXT)"; $python->{INIT_FUNCTION} = "{ (char *)\"$basename\", init$basename }"; } - push (@{$python->{CFLAGS}}, @{$INPUT->{EXT_LIB_PYTHON}->{CFLAGS}}); + push (@{$python->{CFLAGS}}, "\$(EXT_LIB_PYTHON_CFLAGS)"); $python->{SUBSYSTEM} = "LIBPYTHON"; @@ -189,9 +189,12 @@ sub add_implicit($$) $INPUT->{$n} = { TYPE => "MAKE_RULE", NAME => $n, - TARGET => lc($n), - LIBS => "\$(".uc($n)."_LIBS)", - CFLAGS => "\$(".uc($n)."_CFLAG)" + TARGET => "", + OUTPUT_TYPE => undef, + LIBS => ["\$(".uc($n)."_LIBS)"], + LDFLAGS => ["\$(".uc($n)."_LDFLAGS)"], + CFLAGS => ["\$(".uc($n)."_CFLAGS)"], + CPPFLAGS => ["\$(".uc($n)."_CPPFLAGS)"] }; } diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 3d5f4466ca..83be28e740 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -210,7 +210,7 @@ sub create_output($$) } foreach $part (values %{$depend}) { - if (($part->{STANDARD_VISIBILITY} ne "default") and + if (defined($part->{STANDARD_VISIBILITY}) and ($part->{STANDARD_VISIBILITY} ne "default") and ($config->{visibility_attribute} eq "yes")) { push(@{$part->{FINAL_CFLAGS}}, "-fvisibility=$part->{STANDARD_VISIBILITY}"); } -- cgit From ff0315ba859421dff6aba055887e086fa68c2951 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 20:04:18 +0100 Subject: Rename include to mkinclude to emphasize it is different from make's include. (This used to be commit 0e1d0a874ae3d22b8f97a79b81fe0af3ef53a771) --- source4/auth/config.mk | 8 ++--- source4/build/m4/public.m4 | 2 +- source4/build/smb_build/config_mk.pm | 2 +- source4/cluster/config.mk | 2 +- source4/dsdb/config.mk | 2 +- source4/heimdal_build/config.mk | 44 ++++++++++++------------- source4/lib/basic.mk | 36 ++++++++++----------- source4/lib/ldb/config.mk | 4 +-- source4/libcli/config.mk | 8 ++--- source4/librpc/config.mk | 2 +- source4/main.mk | 62 ++++++++++++++++++------------------ source4/ntvfs/config.mk | 8 ++--- source4/scripting/ejs/config.mk | 2 +- source4/smb_server/config.mk | 4 +-- source4/torture/config.mk | 6 ++-- 15 files changed, 96 insertions(+), 96 deletions(-) (limited to 'source4') diff --git a/source4/auth/config.mk b/source4/auth/config.mk index 37581b95f3..5b320bcf36 100644 --- a/source4/auth/config.mk +++ b/source4/auth/config.mk @@ -1,8 +1,8 @@ # auth server subsystem -include gensec/config.mk -include kerberos/config.mk -include ntlmssp/config.mk -include credentials/config.mk +mkinclude gensec/config.mk +mkinclude kerberos/config.mk +mkinclude ntlmssp/config.mk +mkinclude credentials/config.mk [SUBSYSTEM::auth_session] OBJ_FILES = session.o diff --git a/source4/build/m4/public.m4 b/source4/build/m4/public.m4 index f3d262e07a..eb673446c7 100644 --- a/source4/build/m4/public.m4 +++ b/source4/build/m4/public.m4 @@ -131,7 +131,7 @@ dnl SMB_INCLUDE_MK(file) AC_DEFUN([SMB_INCLUDE_MK], [ SMB_INFO_EXT_LIBS="$SMB_INFO_EXT_LIBS -include $1 +mkinclude $1 " ]) diff --git a/source4/build/smb_build/config_mk.pm b/source4/build/smb_build/config_mk.pm index ed05a4e4d9..4d8db8a04e 100644 --- a/source4/build/smb_build/config_mk.pm +++ b/source4/build/smb_build/config_mk.pm @@ -239,7 +239,7 @@ sub run_config_mk($$$$) } # include - if ($line =~ /^include (.*)$/) { + if ($line =~ /^mkinclude (.*)$/) { my $subfile= $1; my $subdir = dirname($filename); $subdir =~ s/^\.$//g; diff --git a/source4/cluster/config.mk b/source4/cluster/config.mk index c5c2ea970a..8b225202fb 100644 --- a/source4/cluster/config.mk +++ b/source4/cluster/config.mk @@ -1,4 +1,4 @@ -include ctdb/config.mk +mkinclude ctdb/config.mk #################### [SUBSYSTEM::CLUSTER] diff --git a/source4/dsdb/config.mk b/source4/dsdb/config.mk index de00b401c8..17752fbbbd 100644 --- a/source4/dsdb/config.mk +++ b/source4/dsdb/config.mk @@ -1,6 +1,6 @@ # Directory Service subsystem -include samdb/ldb_modules/config.mk +mkinclude samdb/ldb_modules/config.mk ################################################ # Start SUBSYSTEM SAMDB diff --git a/source4/heimdal_build/config.mk b/source4/heimdal_build/config.mk index b68fe84f90..45bfd8e81f 100644 --- a/source4/heimdal_build/config.mk +++ b/source4/heimdal_build/config.mk @@ -506,32 +506,32 @@ PRIVATE_DEPENDENCIES = HEIMDAL_COM_ERR_COMPILE_LEX HEIMDAL_ROKEN_GETPROGNAME_H E # End BINARY compile_et ####################### -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/hdb/hdb.asn1 hdb_asn1 heimdal/lib/hdb | -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/gssapi/spnego/spnego.asn1 spnego_asn1 heimdal/lib/gssapi --sequence=MechTypeList | -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/gssapi/mech/gssapi.asn1 gssapi_asn1 heimdal/lib/gssapi| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/k5.asn1 krb5_asn1 heimdal/lib/asn1 --encode-rfc1510-bit-string --sequence=KRB5SignedPathPrincipals --sequence=AuthorizationData --sequence=METHOD-DATA| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/digest.asn1 digest_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkcs8.asn1 pkcs8_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkcs9.asn1 pkcs9_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkcs12.asn1 pkcs12_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/rfc2459.asn1 rfc2459_asn1 heimdal/lib/asn1 --preserve-binary=TBSCertificate --preserve-binary=TBSCRLCertList --preserve-binary=Name --sequence=GeneralNames --sequence=Extensions --sequence=CRLDistributionPoints| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkinit.asn1 pkinit_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/CMS.asn1 cms_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/hx509/ocsp.asn1 ocsp_asn1 heimdal/lib/hx509 --preserve-binary=OCSPTBSRequest --preserve-binary=OCSPResponseData| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/kx509.asn1 kx509_asn1 heimdal/lib/asn1| -include perl_path_wrapper.sh asn1_deps.pl heimdal/lib/hx509/pkcs10.asn1 pkcs10_asn1 heimdal/lib/hx509 --preserve-binary=CertificationRequestInfo| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/hdb/hdb.asn1 hdb_asn1 heimdal/lib/hdb | +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/gssapi/spnego/spnego.asn1 spnego_asn1 heimdal/lib/gssapi --sequence=MechTypeList | +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/gssapi/mech/gssapi.asn1 gssapi_asn1 heimdal/lib/gssapi| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/k5.asn1 krb5_asn1 heimdal/lib/asn1 --encode-rfc1510-bit-string --sequence=KRB5SignedPathPrincipals --sequence=AuthorizationData --sequence=METHOD-DATA| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/digest.asn1 digest_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkcs8.asn1 pkcs8_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkcs9.asn1 pkcs9_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkcs12.asn1 pkcs12_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/rfc2459.asn1 rfc2459_asn1 heimdal/lib/asn1 --preserve-binary=TBSCertificate --preserve-binary=TBSCRLCertList --preserve-binary=Name --sequence=GeneralNames --sequence=Extensions --sequence=CRLDistributionPoints| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/pkinit.asn1 pkinit_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/CMS.asn1 cms_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/hx509/ocsp.asn1 ocsp_asn1 heimdal/lib/hx509 --preserve-binary=OCSPTBSRequest --preserve-binary=OCSPResponseData| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/asn1/kx509.asn1 kx509_asn1 heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh asn1_deps.pl heimdal/lib/hx509/pkcs10.asn1 pkcs10_asn1 heimdal/lib/hx509 --preserve-binary=CertificationRequestInfo| # # Ensure to update ../static_deps.mk when you add a new entry here! # -include perl_path_wrapper.sh et_deps.pl heimdal/lib/asn1/asn1_err.et heimdal/lib/asn1| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/hdb/hdb_err.et heimdal/lib/hdb| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/heim_err.et heimdal/lib/krb5| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/k524_err.et heimdal/lib/krb5| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/krb_err.et heimdal/lib/krb5| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/krb5_err.et heimdal/lib/krb5| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/gssapi/krb5/gkrb5_err.et heimdal/lib/gssapi| -include perl_path_wrapper.sh et_deps.pl heimdal/lib/hx509/hx509_err.et heimdal/lib/hx509| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/asn1/asn1_err.et heimdal/lib/asn1| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/hdb/hdb_err.et heimdal/lib/hdb| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/heim_err.et heimdal/lib/krb5| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/k524_err.et heimdal/lib/krb5| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/krb_err.et heimdal/lib/krb5| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/krb5/krb5_err.et heimdal/lib/krb5| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/gssapi/krb5/gkrb5_err.et heimdal/lib/gssapi| +mkinclude perl_path_wrapper.sh et_deps.pl heimdal/lib/hx509/hx509_err.et heimdal/lib/hx509| clean:: @-rm -f bin/compile_et bin/asn1_compile diff --git a/source4/lib/basic.mk b/source4/lib/basic.mk index 53eb0d038f..a118636c52 100644 --- a/source4/lib/basic.mk +++ b/source4/lib/basic.mk @@ -1,22 +1,22 @@ # LIB BASIC subsystem -include samba3/config.mk -include socket/config.mk -include charset/config.mk -include ldb-samba/config.mk -include tls/config.mk -include registry/config.mk -include policy/config.mk -include messaging/config.mk -include events/config.mk -include cmdline/config.mk -include socket_wrapper/config.mk -include nss_wrapper/config.mk -include appweb/config.mk -include stream/config.mk -include util/config.mk -include tdr/config.mk -include dbwrap/config.mk -include crypto/config.mk +mkinclude samba3/config.mk +mkinclude socket/config.mk +mkinclude charset/config.mk +mkinclude ldb-samba/config.mk +mkinclude tls/config.mk +mkinclude registry/config.mk +mkinclude policy/config.mk +mkinclude messaging/config.mk +mkinclude events/config.mk +mkinclude cmdline/config.mk +mkinclude socket_wrapper/config.mk +mkinclude nss_wrapper/config.mk +mkinclude appweb/config.mk +mkinclude stream/config.mk +mkinclude util/config.mk +mkinclude tdr/config.mk +mkinclude dbwrap/config.mk +mkinclude crypto/config.mk [SUBSYSTEM::LIBCOMPRESSION] OBJ_FILES = compression/mszip.o diff --git a/source4/lib/ldb/config.mk b/source4/lib/ldb/config.mk index 75ce89d6cf..0e7caa381f 100644 --- a/source4/lib/ldb/config.mk +++ b/source4/lib/ldb/config.mk @@ -193,5 +193,5 @@ PRIVATE_DEPENDENCIES = \ ################################################ -include tools/config.mk -include ldb_ildap/config.mk +mkinclude tools/config.mk +mkinclude ldb_ildap/config.mk diff --git a/source4/libcli/config.mk b/source4/libcli/config.mk index 67620fac89..e4b6c71c8c 100644 --- a/source4/libcli/config.mk +++ b/source4/libcli/config.mk @@ -1,6 +1,6 @@ -include auth/config.mk -include ldap/config.mk -include security/config.mk +mkinclude auth/config.mk +mkinclude ldap/config.mk +mkinclude security/config.mk [SUBSYSTEM::LIBSAMBA-ERRORS] PUBLIC_HEADERS = util/error.h util/ntstatus.h util/doserr.h util/werror.h @@ -144,4 +144,4 @@ OBJ_FILES = raw/rawfile.o \ raw/rawlpq.o \ raw/rawshadow.o -include smb2/config.mk +mkinclude smb2/config.mk diff --git a/source4/librpc/config.mk b/source4/librpc/config.mk index 0f5a65121c..2fdef41b2a 100644 --- a/source4/librpc/config.mk +++ b/source4/librpc/config.mk @@ -277,7 +277,7 @@ OBJ_FILES = gen_ndr/ndr_winbind.o PUBLIC_HEADERS = gen_ndr/winbind.h PUBLIC_DEPENDENCIES = LIBNDR NDR_NETLOGON -include ../heimdal_build/perl_path_wrapper.sh ../librpc/idl-deps.pl librpc/idl/*.idl| +mkinclude ../heimdal_build/perl_path_wrapper.sh ../librpc/idl-deps.pl librpc/idl/*.idl| librpc/gen_ndr/tables.c: $(IDL_NDR_PARSE_H_FILES) @echo Generating librpc/gen_ndr/tables.c diff --git a/source4/main.mk b/source4/main.mk index beba4d2039..b8364aca5a 100644 --- a/source4/main.mk +++ b/source4/main.mk @@ -1,31 +1,31 @@ -include dynconfig.mk -include heimdal_build/config.mk -include config.mk -include dsdb/config.mk -include smbd/config.mk -include cluster/config.mk -include smbd/process_model.mk -include libnet/config.mk -include auth/config.mk -include nsswitch/config.mk -include lib/basic.mk -include param/config.mk -include smb_server/config.mk -include rpc_server/config.mk -include ldap_server/config.mk -include web_server/config.mk -include winbind/config.mk -include nbt_server/config.mk -include wrepl_server/config.mk -include cldap_server/config.mk -include utils/net/config.mk -include utils/config.mk -include ntvfs/config.mk -include ntptr/config.mk -include torture/config.mk -include librpc/config.mk -include client/config.mk -include libcli/config.mk -include scripting/ejs/config.mk -include scripting/python/config.mk -include kdc/config.mk +mkinclude dynconfig.mk +mkinclude heimdal_build/config.mk +mkinclude config.mk +mkinclude dsdb/config.mk +mkinclude smbd/config.mk +mkinclude cluster/config.mk +mkinclude smbd/process_model.mk +mkinclude libnet/config.mk +mkinclude auth/config.mk +mkinclude nsswitch/config.mk +mkinclude lib/basic.mk +mkinclude param/config.mk +mkinclude smb_server/config.mk +mkinclude rpc_server/config.mk +mkinclude ldap_server/config.mk +mkinclude web_server/config.mk +mkinclude winbind/config.mk +mkinclude nbt_server/config.mk +mkinclude wrepl_server/config.mk +mkinclude cldap_server/config.mk +mkinclude utils/net/config.mk +mkinclude utils/config.mk +mkinclude ntvfs/config.mk +mkinclude ntptr/config.mk +mkinclude torture/config.mk +mkinclude librpc/config.mk +mkinclude client/config.mk +mkinclude libcli/config.mk +mkinclude scripting/ejs/config.mk +mkinclude scripting/python/config.mk +mkinclude kdc/config.mk diff --git a/source4/ntvfs/config.mk b/source4/ntvfs/config.mk index 017614b7be..dbc1a4c277 100644 --- a/source4/ntvfs/config.mk +++ b/source4/ntvfs/config.mk @@ -1,8 +1,8 @@ # NTVFS Server subsystem -include posix/config.mk -include common/config.mk -include unixuid/config.mk -include sysdep/config.mk +mkinclude posix/config.mk +mkinclude common/config.mk +mkinclude unixuid/config.mk +mkinclude sysdep/config.mk ################################################ # Start MODULE ntvfs_cifs diff --git a/source4/scripting/ejs/config.mk b/source4/scripting/ejs/config.mk index f99f37ecad..c1f07367fb 100644 --- a/source4/scripting/ejs/config.mk +++ b/source4/scripting/ejs/config.mk @@ -66,7 +66,7 @@ SUBSYSTEM = smbcalls OUTPUT_TYPE = MERGED_OBJ INIT_FUNCTION = smb_setup_ejs_system -include ejsnet/config.mk +mkinclude ejsnet/config.mk [SUBSYSTEM::smbcalls] PRIVATE_PROTO_HEADER = proto.h diff --git a/source4/smb_server/config.mk b/source4/smb_server/config.mk index f21336ae69..85c969df59 100644 --- a/source4/smb_server/config.mk +++ b/source4/smb_server/config.mk @@ -25,5 +25,5 @@ PUBLIC_DEPENDENCIES = \ # End SUBSYSTEM SMB ####################### -include smb/config.mk -include smb2/config.mk +mkinclude smb/config.mk +mkinclude smb2/config.mk diff --git a/source4/torture/config.mk b/source4/torture/config.mk index a11b94b639..a1975a6caf 100644 --- a/source4/torture/config.mk +++ b/source4/torture/config.mk @@ -95,8 +95,8 @@ PRIVATE_DEPENDENCIES = \ # End SUBSYSTEM TORTURE_RAW ################################# -include smb2/config.mk -include winbind/config.mk +mkinclude smb2/config.mk +mkinclude winbind/config.mk [SUBSYSTEM::TORTURE_NDR] PRIVATE_PROTO_HEADER = ndr/proto.h @@ -200,7 +200,7 @@ PRIVATE_DEPENDENCIES = \ # End SUBSYSTEM TORTURE_AUTH ################################# -include local/config.mk +mkinclude local/config.mk ################################# # Start MODULE TORTURE_NBENCH -- cgit From 3e4b8da4df1675aa8ac1b23675700d5f8c88daf7 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 20:14:29 +0100 Subject: Fix summary. (This used to be commit afe9418b728a1b35f713c650622c1abadba9a526) --- source4/build/smb_build/summary.pm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'source4') diff --git a/source4/build/smb_build/summary.pm b/source4/build/smb_build/summary.pm index 52817f3597..4ea1ad525e 100644 --- a/source4/build/smb_build/summary.pm +++ b/source4/build/smb_build/summary.pm @@ -5,6 +5,7 @@ # Released under the GNU GPL package summary; +use smb_build::config; use strict; sub enabled($) @@ -21,9 +22,7 @@ sub showitem($$$) my @need = (); foreach (@$items) { - if (!enabled($output->{$_}->{ENABLE})) { - push (@need, $_); - } + push (@need, $_) if (enabled($config::enable{$_})); } print "Support for $desc: "; -- cgit From 984d7d84225f1fc4747dd2837623023e30a8ba36 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 21:13:03 +0100 Subject: Use consistent hierarchical naming for tests used in selftest. This is mainly cosmetical and so it would in the future be possible to print a tree of the tests. People using "make test TESTS=..." may have to specify a slightly different regular expression than they used to. (This used to be commit fe0f2173c006573513f54c45c7bbc9d6855494af) --- source4/samba4-knownfail | 74 ++++++++++++++-------------- source4/samba4-skip | 104 +++++++++++++++++++-------------------- source4/selftest/samba4_tests.sh | 76 ++++++++++++++++------------ 3 files changed, 134 insertions(+), 120 deletions(-) (limited to 'source4') diff --git a/source4/samba4-knownfail b/source4/samba4-knownfail index 376d627764..651111221f 100644 --- a/source4/samba4-knownfail +++ b/source4/samba4-knownfail @@ -1,39 +1,39 @@ -LOCAL-RESOLVE.*.async -LOCAL-ICONV.*.next_codepoint() -BASE-DELAYWRITE.finfo update on close -BASE-DELETE.*.deltest20a -BASE-DELETE.*.deltest20b -RAW-OPLOCK.*.OPLOCK -RPC-WINREG -LOCAL-REGISTRY.*.security # Not implemented yet -RPC-WKSSVC -RPC-HANDLES.*.lsarpc-shared -RPC-HANDLES.*.mixed-shared -RPC-EPMAPPER.*.Insert -RPC-EPMAPPER.*.InqObject -RPC-DFS.* -RPC-DRSUAPI.* -RPC-LSALOOKUP -RPC-CRACKNAMES -RPC-NETLOGON.*.LogonUasLogon -RPC-NETLOGON.*.LogonUasLogoff -RPC-NETLOGON.*.DatabaseSync -RPC-NETLOGON.*.DatabaseSync2 -RPC-NETLOGON.*.GetDcName -RPC-NETLOGON.*.LogonControl -RPC-NETLOGON.*.LogonControl2 -RPC-NETLOGON.*.GetAnyDCName -RPC-NETLOGON.*.DsrEnumerateDomainTrusts -RPC-NETLOGON.*.NetrEnumerateTrustedDomains -RPC-NETLOGON.*.NetrEnumerateTrustedDomainsEx -RPC-NETLOGON.*.DsrGetDcSiteCoverageW -RPC-NETLOGON.*.DsRAddressToSitenamesW -RPC-NETLOGON.*.DsRAddressToSitenamesExW -RPC-NETLOGON.*.GetPassword -RPC-NETLOGON.*.GetTrustPasswords -BASE-CHARSET.*.Testing partial surrogate -.*NET-API-DELSHARE.* # DelShare isn't implemented yet -RAP.*netservergetinfo +local.resolve.*.async +local.iconv.*.next_codepoint() +base.delaywrite.finfo update on close +base.delete.*.deltest20a +base.delete.*.deltest20b +raw.oplock.*.OPLOCK +rpc.winreg +local.registry.*.security # Not implemented yet +rpc.wkssvc +rpc.handles.*.lsarpc-shared +rpc.handles.*.mixed-shared +rpc.epmapper.*.Insert +rpc.epmapper.*.InqObject +rpc.dfs.* +rpc.drsuapi.* +rpc.lsalookup +rpc.cracknames +rpc.netlogon.*.LogonUasLogon +rpc.netlogon.*.LogonUasLogoff +rpc.netlogon.*.DatabaseSync +rpc.netlogon.*.DatabaseSync2 +rpc.netlogon.*.GetDcName +rpc.netlogon.*.LogonControl +rpc.netlogon.*.LogonControl2 +rpc.netlogon.*.GetAnyDCName +rpc.netlogon.*.DsrEnumerateDomainTrusts +rpc.netlogon.*.NetrEnumerateTrustedDomains +rpc.netlogon.*.NetrEnumerateTrustedDomainsEx +rpc.netlogon.*.DsrGetDcSiteCoverageW +rpc.netlogon.*.DsRAddressToSitenamesW +rpc.netlogon.*.DsRAddressToSitenamesExW +rpc.netlogon.*.GetPassword +rpc.netlogon.*.GetTrustPasswords +base.charset.*.Testing partial surrogate +.*net.api.delshare.* # DelShare isn't implemented yet +rap.*netservergetinfo kinit with pkinit # fails with: salt type 3 not supported samba4.blackbox.provision.py.reprovision # Fails with entry already exists -LOCAL-TORTURE.provision +local.torture.provision diff --git a/source4/samba4-skip b/source4/samba4-skip index ea69e297ce..e3d2b182d1 100644 --- a/source4/samba4-skip +++ b/source4/samba4-skip @@ -1,54 +1,54 @@ -BASE-DEFER_OPEN -BASE-DELAYWRITE -RAW-COMPOSITE -RAW-OPLOCK -BASE-IOMETER -BASE-CASETABLE -BASE-NTTRANS -.*BASE-BENCH-HOLDCON.* # Very slow -BASE-SCAN-MAXFID -RAW-BENCH-OPLOCK -RAW-HOLD-OPLOCK -RAW-PING-PONG -RPC-SAMR_ACCESSMASK -RAW-SCAN-EAMAX -RAW-QFILEINFO-IPC -BASE-UTABLE -BASE-SMB -SMB2-NOTIFY -SMB2-SCAN -ntvfs.cifs.BASE-CHARSET -ntvfs.cifs.BASE-DEFER_OPEN -ntvfs.cifs.BASE-DELAYWRITE -ntvfs.cifs.BASE-IOMETER -ntvfs.cifs.BASE-CASETABLE -ntvfs.cifs.BASE-NTTRANS -ntvfs.cifs.BASE-SCAN-MAXFID -ntvfs.cifs.BASE-UTABLE -ntvfs.cifs.BASE-SMB -ntvfs.cifs.RAW-COMPOSITE -ntvfs.cifs.RAW-OPLOCK -ntvfs.cifs.RAW-NOTIFY -ntvfs.cifs.RAW-BENCH-OPLOCK -ntvfs.cifs.RAW-SCAN-EAMAX -ntvfs.cifs.RAW-CONTEXT -ntvfs.cifs.RAW-QFILEINFO-IPC -RPC-DSSYNC -RPC-SAMSYNC -LDAP-UPTODATEVECTOR # Segfaults -RPC-SCANNER # Very slow -RPC-REMACT # Not provided by Samba 4 -RPC-OXIDRESOLVE # Not provided by Samba 4 -RPC-EVENTLOG # Not provided by Samba 4 -RPC-INITSHUTDOWN # Not provided by Samba 4 -RPC-SVCCTL # Not provided by Samba 4 -RPC-ATSVC # Not provided by Samba 4 -RPC-FRSAPI # Not provided by Samba 4 -.*SAMBA3.* # Samba3-specific test -^samba4.NET-DOMOPEN.*$ # Hangs for some reason -^samba4.NET-API-BECOME-DC.*$ # Fails -WINBIND # FIXME: This should not be skipped -NSS-TEST # Fails +base.defer_open +base.delaywrite +raw.composite +raw.oplock +base.iometer +base.casetable +base.nttrans +.*base.bench.holdcon.* # Very slow +base.scan.maxfid +raw.bench.oplock +raw.hold.oplock +raw.ping.pong +rpc.samr_accessmask +raw.scan.eamax +raw.qfileinfo.ipc +base.utable +base.smb +smb2.notify +smb2.scan +ntvfs.cifs.base.charset +ntvfs.cifs.base.defer_open +ntvfs.cifs.base.delaywrite +ntvfs.cifs.base.iometer +ntvfs.cifs.base.casetable +ntvfs.cifs.base.nttrans +ntvfs.cifs.base.scan-maxfid +ntvfs.cifs.base.utable +ntvfs.cifs.base.smb +ntvfs.cifs.raw.composite +ntvfs.cifs.raw.oplock +ntvfs.cifs.raw.notify +ntvfs.cifs.raw.bench-oplock +ntvfs.cifs.raw.scan-eamax +ntvfs.cifs.raw.context +ntvfs.cifs.raw.qfileinfo.ipc +rpc.dssync +rpc.samsync +ldap.uptodatevector # Segfaults +rpc.scanner # Very slow +rpc.remact # Not provided by Samba 4 +rpc.oxidresolve # Not provided by Samba 4 +rpc.eventlog # Not provided by Samba 4 +rpc.initshutdown # Not provided by Samba 4 +rpc.svcctl # Not provided by Samba 4 +rpc.atsvc # Not provided by Samba 4 +rpc.frsapi # Not provided by Samba 4 +.*samba3.* # Samba3-specific test +^samba4.net.domopen.*$ # Hangs for some reason +^samba4.net.api.become.dc.*$ # Fails +winbind # FIXME: This should not be skipped +nss.test # Fails samba4.samba3sam.python # Conversion from EJS not yet finished samba4.samdb.python # Not finished yet -RAW-OFFLINE # Samba 4 doesn't have much offline support yet +raw.offline # Samba 4 doesn't have much offline support yet diff --git a/source4/selftest/samba4_tests.sh b/source4/selftest/samba4_tests.sh index 60da70cc8f..d86c46432e 100755 --- a/source4/selftest/samba4_tests.sh +++ b/source4/selftest/samba4_tests.sh @@ -40,6 +40,21 @@ plantest() { echo $cmdline } +normalize_testname() { + name=$1 + shift 1 + echo $name | tr "A-Z-" "a-z." +} + +plansmbtorturetest() { + name=$1 + env=$2 + shift 2 + modname=`normalize_testname $name` + cmdline="$VALGRIND $smb4torture $* $name" + plantest "$modname" "$env" $cmdline +} + $incdir/../bin/smbtorture -V samba4srcdir=$incdir/.. @@ -67,7 +82,7 @@ if grep ENABLE_GNUTLS.1 include/config.h > /dev/null; then fi for t in LDAP-CLDAP LDAP-BASIC LDAP-SCHEMA LDAP-UPTODATEVECTOR do - plantest "$t" dc $smb4torture "-U\$USERNAME%\$PASSWORD" //\$SERVER_IP/_none_ $t + plansmbtorturetest "$t" dc "-U\$USERNAME%\$PASSWORD" //\$SERVER_IP/_none_ done # only do the ldb tests when not in quick mode - they are quite slow, and ldb @@ -75,7 +90,6 @@ done LDBDIR=$samba4srcdir/lib/ldb export LDBDIR plantest "ldb" none TEST_DATA_PREFIX=\$PREFIX $LDBDIR/tests/test-tdb.sh - plantest "js.ldap" dc $SCRIPTDIR/ldap.js $CONFIGURATION -d 10 \$SERVER -U\$USERNAME%\$PASSWORD # Tests for RPC @@ -109,15 +123,15 @@ for bindoptions in seal,padcheck $VALIDATE bigendian; do ncacn_ip_tcp) tests=$ncacn_ip_tcp_tests ;; esac for t in $tests; do - plantest "$t on $transport with $bindoptions" dc $VALGRIND $smb4torture $transport:"\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN $t "$*" + plantest "`normalize_testname $t` on $transport with $bindoptions" dc $VALGRIND $smb4torture $transport:"\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN $t "$*" done - plantest "RPC-SAMBA3-SHARESEC on $transport with $bindoptions" dc $VALGRIND $smb4torture $transport:"\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN --option=torture:share=tmp $t "$*" + plantest "rpc.samba3.sharesec on $transport with $bindoptions" dc $VALGRIND $smb4torture $transport:"\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN --option=torture:share=tmp RPC-SAMBA3-SHARESEC "$*" done done for bindoptions in "" $VALIDATE bigendian; do for t in $auto_rpc_tests; do - plantest "$t with $bindoptions" dc $VALGRIND $smb4torture "\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN $t "$*" + plantest "`normalize_testname $t` with $bindoptions" dc $VALGRIND $smb4torture "\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN $t "$*" done done @@ -129,7 +143,7 @@ for bindoptions in connect $VALIDATE ; do ncacn_ip_tcp) tests=$slow_ncacn_ip_tcp_tests ;; esac for t in $tests; do - plantest "$t on $transport with $bindoptions" dc $VALGRIND $smb4torture $transport:"\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN $t "$*" + plantest "`normalize_testname $t` on $transport with $bindoptions" dc $VALGRIND $smb4torture $transport:"\$SERVER[$bindoptions]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN $t "$*" done done done @@ -140,7 +154,7 @@ done net=`$smb4torture --list | grep ^NET-` for t in $net; do - plantest "$t" dc $VALGRIND $smb4torture "\$SERVER[$VALIDATE]" -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" $t "$*" + plansmbtorturetest "$t" dc "\$SERVER[$VALIDATE]" -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" "$*" done # Tests for session keys @@ -160,13 +174,13 @@ for ntlmoptions in \ "-k no --option=usespnego=no --option=clientntlmv2auth=yes" \ "-k no --option=gensec:spnego=no --option=clientntlmv2auth=yes" \ "-k no --option=usespnego=no"; do - name="RPC-SECRETS on $transport with $bindoptions with $ntlmoptions" + name="rpc.secrets on $transport with $bindoptions with $ntlmoptions" plantest "$name" dc $smb4torture $transport:"\$SERVER[$bindoptions]" $ntlmoptions -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN --option=gensec:target_hostname=\$NETBIOSNAME RPC-SECRETS "$*" done -plantest "RPC-SECRETS on $transport with $bindoptions with Kerberos" dc $smb4torture $transport:"\$SERVER[$bindoptions]" -k yes -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN "--option=gensec:target_hostname=\$NETBIOSNAME" RPC-SECRETS "$*" -plantest "RPC-SECRETS on $transport with $bindoptions with Kerberos - use target principal" dc $smb4torture $transport:"\$SERVER[$bindoptions]" -k yes -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN "--option=clientusespnegoprincipal=yes" "--option=gensec:target_hostname=\$NETBIOSNAME" RPC-SECRETS "$*" - plantest "RPC-SECRETS on $transport with Kerberos - use Samba3 style login" dc $smb4torture $transport:"\$SERVER" -k yes -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=\$NETBIOSNAME" "RPC-SECRETS-none*" "$*" - plantest "RPC-SECRETS on $transport with Kerberos - use Samba3 style login, use target principal" dc $smb4torture $transport:"\$SERVER" -k yes -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" "--option=clientusespnegoprincipal=yes" "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=\$NETBIOSNAME" "RPC-SECRETS-none*" "$*" +plantest "rpc.secrets on $transport with $bindoptions with Kerberos" dc $smb4torture $transport:"\$SERVER[$bindoptions]" -k yes -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN "--option=gensec:target_hostname=\$NETBIOSNAME" RPC-SECRETS "$*" +plantest "rpc.secrets on $transport with $bindoptions with Kerberos - use target principal" dc $smb4torture $transport:"\$SERVER[$bindoptions]" -k yes -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN "--option=clientusespnegoprincipal=yes" "--option=gensec:target_hostname=\$NETBIOSNAME" RPC-SECRETS "$*" +plantest "rpc.secrets on $transport with Kerberos - use Samba3 style login" dc $smb4torture $transport:"\$SERVER" -k yes -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=\$NETBIOSNAME" "RPC-SECRETS-none*" "$*" +plantest "rpc.secrets on $transport with Kerberos - use Samba3 style login, use target principal" dc $smb4torture $transport:"\$SERVER" -k yes -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" "--option=clientusespnegoprincipal=yes" "--option=gensec:fake_gssapi_krb5=yes" "--option=gensec:gssapi_krb5=no" "--option=gensec:target_hostname=\$NETBIOSNAME" "RPC-SECRETS-none*" "$*" # Echo tests transports="ncacn_np ncacn_ip_tcp ncalrpc" @@ -175,7 +189,7 @@ for transport in $transports; do for bindoptions in connect spnego spnego,sign spnego,seal $VALIDATE padcheck bigendian bigendian,seal; do for ntlmoptions in \ "--option=socket:testnonblock=True --option=torture:quick=yes"; do - plantest "RPC-ECHO on $transport with $bindoptions and $ntlmoptions" dc $smb4torture $transport:"\$SERVER[$bindoptions]" $ntlmoptions -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" RPC-ECHO "$*" + plantest "rpc.echo on $transport with $bindoptions and $ntlmoptions" dc $smb4torture $transport:"\$SERVER[$bindoptions]" $ntlmoptions -U"\$USERNAME"%"\$PASSWORD" -W "\$DOMAIN" RPC-ECHO "$*" done done done @@ -193,12 +207,12 @@ for transport in $transports; do "--option=clientntlmv2auth=yes --option=ntlmssp_client:128bit=no --option=ntlmssp_client:keyexchange=yes --option=torture:quick=yes" \ "--option=clientntlmv2auth=yes --option=ntlmssp_client:128bit=no --option=ntlmssp_client:keyexchange=no --option=torture:quick=yes" \ ; do - plantest "RPC-ECHO on $transport with $bindoptions and $ntlmoptions" dc $smb4torture $transport:"\$SERVER[$bindoptions]" $ntlmoptions -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN RPC-ECHO "$*" + plantest "rpc.echo on $transport with $bindoptions and $ntlmoptions" dc $smb4torture $transport:"\$SERVER[$bindoptions]" $ntlmoptions -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN RPC-ECHO "$*" done done done -plantest "RPC-ECHO on ncacn_np over smb2" dc $smb4torture ncacn_np:"\$SERVER[smb2]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN RPC-ECHO "$*" +plantest "rpc.echo on ncacn_np over smb2" dc $smb4torture ncacn_np:"\$SERVER[smb2]" -U"\$USERNAME"%"\$PASSWORD" -W \$DOMAIN RPC-ECHO "$*" # Tests against the NTVFS POSIX backend smb2=`$smb4torture --list | grep "^SMB2-" | xargs` @@ -206,28 +220,28 @@ raw=`$smb4torture --list | grep "^RAW-" | xargs` base=`$smb4torture --list | grep "^BASE-" | xargs` for t in $base $raw $smb2; do - plantest "$t" dc $VALGRIND $smb4torture $ADDARGS //\$SERVER/tmp -U"\$USERNAME"%"\$PASSWORD" $t + plansmbtorturetest "$t" dc $ADDARGS //\$SERVER/tmp -U"\$USERNAME"%"\$PASSWORD" done rap=`$smb4torture --list | grep "^RAP-" | xargs` for t in $rap; do - plantest "$t" dc $VALGRIND $smb4torture $ADDARGS //\$SERVER/IPC\\\$ -U"\$USERNAME"%"\$PASSWORD" $t + plansmbtorturetest "$t" dc $ADDARGS //\$SERVER/IPC\\\$ -U"\$USERNAME"%"\$PASSWORD" done # Tests against the NTVFS CIFS backend for t in $base $raw; do - plantest "ntvfs.cifs.$t" dc $VALGRIND $smb4torture //\$NETBIOSNAME/cifs -U"\$USERNAME"%"\$PASSWORD" $t + plantest "ntvfs.cifs.`normalize_testname $t`" dc $VALGRIND $smb4torture //\$NETBIOSNAME/cifs -U"\$USERNAME"%"\$PASSWORD" $t done # Local tests for t in `$smb4torture --list | grep "^LOCAL-" | xargs`; do - plantest "$t" none $VALGRIND $smb4torture ncalrpc: $t "$*" + plansmbtorturetest "$t" none $VALGRIND $smb4torture ncalrpc: "$*" done if test -f $samba4bindir/tdbtorture then - plantest "tdb stress" none $VALGRIND $samba4bindir/tdbtorture + plantest "tdb.stress" none $VALGRIND $samba4bindir/tdbtorture fi # Pidl tests @@ -260,7 +274,7 @@ plantest "blackbox.gentest" dc $bbdir/test_gentest.sh "\$SERVER" "\$USERNAME" "\ # Tests using the "Simple" NTVFS backend for t in "BASE-RW1"; do - plantest "ntvfs/simple $t" dc $VALGRIND $smb4torture $ADDARGS //\$SERVER/simple -U"\$USERNAME"%"\$PASSWORD" $t + plantest "ntvfs.simple.`normalize_testname $t`" dc $VALGRIND $smb4torture $ADDARGS //\$SERVER/simple -U"\$USERNAME"%"\$PASSWORD" $t done DATADIR=$samba4srcdir/../testdata @@ -269,17 +283,17 @@ plantest "js.samba3sam" none $SCRIPTDIR/samba3sam.js $CONFIGURATION `pwd` $DATAD # Domain Member Tests -plantest "RPC-ECHO against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" RPC-ECHO "$*" -plantest "RPC-ECHO against member server with domain creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$DOMAIN/\$DC_USERNAME"%"\$DC_PASSWORD" RPC-ECHO "$*" -plantest "RPC-SAMR against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" "RPC-SAMR" "$*" -plantest "RPC-SAMR-USERS against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" "RPC-SAMR-USERS" "$*" -plantest "RPC-SAMR-PASSWORDS against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" "RPC-SAMR-PASSWORDS" "$*" +plantest "rpc.echo against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" RPC-ECHO "$*" +plantest "rpc.echo against member server with domain creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$DOMAIN/\$DC_USERNAME"%"\$DC_PASSWORD" RPC-ECHO "$*" +plantest "rpc.samr against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" "RPC-SAMR" "$*" +plantest "rpc.samr.users against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" "RPC-SAMR-USERS" "$*" +plantest "rpc.samr.passwords against member server with local creds" member $VALGRIND $smb4torture ncacn_np:"\$NETBIOSNAME" -U"\$NETBIOSNAME/\$USERNAME"%"\$PASSWORD" "RPC-SAMR-PASSWORDS" "$*" plantest "wbinfo -a against member server with domain creds" member $VALGRIND $samba4bindir/wbinfo -a "\$DOMAIN/\$DC_USERNAME"%"\$DC_PASSWORD" NBT_TESTS=`$smb4torture --list | grep "^NBT-" | xargs` -for f in $NBT_TESTS; do - plantest $f dc $smb4torture //\$SERVER/_none_ $f -U\$USERNAME%\$PASSWORD +for t in $NBT_TESTS; do + plansmbtorturetest "$t" dc //\$SERVER/_none_ $f -U\$USERNAME%\$PASSWORD done WB_OPTS="--option=\"torture:strict mode=yes\"" @@ -293,17 +307,17 @@ WINBIND_STRUCT_TESTS=`$smb4torture --list | grep "^WINBIND-STRUCT" | xargs` WINBIND_NDR_TESTS=`$smb4torture --list | grep "^WINBIND-NDR" | xargs` for env in dc member; do for t in $WINBIND_STRUCT_TESTS; do - plantest $t $env $smb4torture $WB_OPTS //_none_/_none_ $t + plansmbtorturetest $t $env $WB_OPTS //_none_/_none_ done for t in $WINBIND_NDR_TESTS; do - plantest $t $env $smb4torture $WB_OPTS //_none_/_none_ $t + plansmbtorturetest $t $env $WB_OPTS //_none_/_none_ done done if test -f $samba4bindir/nsstest then - plantest "NSS-TEST using winbind" member $VALGRIND $samba4bindir/nsstest $samba4bindir/shared/libnss_winbind.so + plantest "nss.test using winbind" member $VALGRIND $samba4bindir/nsstest $samba4bindir/shared/libnss_winbind.so fi PYTHON=bin/smbpython -- cgit From b136033421eb045b28f5928e4d2f9604cf704690 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 21:52:23 +0100 Subject: When not using --immediate, use a one-line progress indicator in selftest. (This used to be commit 16b4af184187f29f1f710609ee37029a3f15a294) --- source4/selftest/output/plain.pm | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'source4') diff --git a/source4/selftest/output/plain.pm b/source4/selftest/output/plain.pm index 1e6dead326..e491a999ab 100644 --- a/source4/selftest/output/plain.pm +++ b/source4/selftest/output/plain.pm @@ -46,8 +46,15 @@ sub start_testsuite($$) my $out = ""; $out .= "[$self->{index}/$self->{totalsuites} in ".$duration."s"; $out .= sprintf(", %d errors", ($#{$self->{suitesfailed}}+1)) if ($#{$self->{suitesfailed}} > -1); - $out .= "] $name\n", - print "$out"; + $out .= "] $name"; + if ($self->{immediate}) { + print "$out\n"; + } else { + require Term::ReadKey; + my ($wchar, $hchar, $wpixels, $hpixels) = Term::ReadKey::GetTerminalSize(); + foreach (1..$wchar) { $out.= " "; } + print "\r".substr($out, 0, $wchar); + } } sub output_msg($$) -- cgit From 89f4cfb26310d8f44a3727af1bed70b8c52b4e09 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 23:20:08 +0100 Subject: Fix dependency on popt. (This used to be commit dd854adc7a203f18228195a080bfa8075b0cd170) --- source4/torture/config.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/torture/config.mk b/source4/torture/config.mk index a1975a6caf..cc9340e6b9 100644 --- a/source4/torture/config.mk +++ b/source4/torture/config.mk @@ -11,7 +11,8 @@ OBJ_FILES = \ PUBLIC_DEPENDENCIES = \ LIBSAMBA-CONFIG \ LIBSAMBA-UTIL \ - LIBTALLOC + LIBTALLOC \ + LIBPOPT [SUBSYSTEM::TORTURE_UTIL] OBJ_FILES = util_smb.o util_provision.o -- cgit From 0f3836238e34f96426ed88cd7dc85a9c0d216188 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 18 Feb 2008 23:27:55 +0100 Subject: Fix local tests. (This used to be commit 60f2eb404628f9903bbb839a9aaead89c7a5736f) --- source4/selftest/samba4_tests.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source4') diff --git a/source4/selftest/samba4_tests.sh b/source4/selftest/samba4_tests.sh index d86c46432e..6beff6f279 100755 --- a/source4/selftest/samba4_tests.sh +++ b/source4/selftest/samba4_tests.sh @@ -50,8 +50,9 @@ plansmbtorturetest() { name=$1 env=$2 shift 2 + other_args="$*" modname=`normalize_testname $name` - cmdline="$VALGRIND $smb4torture $* $name" + cmdline="$VALGRIND $smb4torture $other_args $name" plantest "$modname" "$env" $cmdline } @@ -236,7 +237,7 @@ done # Local tests for t in `$smb4torture --list | grep "^LOCAL-" | xargs`; do - plansmbtorturetest "$t" none $VALGRIND $smb4torture ncalrpc: "$*" + plansmbtorturetest "$t" none ncalrpc: "$*" done if test -f $samba4bindir/tdbtorture -- cgit From c455774d9330fc1903a701a2042e29f68b8227f8 Mon Sep 17 00:00:00 2001 From: Julien Kerihuel Date: Tue, 19 Feb 2008 01:55:01 +0100 Subject: Add INCLUDE command to pidl. (This used to be commit 8a8ed4fae849a2cc565a1ff77b2208a4cd6b1edb) --- .../pidl/lib/Parse/Pidl/Wireshark/Conformance.pm | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm b/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm index a240bbf9cd..43604cb51a 100644 --- a/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm +++ b/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm @@ -74,6 +74,10 @@ Change description for the specified header field. `field' is the hf name of the Code to insert when generating the specified dissector. @HF@ and @PARAM@ will be substituted. +=item I filename + +Include conformance data from the specified filename in the dissector. + =item I hf_name "true string" "false string" Override the text shown when a bitmap boolean value is enabled or disabled. @@ -331,6 +335,20 @@ sub handle_ett_field push (@{$data->{ett}}, $ett); } +sub handle_include +{ + my $pos = shift @_; + my $data = shift @_; + my $fn = shift @_; + + unless(defined($fn)) { + error($pos, "incomplete INCLUDE command"); + return; + }; + + ReadConformance($fn, $data); +} + my %field_handlers = ( TYPE => \&handle_type, NOEMIT => \&handle_noemit, @@ -343,7 +361,8 @@ my %field_handlers = ( STRIP_PREFIX => \&handle_strip_prefix, PROTOCOL => \&handle_protocol, FIELD_DESCRIPTION => \&handle_fielddescription, - IMPORT => \&handle_import + IMPORT => \&handle_import, + INCLUDE => \&handle_include ); sub ReadConformance($$) -- cgit From 35dd0b0f4ad6ab0d9365d2858b60bf82e4877bda Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 19 Feb 2008 02:02:48 +0100 Subject: Add test for INCLUDE command. (This used to be commit d1aa25249d64513f785430cab7437b5c7ca8db27) --- source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm | 4 ++-- source4/pidl/tests/wireshark-conf.pl | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'source4') diff --git a/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm b/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm index 43604cb51a..5c37b4a0c4 100644 --- a/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm +++ b/source4/pidl/lib/Parse/Pidl/Wireshark/Conformance.pm @@ -330,7 +330,7 @@ sub handle_ett_field unless(defined($ett)) { error($pos, "incomplete ETT_FIELD command"); return; - }; + } push (@{$data->{ett}}, $ett); } @@ -344,7 +344,7 @@ sub handle_include unless(defined($fn)) { error($pos, "incomplete INCLUDE command"); return; - }; + } ReadConformance($fn, $data); } diff --git a/source4/pidl/tests/wireshark-conf.pl b/source4/pidl/tests/wireshark-conf.pl index c06ac16de4..9da5c7d1ed 100755 --- a/source4/pidl/tests/wireshark-conf.pl +++ b/source4/pidl/tests/wireshark-conf.pl @@ -5,7 +5,7 @@ use strict; use warnings; -use Test::More tests => 48; +use Test::More tests => 49; use FindBin qw($RealBin); use lib "$RealBin"; use Util; @@ -35,7 +35,6 @@ test_warnings("nofile:1: Unknown command `foobar'\n", test_warnings("nofile:1: incomplete HF_RENAME command\n", sub { parse_conf("HF_RENAME\n"); }); - is_deeply(parse_conf("HF_RENAME foo bar\n")->{hf_renames}->{foo}, { OLDNAME => "foo", NEWNAME => "bar", POS => {FILE => "nofile", LINE => 1}, USED => 0}); @@ -47,6 +46,9 @@ test_warnings("nofile:1: incomplete MANUAL command\n", is_deeply(parse_conf("MANUAL foo\n"), { manual => {foo => 1}}); +test_errors("nofile:1: incomplete INCLUDE command\n", + sub { parse_conf("INCLUDE\n"); } ); + test_warnings("nofile:1: incomplete FIELD_DESCRIPTION command\n", sub { parse_conf("FIELD_DESCRIPTION foo\n"); }); -- cgit From 9368ea67cdbb0d1fe5ef2258cc7e8c20c66e6ecd Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 19 Feb 2008 03:57:30 +0100 Subject: Fix CFLAGS (caused problems on hosts without libgssapi installed on the system). (This used to be commit f6760fd161f568ef13a841a0210f130160a16c01) --- source4/build/smb_build/output.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4') diff --git a/source4/build/smb_build/output.pm b/source4/build/smb_build/output.pm index 83be28e740..ff9afe8e8c 100644 --- a/source4/build/smb_build/output.pm +++ b/source4/build/smb_build/output.pm @@ -185,7 +185,7 @@ sub create_output($$) merge_array(\$part->{FINAL_CFLAGS}, $part->{CPPFLAGS}); merge_array(\$part->{FINAL_CFLAGS}, $part->{CFLAGS}); - foreach (@{$part->{UNIQUE_DEPENDENCIES_COMPILE}}) { + foreach (@{$part->{UNIQUE_DEPENDENCIES_ALL}}) { my $elem = $depend->{$_}; next if $elem == $part; -- cgit