[samba4/f18] Fixed building and manpage generation.

asn asn at fedoraproject.org
Tue Sep 18 13:07:44 UTC 2012


commit 2c64e8ee8f1b66a2e83cec9cda271cde734813b3
Author: Andreas Schneider <asn at cryptomilk.org>
Date:   Tue Sep 18 14:36:01 2012 +0200

    Fixed building and manpage generation.

 ...ch => samba-4.0.0rc2-create_smbldaphelper.patch |   41 +-
 samba-4.0.0rc2-fix_docs_build.patch                |  412 --------------------
 samba-4.0.0rc2-fix_panic_action.patch              |   42 ++
 samba-4.0.0rc2-fix_smb.conf_manpage_build.patch    |  155 ++++++++
 ...a-4.0.0rc2-fix_smbldaphelper_without_ldap.patch |   26 ++
 samba-4.0.0rc2-make_smbldaphelper_lib.patch        |  112 ++++++
 samba-4.0.0rc2-use_smb_man_style.patch             |   30 ++
 samba4.spec                                        |   24 +-
 8 files changed, 406 insertions(+), 436 deletions(-)
---
diff --git a/samba-4.0.0rc2-fix_passdb.patch b/samba-4.0.0rc2-create_smbldaphelper.patch
similarity index 70%
rename from samba-4.0.0rc2-fix_passdb.patch
rename to samba-4.0.0rc2-create_smbldaphelper.patch
index e77bce6..5f728c6 100644
--- a/samba-4.0.0rc2-fix_passdb.patch
+++ b/samba-4.0.0rc2-create_smbldaphelper.patch
@@ -1,17 +1,23 @@
-From dbb076fdc1687ca8180d9b4e5697cf06cba480fc Mon Sep 17 00:00:00 2001
-From: Alexander Bokovoy <ab at samba.org>
-Date: Thu, 13 Sep 2012 15:40:31 +0300
-Subject: [PATCH] s3: make ldapsam-related functions a smbldaphelper subsystem
+commit be7a856f5bd251dc84a72eb56cf011facd10988f
+Author:     Alexander Bokovoy <ab at samba.org>
+AuthorDate: Thu Sep 13 15:40:31 2012 +0300
+Commit:     Alexander Bokovoy <ab at samba.org>
+CommitDate: Thu Sep 13 17:36:07 2012 +0200
 
-Since these functions are used in pdb_ldap and idmap_ldap, and
-pdb_ldap might be statically linked to libpdb (default), it is
-better to keep them as separate subsystem to avoid polluting libpdb
-namespace.
-
-This is first step in refactoring libpdb. Right now I cannot move
-these functions into proper libsmbldaphelper as it uses more of
-libpdb-included functions and linking pdb_ldap against libsmbldaphelper
-library would have created a loop if pdb_ldap is included into libpdb.
+    s3: make ldapsam-related functions a smbldaphelper subsystem
+    
+    Since these functions are used in pdb_ldap and idmap_ldap, and
+    pdb_ldap might be statically linked to libpdb (default), it is
+    better to keep them as separate subsystem to avoid polluting libpdb
+    namespace.
+    
+    This is first step in refactoring libpdb. Right now I cannot move
+    these functions into proper libsmbldaphelper as it uses more of
+    libpdb-included functions and linking pdb_ldap against libsmbldaphelper
+    library would have created a loop if pdb_ldap is included into libpdb.
+    
+    Autobuild-User(master): Alexander Bokovoy <ab at samba.org>
+    Autobuild-Date(master): Thu Sep 13 17:36:07 CEST 2012 on sn-devel-104
 ---
  source3/passdb/wscript_build   | 4 ++--
  source3/winbindd/wscript_build | 2 +-
@@ -19,7 +25,7 @@ library would have created a loop if pdb_ldap is included into libpdb.
  3 files changed, 7 insertions(+), 4 deletions(-)
 
 diff --git a/source3/passdb/wscript_build b/source3/passdb/wscript_build
-index 1dfdfd0444a394df8f96d45643779f4882f65f5d..d26afc2a700fd2ae15e0c970199fbd705fa939eb 100644
+index 1dfdfd0..d26afc2 100644
 --- a/source3/passdb/wscript_build
 +++ b/source3/passdb/wscript_build
 @@ -1,7 +1,7 @@
@@ -41,7 +47,7 @@ index 1dfdfd0444a394df8f96d45643779f4882f65f5d..d26afc2a700fd2ae15e0c970199fbd70
                   init_function='',
                   internal_module=bld.SAMBA3_IS_STATIC_MODULE('pdb_ldap'),
 diff --git a/source3/winbindd/wscript_build b/source3/winbindd/wscript_build
-index 9f11affcc994f049a0e911ca9cf9d5f4cea6cefd..af3741b0b91a595a10d5a652762daa673e087e24 100644
+index 9f11aff..af3741b 100644
 --- a/source3/winbindd/wscript_build
 +++ b/source3/winbindd/wscript_build
 @@ -62,7 +62,7 @@ bld.SAMBA3_MODULE('idmap_passdb',
@@ -54,7 +60,7 @@ index 9f11affcc994f049a0e911ca9cf9d5f4cea6cefd..af3741b0b91a595a10d5a652762daa67
                   internal_module=bld.SAMBA3_IS_STATIC_MODULE('idmap_ldap'),
                   enabled=bld.SAMBA3_IS_ENABLED_MODULE('idmap_ldap') and bld.env.HAVE_LDAP)
 diff --git a/source3/wscript_build b/source3/wscript_build
-index c7395e765b0c51a8f8e3d115f9cb4f7698923ad9..c534ae6f762cfc5a3d32a856d951a814cc398935 100755
+index c7395e7..c534ae6 100755
 --- a/source3/wscript_build
 +++ b/source3/wscript_build
 @@ -215,7 +215,6 @@ PASSDB_SRC = '''${PASSDB_GET_SET_SRC} passdb/passdb.c
@@ -76,6 +82,3 @@ index c7395e765b0c51a8f8e3d115f9cb4f7698923ad9..c534ae6f762cfc5a3d32a856d951a814
  bld.SAMBA3_SUBSYSTEM('SERVER_MUTEX',
                       source=SERVER_MUTEX_SRC,
  		     deps='talloc')
--- 
-1.7.12
-
diff --git a/samba-4.0.0rc2-fix_panic_action.patch b/samba-4.0.0rc2-fix_panic_action.patch
new file mode 100644
index 0000000..dc28abb
--- /dev/null
+++ b/samba-4.0.0rc2-fix_panic_action.patch
@@ -0,0 +1,42 @@
+commit 2a7484eb7286a6896826ad1ed15aa7b1760a451c
+Author:     Matthieu Patou <mat at matws.net>
+AuthorDate: Mon Sep 17 16:51:02 2012 -0700
+Commit:     Stefan Metzmacher <metze at samba.org>
+CommitDate: Tue Sep 18 06:12:00 2012 +0200
+
+    panic action is defined as GLOBAL_VAR(szPanicAction) not GLOBAL_VAR(panic_action)
+    
+    Signed-off-by: Stefan Metzmacher <metze at samba.org>
+    
+    Autobuild-User(master): Stefan Metzmacher <metze at samba.org>
+    Autobuild-Date(master): Tue Sep 18 06:12:00 CEST 2012 on sn-devel-104
+---
+ lib/param/loadparm.c     | 2 +-
+ source3/param/loadparm.c | 1 -
+ 2 files changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/lib/param/loadparm.c b/lib/param/loadparm.c
+index 990dd29..b2e4218 100644
+--- a/lib/param/loadparm.c
++++ b/lib/param/loadparm.c
+@@ -2295,7 +2295,7 @@ static bool lpcfg_update(struct loadparm_context *lp_ctx)
+ 		return true;
+ 	}
+ 
+-	panic_action = lp_ctx->globals->panic_action;
++	panic_action = lp_ctx->globals->szPanicAction;
+ 
+ 	reload_charcnv(lp_ctx);
+ 
+diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
+index f1999ad..61606ce 100644
+--- a/source3/param/loadparm.c
++++ b/source3/param/loadparm.c
+@@ -131,7 +131,6 @@ static bool defaults_saved = false;
+ 	char *tls_cafile;						\
+ 	char *tls_crlfile;						\
+ 	char *tls_dhpfile;						\
+-	char *panic_action;						\
+ 	int bPreferredMaster;
+ 
+ #include "param/param_global.h"
diff --git a/samba-4.0.0rc2-fix_smb.conf_manpage_build.patch b/samba-4.0.0rc2-fix_smb.conf_manpage_build.patch
new file mode 100644
index 0000000..15824d5
--- /dev/null
+++ b/samba-4.0.0rc2-fix_smb.conf_manpage_build.patch
@@ -0,0 +1,155 @@
+commit 73ed1533105ac3f90813e5a0e7888a095eff4b75
+Author:     Alexander Bokovoy <ab at samba.org>
+AuthorDate: Mon Sep 17 13:07:26 2012 +0300
+Commit:     Alexander Bokovoy <ab at samba.org>
+CommitDate: Mon Sep 17 14:18:31 2012 +0200
+
+    docs-xml: convert smb.conf.5 build to waf
+    
+    smb.conf(5) is different from other manpages because before it is
+    built, it gets merged together from a number of smaller files, one
+    per parameter. So we first create a parameters.all.xml file that
+    references all these files and then include it into master smb.conf.5.xml
+    
+    One small issue is how to handle generated files in WAF build
+    from xi:include perspective as the files are generated in bin/default/docs-xml
+    rather than in docs-xml. We solve this by further expanding use of XML catalogs
+    and rewriting virtual path http://www.samba.org/samba/smbdotconf/ to proper
+    location.
+    
+    Both docs-xml autoconf and waf builds work correctly now.
+    
+    Autobuild-User(master): Alexander Bokovoy <ab at samba.org>
+    Autobuild-Date(master): Mon Sep 17 14:18:31 CEST 2012 on sn-devel-104
+---
+ buildtools/wafsamba/wafsamba.py  |  6 ++++--
+ docs-xml/build/catalog.xml.in    |  7 +++++--
+ docs-xml/manpages/smb.conf.5.xml |  5 ++++-
+ docs-xml/wscript_build           | 25 +++++++++++++++++++++++--
+ wscript_build                    |  6 ++++--
+ 5 files changed, 40 insertions(+), 9 deletions(-)
+
+diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
+index 1f71bd3..50bd4fa 100644
+--- a/buildtools/wafsamba/wafsamba.py
++++ b/buildtools/wafsamba/wafsamba.py
+@@ -789,14 +789,16 @@ def SAMBAMANPAGES(bld, manpages):
+     '''build and install manual pages'''
+     bld.env.SAMBA_EXPAND_XSL = bld.srcnode.abspath() + '/docs-xml/xslt/expand-sambadoc.xsl'
+     bld.env.SAMBA_MAN_XSL = bld.srcnode.abspath() + '/docs-xml/xslt/man.xsl'
+-    os.environ["XML_CATALOG_FILES"] = 'file:///etc/xml/catalog file://' + bld.srcnode.abspath() + '/bin/default/docs-xml/build/catalog.xml'
++    bld.env.SAMBA_CATALOGS = 'file:///etc/xml/catalog file://' + bld.srcnode.abspath() + '/bin/default/docs-xml/build/catalog.xml'
+     for m in manpages.split():
+         source = m + '.xml'
+         bld.SAMBA_GENERATOR(m,
+                             source=source,
+                             target=m,
+                             group='final',
+-                            rule='${XSLTPROC} --xinclude --stringparam noreference 0 -o ${TGT}.xml --nonet ${SAMBA_EXPAND_XSL} ${SRC} && ${XSLTPROC} --nonet -o ${TGT} ${SAMBA_MAN_XSL} ${TGT}.xml'
++                            rule='''export XML_CATALOG_FILES="${SAMBA_CATALOGS}"
++                                    ${XSLTPROC} --xinclude --stringparam noreference 0 -o ${TGT}.xml --nonet ${SAMBA_EXPAND_XSL} ${SRC}
++                                    ${XSLTPROC} --nonet -o ${TGT} ${SAMBA_MAN_XSL} ${TGT}.xml'''
+                             )
+         bld.INSTALL_FILES('${MANDIR}/man%s' % m[-1], m, flat=True)
+ Build.BuildContext.SAMBAMANPAGES = SAMBAMANPAGES
+diff --git a/docs-xml/build/catalog.xml.in b/docs-xml/build/catalog.xml.in
+index 4b99cf5..56d13a6 100644
+--- a/docs-xml/build/catalog.xml.in
++++ b/docs-xml/build/catalog.xml.in
+@@ -6,9 +6,12 @@
+ 
+     <rewriteURI
+ 			uriStartString="http://www.samba.org/samba/DTD/"
+-			rewritePrefix="file://@abs_top_builddir@/build/DTD/"/>
++			rewritePrefix="file://@abs_top_srcdir@/build/DTD/"/>
+ 
+     <rewriteURI
+ 			uriStartString="http://www.gnu.org/licenses/"
+-			rewritePrefix="file://@abs_top_builddir@/Samba3-ByExample/"/>
++			rewritePrefix="file://@abs_top_srcdir@/Samba3-ByExample/"/>
++    <rewriteURI
++			uriStartString="http://www.samba.org/samba/smbdotconf/"
++			rewritePrefix="file://@abs_top_builddir@/smbdotconf/"/>
+ </catalog>
+diff --git a/docs-xml/manpages/smb.conf.5.xml b/docs-xml/manpages/smb.conf.5.xml
+index e09eee0..a73382f 100644
+--- a/docs-xml/manpages/smb.conf.5.xml
++++ b/docs-xml/manpages/smb.conf.5.xml
+@@ -757,7 +757,10 @@ chmod 1770 /usr/local/samba/lib/usershares
+ 	<title>EXPLANATION OF EACH PARAMETER</title>
+ 	
+ 	<samba:parameterlist>
+-		<xi:include href="../smbdotconf/parameters.all.xml" parse="xml"/>
++		<!-- The URI below is resolved to local generated version of parameters.all.xml //-->
++		<!-- WAF build places it in bin/default/docs-xml/smbdotconf/parameters.all.xml //-->
++		<!-- and we redirect there via use of XML_CATALOG_FILES, see docs-xml/build/catalog.xml.in //-->
++		<xi:include href="http://www.samba.org/samba/smbdotconf/parameters.all.xml" parse="xml"/>
+ 	</samba:parameterlist>
+ 
+ </refsect1>
+diff --git a/docs-xml/wscript_build b/docs-xml/wscript_build
+index 011854b..c5d5839 100644
+--- a/docs-xml/wscript_build
++++ b/docs-xml/wscript_build
+@@ -1,5 +1,5 @@
+ #!/usr/bin/env python
+-
++from samba_utils import save_file
+ manpages='''
+          manpages/eventlogadm.8
+          manpages/findsmb.1
+@@ -23,7 +23,6 @@ manpages='''
+          manpages/rpcclient.1
+          manpages/samba.7
+          manpages/sharesec.1
+-         manpages/smb.conf.5
+          manpages/smbcacls.1
+          manpages/smbclient.1
+          manpages/smbcontrol.1
+@@ -87,8 +86,30 @@ pam_winbind_manpages = '''
+ 
+ krb5_locator_manpages = 'manpages/winbind_krb5_locator.7'
+ 
++def smbdotconf_generate_parameter_list(task):
++    parameter_all = task.outputs[0].bldpath(task.env)
++    articles = task.inputs
++
++    t = '<section xmlns:xi="http://www.w3.org/2003/XInclude">\n'
++    for article in articles:
++        t += "<xi:include href='file://" + article.abspath(task.env) + "' parse='xml'/>\n"
++    t += "</section>\n"
++    save_file(parameter_all, t , create_dir=True)
++    return 0
++
++def SMBDOTCONF_MANPAGE(bld, target):
++    ''' assemble and build smb.conf.5 manual page'''
++    articles = bld.path.ant_glob("smbdotconf/**/*.xml")
++    parameter_all = 'smbdotconf/parameters.all.xml'
++    bld.SAMBA_GENERATOR(parameter_all,
++                        source=articles,
++                        target=parameter_all,
++                        rule=smbdotconf_generate_parameter_list)
++    bld.SAMBAMANPAGES(target)
++
+ if ('XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']):
+ 
++    SMBDOTCONF_MANPAGE(bld, 'manpages/smb.conf.5')
+     bld.SAMBAMANPAGES(manpages)
+ 
+     if bld.CONFIG_SET('WITH_PAM_MODULES') and bld.CONFIG_SET('HAVE_PAM_START'):
+diff --git a/wscript_build b/wscript_build
+index 5434056..0098036 100755
+--- a/wscript_build
++++ b/wscript_build
+@@ -144,7 +144,9 @@ bld.RECURSE('testsuite/headers')
+ bld.SYMBOL_CHECK()
+ bld.DUP_SYMBOL_CHECK()
+ 
+-bld.env.ABS_TOP_BUILDDIR = bld.srcnode.abspath() + '/docs-xml'
++bld.env.ABS_TOP_SRCDIR = bld.srcnode.abspath() + '/docs-xml'
++bld.env.ABS_TOP_BUILDDIR = bld.srcnode.abspath() + '/bin/default/docs-xml'
+ bld.CONFIGURE_FILE('docs-xml/build/catalog.xml',
+-                   ABS_TOP_BUILDDIR = bld.env.ABS_TOP_BUILDDIR)
++                   ABS_TOP_BUILDDIR = bld.env.ABS_TOP_BUILDDIR,
++                   ABS_TOP_SRCDIR=bld.env.ABS_TOP_SRCDIR)
+ bld.RECURSE('docs-xml')
diff --git a/samba-4.0.0rc2-fix_smbldaphelper_without_ldap.patch b/samba-4.0.0rc2-fix_smbldaphelper_without_ldap.patch
new file mode 100644
index 0000000..dabbc4a
--- /dev/null
+++ b/samba-4.0.0rc2-fix_smbldaphelper_without_ldap.patch
@@ -0,0 +1,26 @@
+commit 35a4a1ed1f0fc6f1cbccd31bb7db9431b2518a5b
+Author:     Andrew Bartlett <abartlet at samba.org>
+AuthorDate: Fri Sep 14 11:58:02 2012 -0700
+Commit:     Andrew Bartlett <abartlet at samba.org>
+CommitDate: Fri Sep 14 22:53:30 2012 +0200
+
+    build: Fix build on systems without ldap development headers
+    
+    Autobuild-User(master): Andrew Bartlett <abartlet at samba.org>
+    Autobuild-Date(master): Fri Sep 14 22:53:30 CEST 2012 on sn-devel-104
+---
+ source3/wscript_build | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/source3/wscript_build b/source3/wscript_build
+index 60965ef..7e39ec3 100755
+--- a/source3/wscript_build
++++ b/source3/wscript_build
+@@ -740,6 +740,7 @@ bld.SAMBA3_LIBRARY('smbldaphelper',
+                    source='passdb/pdb_ldap_schema.c passdb/pdb_ldap_util.c',
+                    deps='smbldap secrets3',
+                    allow_undefined_symbols=True,
++                   enabled=bld.env.HAVE_LDAP,
+                    private_library=True)
+ 
+ bld.SAMBA3_SUBSYSTEM('SERVER_MUTEX',
diff --git a/samba-4.0.0rc2-make_smbldaphelper_lib.patch b/samba-4.0.0rc2-make_smbldaphelper_lib.patch
new file mode 100644
index 0000000..88eca27
--- /dev/null
+++ b/samba-4.0.0rc2-make_smbldaphelper_lib.patch
@@ -0,0 +1,112 @@
+commit 86a4ca28649141f77556208b833db2e076c0125d
+Author:     Alexander Bokovoy <ab at samba.org>
+AuthorDate: Thu Sep 13 20:29:25 2012 +0300
+Commit:     Alexander Bokovoy <ab at samba.org>
+CommitDate: Fri Sep 14 01:02:21 2012 +0200
+
+    s3: make smbldaphelper subsystem an internal library
+    
+    Break pdb_ldap -> smbldaphelper -> pdb -> pdb_ldap loop by
+    making smbldaphelp intentionally underlinked internal library.
+    
+    It means that libsmbldaphelp is not usable unless its user is
+    also linked to libpdb (that is the case for both its users,
+    idmap_ldap and pdb_ldap, already) but gives us a break of
+    the circular dependency in case pdb_ldap statically linked
+    into pdb (default).
+    
+    This should solve case when idmap_ldap and pdb_ldap are dynamically
+    loaded modules
+    
+    Autobuild-User(master): Alexander Bokovoy <ab at samba.org>
+    Autobuild-Date(master): Fri Sep 14 01:02:21 CEST 2012 on sn-devel-104
+---
+ source3/passdb/ABI/pdb-0.sigs  |  7 -------
+ source3/winbindd/wscript_build |  2 +-
+ source3/wscript_build          | 12 +++++++++---
+ 3 files changed, 10 insertions(+), 11 deletions(-)
+
+diff --git a/source3/passdb/ABI/pdb-0.sigs b/source3/passdb/ABI/pdb-0.sigs
+index 2b57301..bc82ff3 100644
+--- a/source3/passdb/ABI/pdb-0.sigs
++++ b/source3/passdb/ABI/pdb-0.sigs
+@@ -16,19 +16,14 @@ algorithmic_pdb_rid_is_user: bool (uint32_t)
+ algorithmic_pdb_uid_to_user_rid: uint32_t (uid_t)
+ algorithmic_pdb_user_rid_to_uid: uid_t (uint32_t)
+ algorithmic_rid_base: int (void)
+-attrib_map_to_delete_v30: {attrib = 5, name = 0xXXXX "sambaPwdLastSet"}, {attrib = 6, name = 0xXXXX "sambaPwdCanChange"}, {attrib = 7, name = 0xXXXX "sambaPwdMustChange"}, {attrib = 8, name = 0xXXXX "sambaLogonTime"}, {attrib = 9, name = 0xXXXX "sambaLogoffTime"}, {attrib = 10, name = 0xXXXX "sambaKickoffTime"}, {attrib = 12, name = 0xXXXX "displayName"}, {attrib = 29, name = 0xXXXX "sambaHomeDrive"}, {attrib = 13, name = 0xXXXX "sambaHomePath"}, {attrib = 14, name = 0xXXXX "sambaLogonScript"}, {attrib = 15, name = 0xXXXX "sambaProfilePath"}, {attrib = 17, name = 0xXXXX "sambaUserWorkstations"}, {attrib = 18, name = 0xXXXX "sambaSID"}, {attrib = 19, name = 0xXXXX "sambaPrimaryGroupSID"}, {attrib = 21, name = 0xXXXX "sambaLMPassword"}, {attrib = 22, name = 0xXXXX "sambaNTPassword"}, {attrib = 23, name = 0xXXXX "sambaDomainName"}, {attrib = 25, name = 0xXXXX "sambaAcctFlags"}, {attrib = 37, name = 0xXXXX "sambaMungedDial"}, {attrib = 35, name = 0xXXXX "sambaBadPasswordCount"}
 , {attrib = 38, name = 0xXXXX "sambaBadPasswordTime"}, {attrib = 39, name = 0xXXXX "sambaPasswordHistory"}, {attrib = 42, name = 0xXXXX "sambaLogonHours"}, {attrib = 0, name = 0xXXXX}
+-attrib_map_v30: {attrib = 1, name = 0xXXXX "uid"}, {attrib = 2, name = 0xXXXX "uidNumber"}, {attrib = 3, name = 0xXXXX "gidNumber"}, {attrib = 4, name = 0xXXXX "homeDirectory"}, {attrib = 5, name = 0xXXXX "sambaPwdLastSet"}, {attrib = 6, name = 0xXXXX "sambaPwdCanChange"}, {attrib = 7, name = 0xXXXX "sambaPwdMustChange"}, {attrib = 8, name = 0xXXXX "sambaLogonTime"}, {attrib = 9, name = 0xXXXX "sambaLogoffTime"}, {attrib = 10, name = 0xXXXX "sambaKickoffTime"}, {attrib = 11, name = 0xXXXX "cn"}, {attrib = 44, name = 0xXXXX "sn"}, {attrib = 12, name = 0xXXXX "displayName"}, {attrib = 29, name = 0xXXXX "sambaHomeDrive"}, {attrib = 13, name = 0xXXXX "sambaHomePath"}, {attrib = 14, name = 0xXXXX "sambaLogonScript"}, {attrib = 15, name = 0xXXXX "sambaProfilePath"}, {attrib = 16, name = 0xXXXX "description"}, {attrib = 17, name = 0xXXXX "sambaUserWorkstations"}, {attrib = 18, name = 0xXXXX "sambaSID"}, {attrib = 19, name = 0xXXXX "sambaPrimaryGroupSID"}, {attrib = 21, name = 0xXX
 XX "sambaLMPassword"}, {attrib = 22, name = 0xXXXX "sambaNTPassword"}, {attrib = 23, name = 0xXXXX "sambaDomainName"}, {attrib = 24, name = 0xXXXX "objectClass"}, {attrib = 25, name = 0xXXXX "sambaAcctFlags"}, {attrib = 37, name = 0xXXXX "sambaMungedDial"}, {attrib = 35, name = 0xXXXX "sambaBadPasswordCount"}, {attrib = 38, name = 0xXXXX "sambaBadPasswordTime"}, {attrib = 39, name = 0xXXXX "sambaPasswordHistory"}, {attrib = 41, name = 0xXXXX "modifyTimestamp"}, {attrib = 42, name = 0xXXXX "sambaLogonHours"}, {attrib = 0, name = 0xXXXX}
+ builtin_domain_name: const char *(void)
+ cache_account_policy_get: bool (enum pdb_policy_type, uint32_t *)
+ cache_account_policy_set: bool (enum pdb_policy_type, uint32_t)
+ create_builtin_administrators: NTSTATUS (const struct dom_sid *)
+ create_builtin_users: NTSTATUS (const struct dom_sid *)
+ decode_account_policy_name: const char *(enum pdb_policy_type)
+-dominfo_attr_list: {attrib = 23, name = 0xXXXX "sambaDomainName"}, {attrib = 34, name = 0xXXXX "sambaNextRid"}, {attrib = 26, name = 0xXXXX "sambaNextUserRid"}, {attrib = 27, name = 0xXXXX "sambaNextGroupRid"}, {attrib = 28, name = 0xXXXX "sambaSID"}, {attrib = 33, name = 0xXXXX "sambaAlgorithmicRidBase"}, {attrib = 24, name = 0xXXXX "objectClass"}, {attrib = 0, name = 0xXXXX}
+ get_account_pol_db: struct db_context *(void)
+ get_account_policy_attr: const char *(enum pdb_policy_type)
+-get_attr_key2string: const char *(ATTRIB_MAP_ENTRY *, int)
+-get_attr_list: const char **(TALLOC_CTX *, ATTRIB_MAP_ENTRY *)
+ get_domain_group_from_sid: bool (struct dom_sid, GROUP_MAP *)
+ get_primary_group_sid: NTSTATUS (TALLOC_CTX *, const char *, struct passwd **, struct dom_sid **)
+ get_privileges_for_sid_as_set: NTSTATUS (TALLOC_CTX *, PRIVILEGE_SET **, struct dom_sid *)
+@@ -42,7 +37,6 @@ grant_all_privileges: bool (const struct dom_sid *)
+ grant_privilege_by_name: bool (const struct dom_sid *, const char *)
+ grant_privilege_set: bool (const struct dom_sid *, struct lsa_PrivilegeSet *)
+ groupdb_tdb_init: const struct mapping_backend *(void)
+-idpool_attr_list: {attrib = 2, name = 0xXXXX "uidNumber"}, {attrib = 3, name = 0xXXXX "gidNumber"}, {attrib = 24, name = 0xXXXX "objectClass"}, {attrib = 0, name = 0xXXXX}
+ init_account_policy: bool (void)
+ init_buffer_from_samu: uint32_t (uint8_t **, struct samu *, bool)
+ init_samu_from_buffer: bool (struct samu *, uint32_t, uint8_t *, uint32_t)
+@@ -272,7 +266,6 @@ sid_check_is_wellknown_builtin: bool (const struct dom_sid *)
+ sid_check_is_wellknown_domain: bool (const struct dom_sid *, const char **)
+ sid_to_gid: bool (const struct dom_sid *, gid_t *)
+ sid_to_uid: bool (const struct dom_sid *, uid_t *)
+-sidmap_attr_list: {attrib = 32, name = 0xXXXX "sambaSID"}, {attrib = 2, name = 0xXXXX "uidNumber"}, {attrib = 3, name = 0xXXXX "gidNumber"}, {attrib = 24, name = 0xXXXX "objectClass"}, {attrib = 0, name = 0xXXXX}
+ sids_to_unixids: bool (const struct dom_sid *, uint32_t, struct unixid *)
+ smb_add_user_group: int (const char *, const char *)
+ smb_create_group: int (const char *, gid_t *)
+diff --git a/source3/winbindd/wscript_build b/source3/winbindd/wscript_build
+index af3741b..302b9ee 100644
+--- a/source3/winbindd/wscript_build
++++ b/source3/winbindd/wscript_build
+@@ -62,7 +62,7 @@ bld.SAMBA3_MODULE('idmap_passdb',
+ bld.SAMBA3_MODULE('idmap_ldap',
+                  subsystem='idmap',
+                  source=IDMAP_LDAP_SRC,
+-                 deps='smbldap smbldaphelper',
++                 deps='smbldap smbldaphelper pdb',
+                  init_function='',
+                  internal_module=bld.SAMBA3_IS_STATIC_MODULE('idmap_ldap'),
+                  enabled=bld.SAMBA3_IS_ENABLED_MODULE('idmap_ldap') and bld.env.HAVE_LDAP)
+diff --git a/source3/wscript_build b/source3/wscript_build
+index c534ae6..60965ef 100755
+--- a/source3/wscript_build
++++ b/source3/wscript_build
+@@ -710,7 +710,11 @@ private_pdb_match.append('!idmap_xids_to_sids')
+ 
+ # ldap module is actually three modules merged together: ldapsam, ipa, and nds
+ static_pdb_match = static_pdb_match + ['ldap', 'ipa', 'nds']
+-ldapsam_pdb_match = ['!priv2ld', '!smbldap_search_domain_info', '!ldapsam_*', '!groupmap_attr_list*', '!get_userattr_list']
++ldapsam_pdb_match = ['!priv2ld', '!smbldap_search_domain_info',
++                     '!ldapsam_*', '!groupmap_attr_list*', '!get_userattr_list',
++                     '!dominfo_attr_list', '!get_attr_key2string',
++                     '!sidmap_attr_list', '!attrib_map_*', '!idpool_attr_list',
++                     '!get_attr_list']
+ private_pdb_match.append('!pdb_nds_*')
+ private_pdb_match.append('!pdb_init_ldapsam')
+ private_pdb_match = private_pdb_match + ldapsam_pdb_match
+@@ -732,9 +736,11 @@ bld.SAMBA3_LIBRARY('pdb',
+                    vnum='0',
+                    vars=locals())
+ 
+-bld.SAMBA3_SUBSYSTEM('smbldaphelper',
++bld.SAMBA3_LIBRARY('smbldaphelper',
+                    source='passdb/pdb_ldap_schema.c passdb/pdb_ldap_util.c',
+-                   deps='smbldap secrets3 pdb')
++                   deps='smbldap secrets3',
++                   allow_undefined_symbols=True,
++                   private_library=True)
+ 
+ bld.SAMBA3_SUBSYSTEM('SERVER_MUTEX',
+                      source=SERVER_MUTEX_SRC,
diff --git a/samba-4.0.0rc2-use_smb_man_style.patch b/samba-4.0.0rc2-use_smb_man_style.patch
new file mode 100644
index 0000000..73dc3cf
--- /dev/null
+++ b/samba-4.0.0rc2-use_smb_man_style.patch
@@ -0,0 +1,30 @@
+commit e7a58bc251bd74c3c7c64ee4f5cb85ec76852a8d
+Author:     Alexander Bokovoy <ab at samba.org>
+AuthorDate: Mon Sep 17 19:09:35 2012 +0300
+Commit:     Alexander Bokovoy <ab at samba.org>
+CommitDate: Mon Sep 17 19:52:53 2012 +0200
+
+    docs-xml: fix build of winbindd- and krb5 locator-related manpages
+    
+    These manpages depend on docs-xml infrastructure (samba DTDs)
+    
+    Autobuild-User(master): Alexander Bokovoy <ab at samba.org>
+    Autobuild-Date(master): Mon Sep 17 19:52:53 CEST 2012 on sn-devel-104
+---
+ docs-xml/wscript_build | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/docs-xml/wscript_build b/docs-xml/wscript_build
+index c5d5839..32cf9be 100644
+--- a/docs-xml/wscript_build
++++ b/docs-xml/wscript_build
+@@ -113,7 +113,7 @@ if ('XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']):
+     bld.SAMBAMANPAGES(manpages)
+ 
+     if bld.CONFIG_SET('WITH_PAM_MODULES') and bld.CONFIG_SET('HAVE_PAM_START'):
+-        bld.MANPAGES(pam_winbind_manpages)
++        bld.SAMBAMANPAGES(pam_winbind_manpages)
+ 
+     if bld.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'):
+-        bld.MANPAGES(krb5_locator_manpages)
++        bld.SAMBAMANPAGES(krb5_locator_manpages)
diff --git a/samba4.spec b/samba4.spec
index a662431..0b43fb1 100644
--- a/samba4.spec
+++ b/samba4.spec
@@ -1,4 +1,4 @@
-%define main_release 139
+%define main_release 140
 
 %define samba_version 4.0.0
 %define talloc_version 2.0.7
@@ -92,9 +92,13 @@ Source102: winbind.init
 Source200: README.dc
 Source201: README.downgrade
 
-Patch0: samba-4.0.0rc2-fix_passdb.patch
 Patch1: samba-4.0.0rc2-build_idmap_manpages.patch
-Patch2: samba-4.0.0rc2-fix_docs_build.patch
+Patch2: samba-4.0.0rc2-create_smbldaphelper.patch
+Patch3: samba-4.0.0rc2-make_smbldaphelper_lib.patch
+Patch4: samba-4.0.0rc2-fix_smbldaphelper_without_ldap.patch
+Patch5: samba-4.0.0rc2-fix_smb.conf_manpage_build.patch
+Patch6: samba-4.0.0rc2-use_smb_man_style.patch
+Patch7: samba-4.0.0rc2-fix_panic_action.patch
 
 BuildRoot:      %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
 
@@ -379,9 +383,13 @@ link against the SMB, RPC and other protocols.
 %prep
 %setup -q -n samba-%{version}%{pre_release}
 
-%patch0 -p1 -b .fix_passdb
 %patch1 -p1 -b .build_idmap_manpages
-%patch2 -p1 -b .fix_docs_build
+%patch2 -p1 -b .create_smbldaphelper
+%patch3 -p1 -b .smbldaphelper_lib
+%patch4 -p1 -b .smbldaphed_without_ldap
+%patch5 -p1 -b .smb.conf_manpage
+%patch6 -p1 -b .smb_man_style
+%patch7 -p1 -b .fix_panic_action
 
 %build
 %global _talloc_lib ,talloc,pytalloc,pytalloc-util
@@ -859,6 +867,7 @@ rm -rf %{buildroot}
 %{_libdir}/samba/libshares.so
 %{_libdir}/samba/libsamba3-util.so
 %{_libdir}/samba/libsmbd_shim.so
+%{_libdir}/samba/libsmbldaphelper.so
 %{_libdir}/samba/libsmbpasswdparser.so
 %{_libdir}/samba/libsmbregistry.so
 %{_libdir}/samba/libtdb-wrap.so
@@ -1392,6 +1401,11 @@ rm -rf %{buildroot}
 %endif # with_libwbclient
 
 %changelog
+* Tue Sep 18 2012 - Andreas Schneider <asn at redhat.com> - 2:4.0.0-140.rc1
+- Fixed building the manpages.
+- Fixed building passdb and smbldaphelper
+- Fixed the panic action.
+
 * Thu Sep 13 2012 - Andreas Schneider <asn at redhat.com> - 2:4.0.0-139.rc1
 - Update to Samba 4.0.0 rc1.
 


More information about the scm-commits mailing list