summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/aclocal.m42
-rw-r--r--source3/auth/auth.c2
-rw-r--r--source3/auth/auth_script.c4
-rw-r--r--source3/lib/iconv.c2
-rw-r--r--source3/passdb/pdb_interface.c2
-rw-r--r--source3/sam/idmap.c2
-rw-r--r--source3/smbd/server.c2
-rw-r--r--source3/smbd/vfs.c2
8 files changed, 15 insertions, 3 deletions
diff --git a/source3/aclocal.m4 b/source3/aclocal.m4
index 86c43f80dc..cb8c7f00e2 100644
--- a/source3/aclocal.m4
+++ b/source3/aclocal.m4
@@ -57,6 +57,7 @@ AC_DEFUN(SMB_MODULE,
string_shared_modules="$string_shared_modules $1"
elif test x"$DEST" = xSTATIC; then
[init_static_modules_]translit([$4], [A-Z], [a-z])="$[init_static_modules_]translit([$4], [A-Z], [a-z]) $1_init();"
+ [decl_static_modules_]translit([$4], [A-Z], [a-z])="$[decl_static_modules_]translit([$4], [A-Z], [a-z]) extern NTSTATUS $1_init();"
string_static_modules="$string_static_modules $1"
$4_STATIC="$$4_STATIC $2"
AC_SUBST($4_STATIC)
@@ -73,6 +74,7 @@ AC_DEFUN(SMB_SUBSYSTEM,
AC_SUBST($1_STATIC)
AC_SUBST($1_MODULES)
AC_DEFINE_UNQUOTED([static_init_]translit([$1], [A-Z], [a-z]), [{$init_static_modules_]translit([$1], [A-Z], [a-z])[}], [Static init functions])
+ AC_DEFINE_UNQUOTED([static_decl_]translit([$1], [A-Z], [a-z]), [$decl_static_modules_]translit([$1], [A-Z], [a-z]), [Decl of Static init functions])
ifelse([$2], , :, [rm -f $2])
])
diff --git a/source3/auth/auth.c b/source3/auth/auth.c
index 5329e736ff..139ba5482b 100644
--- a/source3/auth/auth.c
+++ b/source3/auth/auth.c
@@ -23,6 +23,8 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_AUTH
+static_decl_auth;
+
static struct auth_init_function_entry *backends = NULL;
static struct auth_init_function_entry *auth_find_backend_entry(const char *name);
diff --git a/source3/auth/auth_script.c b/source3/auth/auth_script.c
index 1bc33ec59e..05bae44865 100644
--- a/source3/auth/auth_script.c
+++ b/source3/auth/auth_script.c
@@ -140,16 +140,14 @@ static NTSTATUS auth_init_script(struct auth_context *auth_context, const char *
return NT_STATUS_OK;
}
-#if 0
/* Define this to build static. */
NTSTATUS auth_script_init(void)
{
return smb_register_auth(AUTH_INTERFACE_VERSION, "script", auth_init_script);
}
-#else
+
/* Define this to build shared. */
NTSTATUS init_module(void)
{
return smb_register_auth(AUTH_INTERFACE_VERSION, "script", auth_init_script);
}
-#endif
diff --git a/source3/lib/iconv.c b/source3/lib/iconv.c
index f738f45efa..c96243633f 100644
--- a/source3/lib/iconv.c
+++ b/source3/lib/iconv.c
@@ -51,6 +51,8 @@
* @sa Samba Developers Guide
**/
+static_decl_charset;
+
static size_t ascii_pull(void *,const char **, size_t *, char **, size_t *);
static size_t ascii_push(void *,const char **, size_t *, char **, size_t *);
static size_t latin1_push(void *,const char **, size_t *, char **, size_t *);
diff --git a/source3/passdb/pdb_interface.c b/source3/passdb/pdb_interface.c
index b3522e33a7..393b60516c 100644
--- a/source3/passdb/pdb_interface.c
+++ b/source3/passdb/pdb_interface.c
@@ -30,6 +30,8 @@
static struct samu *csamuser = NULL;
+static_decl_pdb;
+
static struct pdb_init_function_entry *backends = NULL;
static void lazy_initialize_passdb(void)
diff --git a/source3/sam/idmap.c b/source3/sam/idmap.c
index aac8b70013..aa5b923d3d 100644
--- a/source3/sam/idmap.c
+++ b/source3/sam/idmap.c
@@ -25,6 +25,8 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_IDMAP
+static_decl_idmap;
+
struct idmap_function_entry {
const char *name;
struct idmap_methods *methods;
diff --git a/source3/smbd/server.c b/source3/smbd/server.c
index b76ade957c..d16579f24a 100644
--- a/source3/smbd/server.c
+++ b/source3/smbd/server.c
@@ -22,6 +22,8 @@
#include "includes.h"
+static_decl_rpc;
+
static int am_parent = 1;
/* the last message the was processed */
diff --git a/source3/smbd/vfs.c b/source3/smbd/vfs.c
index 9a6327b33b..2c9403a079 100644
--- a/source3/smbd/vfs.c
+++ b/source3/smbd/vfs.c
@@ -27,6 +27,8 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_VFS
+static_decl_vfs;
+
struct vfs_init_function_entry {
char *name;
vfs_op_tuple *vfs_op_tuples;