param: update the README with instructions for adding a parameter
authorMichael Adam <obnox@samba.org>
Thu, 23 Jul 2015 23:56:39 +0000 (01:56 +0200)
committerJeremy Allison <jra@samba.org>
Fri, 31 Jul 2015 03:00:56 +0000 (05:00 +0200)
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Jul 31 05:00:57 CEST 2015 on sn-devel-104

lib/param/README

index 6a53a455c24db89ea4765d137d51392e6daaaf1e..d83fe9a7a3ae4e646ad9646c196016e653e1ea35 100644 (file)
@@ -10,13 +10,23 @@ such as the configured shares, default parameter values and host secret keys.
 Adding a parameter
 ------------------
 
-To add or change an smb.conf option, you only have to modify
-lib/param/param_table.c and add the documentation to docs-xml/smbdotconf.
-If special defaults are needed, the functions loadparm_int() in
-lib/param/loadparm.c and/or init_globals() in source3/param/loadparm.c
-need to be adapted accordingly.
+To add or change an smb.conf option, in general you only have to add
+the documentation to docs-xml/smbdotconf, or change it.
+In addition to that, if special defaults are needed, the functions
+loadparm_init() in lib/param/loadparm.c and/or init_globals() in
+source3/param/loadparm.c need to be adapted accordingly.
 The rest is generated for you.
 
+It is important to get the attributes right in the <samba:parameter ...>
+tag of the xml files.  These determine the details of the generated code.
+
+- Supported attributes are name, context, type, constant, function,
+  generated_function, synonym, parm, enumlist, handler, and deprecated.
+- Supported contexts are 'G' (for global) and 'S' (for share).
+- Supported types are boolean, boolean-rev, boolean-auto, list,
+  cmdlist, string, ustring, char, integer, bytes, octal, and enum.
+
+
 
 Using smb.conf parameters in the code
 -------------------------------------