diff -Naur samba-4.5.5/buildtools/wafsamba/wafsamba.py samba-4.5.5.patch/buildtools/wafsamba/wafsamba.py
--- samba-4.5.5/buildtools/wafsamba/wafsamba.py	2016-08-11 09:51:04.000000000 +0200
+++ samba-4.5.5.patch/buildtools/wafsamba/wafsamba.py	2017-02-17 15:33:36.453169574 +0100
@@ -330,9 +330,9 @@
     if pc_files is not None and not private_library:
         bld.PKG_CONFIG_FILES(pc_files, vnum=vnum)
 
-    if (manpages is not None and 'XSLTPROC_MANPAGES' in bld.env and
-        bld.env['XSLTPROC_MANPAGES']):
-        bld.MANPAGES(manpages, install)
+#    if (manpages is not None and 'XSLTPROC_MANPAGES' in bld.env and
+#        bld.env['XSLTPROC_MANPAGES']):
+#        bld.MANPAGES(manpages, install)
 
 
 Build.BuildContext.SAMBA_LIBRARY = SAMBA_LIBRARY
@@ -437,8 +437,8 @@
         samba_ldflags  = pie_ldflags
         )
 
-    if manpages is not None and 'XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']:
-        bld.MANPAGES(manpages, install)
+#    if manpages is not None and 'XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']:
+#        bld.MANPAGES(manpages, install)
 
 Build.BuildContext.SAMBA_BINARY = SAMBA_BINARY
 
diff -Naur samba-4.5.5/docs-xml/wscript_build samba-4.5.5.patch/docs-xml/wscript_build
--- samba-4.5.5/docs-xml/wscript_build	2016-08-11 09:51:04.000000000 +0200
+++ samba-4.5.5.patch/docs-xml/wscript_build	2017-02-17 15:44:45.142392019 +0100
@@ -127,23 +127,23 @@
                     rule=smbdotconf_generate_parameter_list,
                     dep_vars=bld.dynconfig_varnames())
 
-def SMBDOTCONF_MANPAGE(bld, target):
-    ''' assemble and build smb.conf.5 manual page'''
-    bld.SAMBAMANPAGES(target, parameter_all)
-
-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'):
-        bld.SAMBAMANPAGES(pam_winbind_manpages)
-
-    if bld.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'):
-        bld.SAMBAMANPAGES(krb5_locator_manpages)
-
-    if bld.CONFIG_SET('HAVE_KRB5_LOCALAUTH_PLUGIN_H'):
-        bld.SAMBAMANPAGES(krb5_localauth_manpages)
-
-    if bld.SAMBA3_IS_ENABLED_MODULE('vfs_zfsacl'):
-        bld.SAMBAMANPAGES('manpages/vfs_zfsacl.8')
+#def SMBDOTCONF_MANPAGE(bld, target):
+#    ''' assemble and build smb.conf.5 manual page'''
+#    bld.SAMBAMANPAGES(target, parameter_all)
+#
+#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'):
+#        bld.SAMBAMANPAGES(pam_winbind_manpages)
+#
+#    if bld.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'):
+#        bld.SAMBAMANPAGES(krb5_locator_manpages)
+#
+#    if bld.CONFIG_SET('HAVE_KRB5_LOCALAUTH_PLUGIN_H'):
+#        bld.SAMBAMANPAGES(krb5_localauth_manpages)
+#
+#    if bld.SAMBA3_IS_ENABLED_MODULE('vfs_zfsacl'):
+#        bld.SAMBAMANPAGES('manpages/vfs_zfsacl.8')
--- a/source4/scripting/wscript_build	2018-03-20 12:19:12.059332486 +0100
+++ b/source4/scripting/wscript_build	2018-03-20 12:19:32.087429756 +0100
@@ -12,8 +12,8 @@
     bld.INSTALL_FILES('${SBINDIR}',
                       sbin_files,
                       chmod=MODE_755, python_fixup=True, flat=True)
-    if 'XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']:
-        bld.MANPAGES(man_files, True)
+#    if 'XSLTPROC_MANPAGES' in bld.env and bld.env['XSLTPROC_MANPAGES']:
+#        bld.MANPAGES(man_files, True)
 
 if bld.CONFIG_SET('AD_DC_BUILD_IS_ENABLED'):
     bld.INSTALL_FILES('${BINDIR}',
