pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: [PATCH] net/samba4 4.3.6 update, zfsacl option, winbindd smf, man pages option



On Tue, 15 Mar 2016, at 18:36, Thomas Klausner wrote:
> Thanks for your patches, most of these look fine. The patch to
> docs-xml/wscript_build should be sent upstream, can you please do
> that?

Hi Thomas,

Great. Thank you for the feedback.

I will work towards sending the docs-xml/wscript_build patch upstream.


Both of these suggestions make sense and I agree with them.
I have attached modified patches.

> The installation prefix for pkgsrc is configurable, so it would be
> good to find a solution that uses PREFIX passed in from the
> environment; or if that's not so easy, add a SUBST_* block to the
> pkgsrc Makefile that replaces e.g. /usr/local/share/xml/catalog with
> ${PREFIX}/share/xml/catalog.

I used ${PREFIX} in buildtools/wafsamba/wafsamba.py
I am not sure if this is correct, but buildtools/wafsamba/wafsamba.py
contains other variables and it builds.
${PREFIX} is also used in buildtools/wafsamba/wscript.

> Please do it either as you did with the module (${PLIST.man}) or add a
> separate PLIST.man file and add it to PLIST_SRC (e.g. PLIST_SRC=PLIST
> PLIST.man in the block you add to options.mk).

For the man files, I went with using a PLIST.man, as there are a large
number of man pages.
Also some man pages are built according to options, and I don't know if
I can 'and' PLIST variables.
This probably needs more investigation to check that Samba does not
install extra man pages on other systems and environments.
If it does, then add them with PLIST variables I guess?
(Building on SmartOS) I had to include PLIST_SRC+=PLIST.SunOS to avoid
errors with not-in-PLIST files. I am unsure if I am using PLIST_SRC
correctly?

These patches should apply after the numbered 1, 2 and 3 patches in my
previous email.
I built and lightly test Samba with these changes on SmartOS 2015Q4
i386.


Regards,
--
John Thomson
From 05b741dba2f6a562419c9f175c52d0a57f437a49 Mon Sep 17 00:00:00 2001
From: John <john@mgs.local>
Date: Tue, 15 Mar 2016 14:05:31 +0000
Subject: [PATCH] Add patch for Samba SmartOS docbook-xsl catalog location

---
 net/samba4/distinfo                                      |  1 +
 net/samba4/patches/patch-buildtools_wafsamba_wafsamba.py | 15 +++++++++++++++
 2 files changed, 16 insertions(+)
 create mode 100644 net/samba4/patches/patch-buildtools_wafsamba_wafsamba.py

diff --git a/net/samba4/distinfo b/net/samba4/distinfo
index 885dd03..4cecfb7 100644
--- a/net/samba4/distinfo
+++ b/net/samba4/distinfo
@@ -4,6 +4,7 @@ SHA1 (samba-4.3.6.tar.gz) = c9fd4f4ea48355e604ee1f40bf5d8e5ff9f2c692
 RMD160 (samba-4.3.6.tar.gz) = 1b332ffeb5aad33738840bcd6576dfc4e15b2e69
 SHA512 (samba-4.3.6.tar.gz) = 2551ece4e17ed855c8faf488e4438229455a063ba7687fd36bf650d72676bab3bef7e2bc9de05a00081285268bf527b9c781024ea31aac493d2fcd5fd2593c21
 Size (samba-4.3.6.tar.gz) = 20445038 bytes
+SHA1 (patch-buildtools_wafsamba_wafsamba.py) = 78b9602dbbc0a44327000f60e00b2d43d95a59e7
 SHA1 (patch-buildtools_wafsamba_wscript) = 5604936a825675647157331df2333f4237c611f5
 SHA1 (patch-lib_nss__wrapper_nss__wrapper.c) = c692fa33ec17ed4f1dc1e40c1fadf7846d976824
 SHA1 (patch-lib_nss__wrapper_wscript) = 1ce37974f93e791c9e0b1bdc34d26890583fdbfb
diff --git a/net/samba4/patches/patch-buildtools_wafsamba_wafsamba.py b/net/samba4/patches/patch-buildtools_wafsamba_wafsamba.py
new file mode 100644
index 0000000..7984321
--- /dev/null
+++ b/net/samba4/patches/patch-buildtools_wafsamba_wafsamba.py
@@ -0,0 +1,15 @@
+$NetBSD$
+
+Include docbook-xsl xml catalog location for SmartOS
+
+--- buildtools/wafsamba/wafsamba.py.orig	2015-07-21 09:47:48.000000000 +0000
++++ buildtools/wafsamba/wafsamba.py
+@@ -892,7 +892,7 @@ def SAMBAMANPAGES(bld, manpages, extra_s
+     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'
+     bld.env.SAMBA_CATALOG = bld.srcnode.abspath() + '/bin/default/docs-xml/build/catalog.xml'
+-    bld.env.SAMBA_CATALOGS = 'file:///etc/xml/catalog file:///usr/local/share/xml/catalog file://' + bld.env.SAMBA_CATALOG
++    bld.env.SAMBA_CATALOGS = 'file:///etc/xml/catalog file:///usr/local/share/xml/catalog file://${PREFIX}/share/xml/catalog file://' + bld.env.SAMBA_CATALOG
+ 
+     for m in manpages.split():
+         source = m + '.xml'
-- 
2.6.4

From 6d4a4076fd0c43e54de21cbaaf8f588c4d2fc1f6 Mon Sep 17 00:00:00 2001
From: John <john@mgs.local>
Date: Tue, 15 Mar 2016 14:20:20 +0000
Subject: [PATCH] Add man option

Include Samba man pages in package.
---
 net/samba4/Makefile                              |   1 -
 net/samba4/PLIST.man                             | 118 +++++++++++++++++++++++
 net/samba4/distinfo                              |   1 +
 net/samba4/options.mk                            |  17 +++-
 net/samba4/patches/patch-docs-xml_wscript__build |  14 +++
 5 files changed, 149 insertions(+), 2 deletions(-)
 create mode 100644 net/samba4/PLIST.man
 create mode 100644 net/samba4/patches/patch-docs-xml_wscript__build

diff --git a/net/samba4/Makefile b/net/samba4/Makefile
index 6084593..dd3969f 100644
--- a/net/samba4/Makefile
+++ b/net/samba4/Makefile
@@ -61,7 +61,6 @@ BROKEN_GETTEXT_DETECTION=yes
 #CONFIGURE_ARGS+=	--fatal-errors
 
 HAS_CONFIGURE=		yes
-CONFIGURE_ENV+=		XSLTPROC=${FALSE} # suppress generation of man pages
 CONFIGURE_ARGS+=	--libdir=${SAMBA_LIB}
 CONFIG_SHELL=		${PYTHONBIN}
 CONFIGURE_SCRIPT=	${WRKSRC}/buildtools/bin/waf
diff --git a/net/samba4/PLIST.man b/net/samba4/PLIST.man
new file mode 100644
index 0000000..c4ca40e
--- /dev/null
+++ b/net/samba4/PLIST.man
@@ -0,0 +1,118 @@
+@comment $NetBSD: PLIST.man$
+man/man1/dbwrap_tool.1
+man/man1/findsmb.1
+man/man1/gentest.1
+man/man1/ldbadd.1
+man/man1/ldbdel.1
+man/man1/ldbedit.1
+man/man1/ldbmodify.1
+man/man1/ldbrename.1
+man/man1/ldbsearch.1
+man/man1/locktest.1
+man/man1/log2pcap.1
+man/man1/masktest.1
+man/man1/ndrdump.1
+man/man1/nmblookup.1
+man/man1/ntlm_auth.1
+man/man1/oLschema2ldif.1
+man/man1/profiles.1
+man/man1/regdiff.1
+man/man1/regpatch.1
+man/man1/regshell.1
+man/man1/regtree.1
+man/man1/rpcclient.1
+man/man1/sharesec.1
+man/man1/smbcacls.1
+man/man1/smbclient.1
+man/man1/smbcontrol.1
+man/man1/smbcquotas.1
+man/man1/smbget.1
+man/man1/smbstatus.1
+man/man1/smbtar.1
+man/man1/smbtorture.1
+man/man1/smbtree.1
+man/man1/testparm.1
+man/man1/vfstest.1
+man/man1/wbinfo.1
+man/man3/ldb.3
+man/man3/talloc.3
+man/man5/lmhosts.5
+${PLIST.pam}man/man5/pam_winbind.conf.5
+man/man5/smb.conf.5
+man/man5/smbgetrc.5
+man/man5/smbpasswd.5
+man/man7/libsmbclient.7
+man/man7/samba.7
+man/man7/winbind_krb5_locator.7
+man/man8/eventlogadm.8
+man/man8/idmap_ad.8
+man/man8/idmap_autorid.8
+man/man8/idmap_hash.8
+man/man8/idmap_ldap.8
+man/man8/idmap_nss.8
+man/man8/idmap_rfc2307.8
+man/man8/idmap_rid.8
+man/man8/idmap_tdb.8
+man/man8/idmap_tdb2.8
+man/man8/net.8
+man/man8/nmbd.8
+${PLIST.pam}man/man8/pam_winbind.8
+man/man8/pdbedit.8
+man/man8/samba-regedit.8
+man/man8/samba-tool.8
+man/man8/samba.8
+man/man8/smbd.8
+man/man8/smbpasswd.8
+man/man8/smbspool.8
+man/man8/smbspool_krb5_wrapper.8
+man/man8/smbta-util.8
+man/man8/tdbbackup.8
+man/man8/tdbdump.8
+man/man8/tdbrestore.8
+man/man8/tdbtool.8
+man/man8/vfs_acl_tdb.8
+man/man8/vfs_acl_xattr.8
+man/man8/vfs_aio_fork.8
+man/man8/vfs_aio_linux.8
+man/man8/vfs_aio_pthread.8
+man/man8/vfs_audit.8
+man/man8/vfs_btrfs.8
+man/man8/vfs_cacheprime.8
+man/man8/vfs_cap.8
+man/man8/vfs_catia.8
+man/man8/vfs_ceph.8
+man/man8/vfs_commit.8
+man/man8/vfs_crossrename.8
+man/man8/vfs_default_quota.8
+man/man8/vfs_dirsort.8
+man/man8/vfs_extd_audit.8
+man/man8/vfs_fake_perms.8
+man/man8/vfs_fileid.8
+man/man8/vfs_fruit.8
+man/man8/vfs_full_audit.8
+man/man8/vfs_glusterfs.8
+man/man8/vfs_gpfs.8
+man/man8/vfs_linux_xfs_sgid.8
+man/man8/vfs_media_harmony.8
+man/man8/vfs_netatalk.8
+man/man8/vfs_prealloc.8
+man/man8/vfs_preopen.8
+man/man8/vfs_readahead.8
+man/man8/vfs_readonly.8
+man/man8/vfs_recycle.8
+man/man8/vfs_scannedonly.8
+man/man8/vfs_shadow_copy.8
+man/man8/vfs_shadow_copy2.8
+man/man8/vfs_shell_snap.8
+man/man8/vfs_smb_traffic_analyzer.8
+man/man8/vfs_snapper.8
+man/man8/vfs_streams_depot.8
+man/man8/vfs_streams_xattr.8
+man/man8/vfs_syncops.8
+man/man8/vfs_time_audit.8
+man/man8/vfs_tsmsm.8
+man/man8/vfs_unityed_media.8
+man/man8/vfs_worm.8
+man/man8/vfs_xattr_tdb.8
+man/man8/vfs_zfsacl.8
+man/man8/winbindd.8
diff --git a/net/samba4/distinfo b/net/samba4/distinfo
index 4cecfb7..60fc615 100644
--- a/net/samba4/distinfo
+++ b/net/samba4/distinfo
@@ -6,6 +6,7 @@ SHA512 (samba-4.3.6.tar.gz) = 2551ece4e17ed855c8faf488e4438229455a063ba7687fd36b
 Size (samba-4.3.6.tar.gz) = 20445038 bytes
 SHA1 (patch-buildtools_wafsamba_wafsamba.py) = 78b9602dbbc0a44327000f60e00b2d43d95a59e7
 SHA1 (patch-buildtools_wafsamba_wscript) = 5604936a825675647157331df2333f4237c611f5
+SHA1 (patch-docs-xml_wscript__build) = bfb11e5765b11235c1e0668b92831b605d502584
 SHA1 (patch-lib_nss__wrapper_nss__wrapper.c) = c692fa33ec17ed4f1dc1e40c1fadf7846d976824
 SHA1 (patch-lib_nss__wrapper_wscript) = 1ce37974f93e791c9e0b1bdc34d26890583fdbfb
 SHA1 (patch-lib_param_loadparm.h) = d1c9df37bb9969d2788dd70e613067df6bb64f26
diff --git a/net/samba4/options.mk b/net/samba4/options.mk
index 5f8c9d0..2a9fdf5 100644
--- a/net/samba4/options.mk
+++ b/net/samba4/options.mk
@@ -1,7 +1,7 @@
 # $NetBSD: options.mk$
 
 PKG_OPTIONS_VAR=	PKG_OPTIONS.samba4
-PKG_SUPPORTED_OPTIONS=	ads fam ldap pam winbind # cups # cups option is broken for me.
+PKG_SUPPORTED_OPTIONS=	ads fam ldap pam winbind man # cups # cups option is broken for me.
 PKG_SUGGESTED_OPTIONS=	ldap pam winbind
 
 .include "../../mk/bsd.fast.prefs.mk"
@@ -133,3 +133,18 @@ CONFIGURE_ARGS+=	--without-winbind
 .if !empty(SAMBA_SHARED_MODULES)
 CONFIGURE_ARGS+=	--with-shared-modules=${SAMBA_SHARED_MODULES:S/^,//}
 .endif
+
+###
+### Build man pages if wanted
+###
+.if !empty(PKG_OPTIONS:Mman)
+DEPENDS+=		docbook-xsl-[0-9]*:../../textproc/docbook-xsl
+.  include "../../textproc/libxslt/buildlink3.mk"
+PLIST_SRC=		PLIST
+PLIST_SRC+=		PLIST.man
+.if ${OPSYS} == "SunOS"
+PLIST_SRC+=		PLIST.${OPSYS}
+.endif
+.else
+CONFIGURE_ENV+=		XSLTPROC=${FALSE:Q}
+.endif
diff --git a/net/samba4/patches/patch-docs-xml_wscript__build b/net/samba4/patches/patch-docs-xml_wscript__build
new file mode 100644
index 0000000..8fafdd0
--- /dev/null
+++ b/net/samba4/patches/patch-docs-xml_wscript__build
@@ -0,0 +1,14 @@
+$NetBSD$
+
+Include ZFSACL man
+
+--- docs-xml/wscript_build.orig	2016-02-22 09:36:15.000000000 +0000
++++ docs-xml/wscript_build
+@@ -88,6 +88,7 @@ manpages='''
+          manpages/vfs_unityed_media.8
+          manpages/vfs_worm.8
+          manpages/vfs_xattr_tdb.8
++         manpages/vfs_zfsacl.8
+          manpages/vfstest.1
+          manpages/wbinfo.1
+          manpages/winbindd.8
-- 
2.6.4



Home | Main Index | Thread Index | Old Index