Index: Makefile
===================================================================
RCS file: /cvs/ports/net/samba/Makefile,v
retrieving revision 1.109
diff -N -u Makefile
--- Makefile	26 Feb 2010 18:13:25 -0000	1.109
+++ Makefile	4 Mar 2010 10:07:41 -0000
@@ -108,12 +108,26 @@
 
 SAMPLE_CONFIG=	${PREFIX}/share/examples/samba/smb.conf.default
 
+SAMBA_MANPAGES= ${WRKSRC}/../docs/manpages
+
 pre-configure:
 	@${SUBST_CMD} ${WRKSRC}/../docs/manpages/swat.8
 
+# Samba's man pages kill OpenBSD's groff/nroff/man implementation.
+# This workaround will be needed until the new usr.bin/mandoc is
+# finished and enabled.
 post-extract:
 	@cp ${FILESDIR}/krb5-config ${WRKDIR}/bin
 	@chmod a+x ${WRKDIR}/bin/krb5-config
+	@for file in ${SAMBA_MANPAGES}/*; do \
+         if [ -f $$file ]; then \
+	  cp $$file $$file.crap; \
+	  sed -e 's:\\FC::g' -e 's:\\F\[\]::g' -e 's:\.\\\":\ \\\":g' \
+	   -e 's:SH-xref:Sx:g' -e 's:\\m\[\]::g' -e 's:toupper:tu:g' \
+	   -e 's:\.\.\\\":\\\":g' -e 's:^.tu :\\":g' -e's:\\m\[blue\]::g' \
+	   -e's:\\m\[\]::g' $$file.crap  > $$file; \
+	 fi; \
+	done
 
 post-install:
 	${INSTALL_DATA_DIR} ${PREFIX}/share/doc/samba/pdf
Index: patches/patch-docs_manpages_swat_8
===================================================================
RCS file: /cvs/ports/net/samba/patches/patch-docs_manpages_swat_8,v
retrieving revision 1.7
diff -N -u patches/patch-docs_manpages_swat_8
--- patches/patch-docs_manpages_swat_8	11 Oct 2009 19:45:46 -0000	1.7
+++ patches/patch-docs_manpages_swat_8	4 Mar 2010 10:07:41 -0000
@@ -1,7 +1,7 @@
 $OpenBSD: patch-docs_manpages_swat_8,v 1.7 2009/10/11 19:45:46 sthen Exp $
---- ../docs/manpages/swat.8.orig	Wed Sep 30 08:28:45 2009
-+++ ../docs/manpages/swat.8	Sat Oct 10 20:14:20 2009
-@@ -261,49 +261,6 @@ will be appended (e\&.g\&. log\&.smbclient, log\&.smbd
+--- ../docs/manpages/swat.8.orig	Thu Mar  4 20:58:23 2010
++++ ../docs/manpages/swat.8	Thu Mar  4 21:02:34 2010
+@@ -261,49 +261,6 @@
  .RS 4
  Print a summary of command line options\&.
  .RE
@@ -10,9 +10,9 @@
 -Swat is included as binary package with most distributions\&. The package manager in this case takes care of the installation and configuration\&. This section is only for those who have compiled swat from scratch\&.
 -.PP
 -After you compile SWAT you need to run
--\FCmake install \F[]
+-make install 
 -to install the
--\FCswat\F[]
+-swat
 -binary and the various help files and images\&. A default install would put these in:
 -.sp
 -.RS 4
@@ -51,28 +51,28 @@
  .SS "Inetd Installation"
  .PP
  You need to edit your
-@@ -331,7 +288,7 @@ In
- \FC/etc/inetd\&.conf\F[]
+@@ -331,7 +288,7 @@
+ /etc/inetd\&.conf
  you should add a line like this:
  .PP
--\FCswat stream tcp nowait\&.400 root /usr/local/samba/sbin/swat swat\F[]
-+\FCswat stream tcp nowait\&.400 root ${PREFIX}/libexec/swat swat\F[]
+-swat stream tcp nowait\&.400 root /usr/local/samba/sbin/swat swat
++swat stream tcp nowait\&.400 root ${PREFIX}/samba/sbin/swat swat
  .PP
  Once you have edited
- \FC/etc/services\F[]
-@@ -357,14 +314,12 @@ This file must contain suitable startup information fo
+ /etc/services
+@@ -357,14 +314,12 @@
  This file must contain a mapping of service name (e\&.g\&., swat) to service port (e\&.g\&., 901) and protocol type (e\&.g\&., tcp)\&.
  .RE
  .PP
--\FC/usr/local/samba/lib/smb\&.conf\F[]
-+\FC${SYSCONFDIR}/samba/smb\&.conf\F[]
+-/usr/local/samba/lib/smb\&.conf
++${SYSCONFDIR}/samba/lib/smb\&.conf
  .RS 4
  This is the default location of the
  \fBsmb.conf\fR(5)
 -server configuration file that swat edits\&. Other common places that systems install this file are
--\FC /usr/samba/lib/smb\&.conf\F[]
+- /usr/samba/lib/smb\&.conf
 -and
--\FC/etc/smb\&.conf \F[]\&. This file describes all the services the server is to make available to clients\&.
+-/etc/smb\&.conf \&. This file describes all the services the server is to make available to clients\&.
 +server configuration file that swat edits\&.
 +This file describes all the services the server is to make available to clients\&.
  .RE
