]> arthur.barton.de Git - netatalk.git/commitdiff
Merge remote-tracking branch 'origin/develop' into spotlight
authorRalph Boehme <sloowfranklin@gmail.com>
Mon, 4 Mar 2013 20:50:58 +0000 (21:50 +0100)
committerRalph Boehme <sloowfranklin@gmail.com>
Mon, 4 Mar 2013 20:50:58 +0000 (21:50 +0100)
Conflicts:
include/atalk/globals.h

NEWS
etc/afpd/main.c
include/atalk/globals.h
libatalk/util/netatalk_conf.c
macros/netatalk.m4
man/man5/afp.conf.5.tmpl

diff --git a/NEWS b/NEWS
index 070b773c353605796414bb1646cd3f5368255a32..7f43cf0f74e3bca2bed6c6d6e1ac0524cec835c2 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -18,7 +18,9 @@ Changes in 3.0.3
 * NEW: AFP stats about active session via dbus IPC. Client side python
        program `afpstats`. Requires dbus, dbus-glib any python-dbus.
        configure option --dbus-sysconf-dir for specifying dbus
-       system security configuration files.       
+       system security configuration files.
+       New option 'afpstats' (default: no) which determines whether
+       to enable the feature or not.
 * NEW: dtrace probes, cf include/atalk/afp_dtrace.d for available
        probes.
 * UPD: Reload groups when reloading volumes. FR #71.
index 76095b8ccd1e6ff43356c4a5284013c8cd849eb3..516adf16c6f19d43941b9bf37071594fe2f219f0 100644 (file)
@@ -329,7 +329,8 @@ int main(int ac, char **av)
 
 #ifdef HAVE_DBUS_GLIB
     /* Run dbus AFP statics thread */
-    (void)afpstats_init(server_children);
+    if (obj.options.flags & OPTION_DBUS_AFPSTATS)
+        (void)afpstats_init(server_children);
 #endif
 
     afp_child_t *child;
index 455a92b5fc95977b39b1a6eefa682810838a8eba..6f8ff68f7c79f0b10990120380f5abb4738705f3 100644 (file)
@@ -55,7 +55,9 @@
 #define OPTION_ACL2MACCESS   (1 << 8)
 #define OPTION_NOZEROCONF    (1 << 9)
 #define OPTION_SHARE_RESERV  (1 << 11) /* whether to use Solaris fcntl F_SHARE locks */
-#define OPTION_SPOTLIGHT     (1 << 12) /* whether to enable Spotlight support */
+#define OPTION_DBUS_AFPSTATS (1 << 12) /* whether to run dbus thread for afpstats */
+#define OPTION_SPOTLIGHT     (1 << 13) /* whether to enable Spotlight support */
+
 #define PASSWD_NONE     0
 #define PASSWD_SET     (1 << 0)
 #define PASSWD_NOSAVE  (1 << 1)
index e56701ad18c3eed122c87e7aacdb15ffd3721756..53c29e2814fc7113572d9ff8ca5aecd73a5f2439 100644 (file)
@@ -1725,6 +1725,8 @@ int afp_config_parse(AFPObj *AFPObj, char *processname)
         options->flags |= OPTION_NOSENDFILE;
     if (iniparser_getboolean(config, INISEC_GLOBAL, "solaris share reservations", 1))
         options->flags |= OPTION_SHARE_RESERV;
+    if (iniparser_getboolean(config, INISEC_GLOBAL, "afpstats", 0))
+        options->flags |= OPTION_DBUS_AFPSTATS;
     if (iniparser_getboolean(config, INISEC_GLOBAL, "afp read locks", 0))
         options->flags |= OPTION_AFP_READ_LOCK;
     if (iniparser_getboolean(config, INISEC_GLOBAL, "spotlight", 0))
index 212251731552ebdb422b3a3223d0eba7499db55f..b5096e37677f8bc10e7bdc80e4b495d277ea7b0b 100644 (file)
@@ -37,7 +37,7 @@ dnl Check for dbus-glib, for AFP stats
 AC_DEFUN([AC_NETATALK_DBUS_GLIB], [
     atalk_cv_with_dbus=no
     PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.1, have_dbus=yes, have_dbus=no)
-    PKG_CHECK_MODULES(DBUS_GLIB, gobject-2.0 >= 2.6, have_dbus_glib=yes, have_dbus_glib=no)
+    PKG_CHECK_MODULES(DBUS_GLIB, dbus-glib-1, have_dbus_glib=yes, have_dbus_glib=no)
     PKG_CHECK_MODULES(DBUS_GTHREAD, gthread-2.0, have_dbus_gthread=yes, have_dbus_gthread=no)
     AC_SUBST(DBUS_CFLAGS)
     AC_SUBST(DBUS_LIBS)
index c03ad30a8b8a201090e8c8b732e30dc90c2cb715..6840bf7dcbf25bf062b2acd148632d046e9a4c31 100644 (file)
@@ -2,12 +2,12 @@
 .\"     Title: afp.conf
 .\"    Author: [FIXME: author] [see http://docbook.sf.net/el/author]
 .\" Generator: DocBook XSL Stylesheets v1.78.0 <http://docbook.sf.net/>
-.\"      Date: 19 Jan 2013
+.\"      Date: 19 Feb 2013
 .\"    Manual: Netatalk 3.0
 .\"    Source: Netatalk 3.0
 .\"  Language: English
 .\"
-.TH "AFP\&.CONF" "5" "19 Jan 2013" "Netatalk 3.0" "Netatalk 3.0"
+.TH "AFP\&.CONF" "5" "19 Feb 2013" "Netatalk 3.0" "Netatalk 3.0"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -508,6 +508,11 @@ afp read locks = \fIBOOLEAN\fR (default: \fIno\fR) \fB(G)\fR
 Whether to apply locks to the byte region read in FPRead calls\&. The AFP spec mandates this, but it\*(Aqs not really in line with UNIX semantics and is a performance hug\&.
 .RE
 .PP
+afpstats = \fIBOOLEAN\fR (default: \fIno\fR) \fB(G)\fR
+.RS 4
+Whether to provide AFP runtime statistics (connected users, open volumes) via dbus\&.
+.RE
+.PP
 basedir regex = \fIregex\fR \fB(H)\fR
 .RS 4
 Regular expression which matches the parent directory of the user homes\&. If
@@ -871,7 +876,7 @@ cnid scheme = \fIbackend\fR \fB(V)\fR
 set the CNID backend to be used for the volume, default is [:DEFAULT_CNID_SCHEME:] available schemes: [:COMPILED_BACKENDS:]
 .RE
 .PP
-ea = \fInone|auto|sys|ad\fR
+ea = \fInone|auto|sys|ad\fR \fB(V)\fR
 .RS 4
 Specify how Extended Attributes
 are stored\&.
@@ -914,7 +919,7 @@ specifies the Mac client charset for this Volume, e\&.g\&.
 \fIMAC_CYRILLIC\fR\&. If not specified the global setting is applied\&. This setting is only required if you need volumes, where the Mac charset differs from the one globally set in the [Global] section\&.
 .RE
 .PP
-casefold = \fBoption\fR
+casefold = \fBoption\fR \fB(V)\fR
 .RS 4
 The casefold option handles, if the case of filenames should be changed\&. The available options are:
 .sp
@@ -951,7 +956,7 @@ is for directories only\&. Don\*(Aqt use with "\fBunix priv = no\fR"\&.
 .\}
 .nf
 file perm = 0660 directory perm =
-                0770
+              0770
 .fi
 .if n \{\
 .RE