Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 28 Jun 2012 02:39:34 +0000
From:      jhagewood@FreeBSD.org
To:        svn-soc-all@FreeBSD.org
Subject:   socsvn commit: r238437 - in soc2012/jhagewood: diff diff3 mdocml
Message-ID:  <20120628023934.5F7E9106566B@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jhagewood
Date: Thu Jun 28 02:39:33 2012
New Revision: 238437
URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=238437

Log:

Modified:
  soc2012/jhagewood/diff/TODO
  soc2012/jhagewood/diff/diff-test.sh
  soc2012/jhagewood/diff/hagewood-diff.patch
  soc2012/jhagewood/diff3/hagewood-diff3.patch
  soc2012/jhagewood/mdocml/hagewood-mdocml-ns.patch

Modified: soc2012/jhagewood/diff/TODO
==============================================================================
--- soc2012/jhagewood/diff/TODO	Thu Jun 28 01:04:59 2012	(r238436)
+++ soc2012/jhagewood/diff/TODO	Thu Jun 28 02:39:33 2012	(r238437)
@@ -17,6 +17,7 @@
 --speed-large-file			INCOMPLETE
 --ignore-tab-expansion			IN PROGRESS		Functionality implemented in check(), needs debugging. (Same problem as --ignore-blank-lines?)  
 --width					INCOMPLETE
+--help					IN PROGRESS		Needs descriptions for the rest of the options and formatting.
 Fix non-ascii character diffs		COMPLETE		Changed name of asciifile() to istextfile() and detects if file is binary.
 Test script				COMPLETE 
 

Modified: soc2012/jhagewood/diff/diff-test.sh
==============================================================================
--- soc2012/jhagewood/diff/diff-test.sh	Thu Jun 28 01:04:59 2012	(r238436)
+++ soc2012/jhagewood/diff/diff-test.sh	Thu Jun 28 02:39:33 2012	(r238437)
@@ -9,7 +9,7 @@
 mkdir ./test_outputs/gnu
 mkdir ./test_outputs/bsd
 
-function run {
+run () {
 
 	# Default diff
 	$1 1.txt 2.txt >> $2/diff.txt
@@ -46,10 +46,12 @@
 	$1 -f 1.txt 2.txt >> $2/forward-ed.txt
 	
 	# --to-file
-	$1 --tofile="3.txt" 1.txt 2.txt >> $2/tofile.txt
+	# XXX Currently hangs on BSD diff.
+	#$1 --to-file="3.txt" 1.txt 2.txt >> $2/tofile.txt
 	
 	# --from-file
-	$1 --from-file="3.txt" 1.txt 2.txt >> $2/fromfile.txt
+	# XXX Currently hangs on BSD diff.
+	#$1 --from-file="3.txt" 1.txt 2.txt >> $2/fromfile.txt
 	
 	# --text
 	$1 --text 1.txt 2.txt >> $2/text.txt
@@ -77,18 +79,16 @@
 	# --line-format
 	$1 --line-format="%l %% %c'T'" 1.txt 2.txt >> $2/lf.txt
 	
-	# 
-	
 	# --help
 	$1 --help 1.txt 2.txt >> $2/help.txt
 }
 
-$PATH = './test_outputs/gnu'
-$DIFF_PATH = '/usr/bin/diff'
-run $DIFF_PATH $PATH
-$PATH = './test_outputs/bsd'
-$DIFF_PATH = './diff'
-run $DIFF_PATH $PATH
+DIR_PATH="./test_outputs/gnu"
+DIFF_PATH="/usr/bin/diff"
+run "$DIFF_PATH" "$DIR_PATH"
+DIR_PATH="./test_outputs/bsd"
+DIFF_PATH="./diff"
+run "$DIFF_PATH" "$DIR_PATH"
 
 #
 # Get the diff between the GNU and BSD outputs.

Modified: soc2012/jhagewood/diff/hagewood-diff.patch
==============================================================================
--- soc2012/jhagewood/diff/hagewood-diff.patch	Thu Jun 28 01:04:59 2012	(r238436)
+++ soc2012/jhagewood/diff/hagewood-diff.patch	Thu Jun 28 02:39:33 2012	(r238437)
@@ -1,6 +1,6 @@
 diff -rupN jhagewood/diff/diff-orig/diff.c jhagewood/diff/diff/diff.c
---- jhagewood/diff/diff-orig/diff.c	2012-06-25 12:05:52.000000000 -0400
-+++ jhagewood/diff/diff/diff.c	2012-06-27 16:35:04.000000000 -0400
+--- jhagewood/diff/diff-orig/diff.c	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff/diff/diff.c	2012-06-28 02:16:56.000000000 -0400
 @@ -1,4 +1,4 @@
 -/*-
 +/*
@@ -56,7 +56,7 @@
  
  
  /* Options which exceed manageable alphanumeric assignments */ 
-@@ -69,75 +67,82 @@ enum
+@@ -69,75 +67,82 @@ enum 
    OPT_STRIPCR,
    OPT_NORMAL,
    OPT_LEFTC,
@@ -477,7 +477,7 @@
  		break;
  	}
  }
-@@ -585,6 +673,7 @@ print_status(int val, char *path1, char
+@@ -585,6 +673,7 @@ print_status(int val, char *path1, char 
  void
  usage(void)
  {
@@ -485,9 +485,25 @@
  	(void)fprintf(stderr,
  	    "usage: diff [-abdilpqTtw] [-I pattern] [-c | -e | -f | -n | -u]\n"
  	    "            [-L label] file1 file2\n"
+diff -rupN jhagewood/diff/diff-orig/diff.h jhagewood/diff/diff/diff.h
+--- jhagewood/diff/diff-orig/diff.h	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff/diff/diff.h	2012-06-28 02:16:56.000000000 -0400
+@@ -75,9 +75,9 @@ struct excludes {
+ 	struct excludes	*next;
+ };
+ 
+-extern int	 aflag, bflag, dflag, iflag, lflag, Nflag, Pflag, pflag, rflag,
+-		 sflag, tflag, Tflag, wflag;
+-extern int	 Bflag, strip_cr, tabsize;
++extern int	 aflag, bflag, cflag, dflag, Eflag, Fromflag, iflag, lflag, Nflag, Pflag, pflag, rflag,
++		 sflag, tflag, Tflag, Toflag, wflag;
++extern int	 Bflag, strip_cr, suppress_cl, tabsize;
+ extern int	 format, context, status;
+ extern char	 ignore_file_case;
+ extern char	*start, *ifdefname, *diffargs, *label[2], *ignore_pats;
 diff -rupN jhagewood/diff/diff-orig/diffdir.c jhagewood/diff/diff/diffdir.c
---- jhagewood/diff/diff-orig/diffdir.c	2012-06-25 12:05:52.000000000 -0400
-+++ jhagewood/diff/diff/diffdir.c	2012-06-25 12:05:52.000000000 -0400
+--- jhagewood/diff/diff-orig/diffdir.c	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff/diff/diffdir.c	2012-06-28 02:16:56.000000000 -0400
 @@ -20,14 +20,13 @@
  
  #include <sys/cdefs.h>
@@ -595,25 +611,9 @@
  
  	strlcpy(path1 + plen1, dp->d_name, MAXPATHLEN - plen1);
  	if (stat(path1, &stb1) != 0) {
-diff -rupN jhagewood/diff/diff-orig/diff.h jhagewood/diff/diff/diff.h
---- jhagewood/diff/diff-orig/diff.h	2012-06-25 12:05:52.000000000 -0400
-+++ jhagewood/diff/diff/diff.h	2012-06-26 00:19:54.000000000 -0400
-@@ -75,9 +75,9 @@ struct excludes {
- 	struct excludes	*next;
- };
- 
--extern int	 aflag, bflag, dflag, iflag, lflag, Nflag, Pflag, pflag, rflag,
--		 sflag, tflag, Tflag, wflag;
--extern int	 Bflag, strip_cr, tabsize;
-+extern int	 aflag, bflag, cflag, dflag, Eflag, Fromflag, iflag, lflag, Nflag, Pflag, pflag, rflag,
-+		 sflag, tflag, Tflag, Toflag, wflag;
-+extern int	 Bflag, strip_cr, suppress_cl, tabsize;
- extern int	 format, context, status;
- extern char	 ignore_file_case;
- extern char	*start, *ifdefname, *diffargs, *label[2], *ignore_pats;
 diff -rupN jhagewood/diff/diff-orig/diffreg.c jhagewood/diff/diff/diffreg.c
---- jhagewood/diff/diff-orig/diffreg.c	2012-06-25 17:19:12.000000000 -0400
-+++ jhagewood/diff/diff/diffreg.c	2012-06-27 14:31:58.000000000 -0400
+--- jhagewood/diff/diff-orig/diffreg.c	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff/diff/diffreg.c	2012-06-28 02:16:56.000000000 -0400
 @@ -62,15 +62,13 @@
   *	@(#)diffreg.c   8.1 (Berkeley) 6/6/93
   */
@@ -677,7 +677,7 @@
  
  	anychange = 0;
  	lastline = 0;
-@@ -353,7 +357,6 @@ diffreg(char *ofile1, char *ofile2, int
+@@ -353,7 +357,6 @@ diffreg(char *ofile1, char *ofile2, int 
  		status |= 2;
  		goto closem;
  	}
@@ -685,7 +685,7 @@
  	switch (files_differ(f1, f2, flags)) {
  	case 0:
  		goto closem;
-@@ -365,7 +368,7 @@ diffreg(char *ofile1, char *ofile2, int
+@@ -365,7 +368,7 @@ diffreg(char *ofile1, char *ofile2, int 
  		goto closem;
  	}
  
@@ -1283,8 +1283,8 @@
 +			file2, buf2);	
  }
 diff -rupN jhagewood/diff/diff-orig/pathnames.h jhagewood/diff/diff/pathnames.h
---- jhagewood/diff/diff-orig/pathnames.h	2012-06-25 12:05:52.000000000 -0400
-+++ jhagewood/diff/diff/pathnames.h	2012-06-26 00:51:36.000000000 -0400
+--- jhagewood/diff/diff-orig/pathnames.h	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff/diff/pathnames.h	2012-06-28 02:16:56.000000000 -0400
 @@ -23,4 +23,5 @@
  #include <paths.h>
  

Modified: soc2012/jhagewood/diff3/hagewood-diff3.patch
==============================================================================
--- soc2012/jhagewood/diff3/hagewood-diff3.patch	Thu Jun 28 01:04:59 2012	(r238436)
+++ soc2012/jhagewood/diff3/hagewood-diff3.patch	Thu Jun 28 02:39:33 2012	(r238437)
@@ -1,6 +1,17 @@
+diff -rupN jhagewood/diff3/diff3-orig/Makefile jhagewood/diff3/diff3/Makefile
+--- jhagewood/diff3/diff3-orig/Makefile	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff3/diff3/Makefile	2012-06-28 02:16:57.000000000 -0400
+@@ -6,6 +6,6 @@ BINDIR=	/usr/libexec
+ 
+ beforeinstall:
+ 	install ${INSTALL_COPY}c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
+-	    ${.CURDIR}/diff3.ksh ${DESTDIR}/usr/bin/diff3
++	    ${.CURDIR}/diff3.sh ${DESTDIR}/usr/bin/diff3
+ 
+ .include <bsd.prog.mk>
 diff -rupN jhagewood/diff3/diff3-orig/diff3prog.c jhagewood/diff3/diff3/diff3prog.c
---- jhagewood/diff3/diff3-orig/diff3prog.c	2012-06-25 12:05:52.000000000 -0400
-+++ jhagewood/diff3/diff3/diff3prog.c	2012-06-25 12:05:52.000000000 -0400
+--- jhagewood/diff3/diff3-orig/diff3prog.c	2012-06-28 02:16:56.000000000 -0400
++++ jhagewood/diff3/diff3/diff3prog.c	2012-06-28 02:16:57.000000000 -0400
 @@ -64,19 +64,23 @@
   *	@(#)diff3.c	8.1 (Berkeley) 6/6/93
   */
@@ -455,14 +466,3 @@
 +	fprintf(stderr, "usage: diff3 %s file1 file2 file3\n", OPTIONS);
  	exit(EXIT_FAILURE);
  }
-diff -rupN jhagewood/diff3/diff3-orig/Makefile jhagewood/diff3/diff3/Makefile
---- jhagewood/diff3/diff3-orig/Makefile	2012-06-25 12:05:52.000000000 -0400
-+++ jhagewood/diff3/diff3/Makefile	2012-06-25 12:05:52.000000000 -0400
-@@ -6,6 +6,6 @@ BINDIR=	/usr/libexec
- 
- beforeinstall:
- 	install ${INSTALL_COPY}c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} \
--	    ${.CURDIR}/diff3.ksh ${DESTDIR}/usr/bin/diff3
-+	    ${.CURDIR}/diff3.sh ${DESTDIR}/usr/bin/diff3
- 
- .include <bsd.prog.mk>

Modified: soc2012/jhagewood/mdocml/hagewood-mdocml-ns.patch
==============================================================================
--- soc2012/jhagewood/mdocml/hagewood-mdocml-ns.patch	Thu Jun 28 01:04:59 2012	(r238436)
+++ soc2012/jhagewood/mdocml/hagewood-mdocml-ns.patch	Thu Jun 28 02:39:33 2012	(r238437)
@@ -1,6 +1,6 @@
 diff -rupN jhagewood/mdocml/mdocml-1.12.1-orig/man.h jhagewood/mdocml/mdocml-1.12.1/man.h
---- jhagewood/mdocml/mdocml-1.12.1-orig/man.h	2012-06-25 12:05:56.000000000 -0400
-+++ jhagewood/mdocml/mdocml-1.12.1/man.h	2012-06-25 12:05:58.000000000 -0400
+--- jhagewood/mdocml/mdocml-1.12.1-orig/man.h	2012-06-28 02:16:57.000000000 -0400
++++ jhagewood/mdocml/mdocml-1.12.1/man.h	2012-06-28 02:16:58.000000000 -0400
 @@ -43,6 +43,8 @@ enum	mant {
  	MAN_sp,
  	MAN_nf,
@@ -12,7 +12,7 @@
  	MAN_DT,
 diff -rupN jhagewood/mdocml/mdocml-1.12.1-orig/man.h.orig jhagewood/mdocml/mdocml-1.12.1/man.h.orig
 --- jhagewood/mdocml/mdocml-1.12.1-orig/man.h.orig	1969-12-31 19:00:00.000000000 -0500
-+++ jhagewood/mdocml/mdocml-1.12.1/man.h.orig	2012-06-25 12:05:58.000000000 -0400
++++ jhagewood/mdocml/mdocml-1.12.1/man.h.orig	2012-06-28 02:16:58.000000000 -0400
 @@ -0,0 +1,113 @@
 +/*	$Id: man.h,v 1.60 2012/01/03 15:16:24 kristaps Exp $ */
 +/*
@@ -128,8 +128,8 @@
 +
 +#endif /*!MAN_H*/
 diff -rupN jhagewood/mdocml/mdocml-1.12.1-orig/man_term.c jhagewood/mdocml/mdocml-1.12.1/man_term.c
---- jhagewood/mdocml/mdocml-1.12.1-orig/man_term.c	2012-06-25 12:05:56.000000000 -0400
-+++ jhagewood/mdocml/mdocml-1.12.1/man_term.c	2012-06-25 12:05:58.000000000 -0400
+--- jhagewood/mdocml/mdocml-1.12.1-orig/man_term.c	2012-06-28 02:16:57.000000000 -0400
++++ jhagewood/mdocml/mdocml-1.12.1/man_term.c	2012-06-28 02:16:58.000000000 -0400
 @@ -82,6 +82,8 @@ static	int		  pre_alternate(DECL_ARGS);
  static	int		  pre_ft(DECL_ARGS);
  static	int		  pre_ign(DECL_ARGS);
@@ -173,7 +173,7 @@
  static int
 diff -rupN jhagewood/mdocml/mdocml-1.12.1-orig/man_term.c.orig jhagewood/mdocml/mdocml-1.12.1/man_term.c.orig
 --- jhagewood/mdocml/mdocml-1.12.1-orig/man_term.c.orig	1969-12-31 19:00:00.000000000 -0500
-+++ jhagewood/mdocml/mdocml-1.12.1/man_term.c.orig	2012-06-25 12:05:58.000000000 -0400
++++ jhagewood/mdocml/mdocml-1.12.1/man_term.c.orig	2012-06-28 02:16:58.000000000 -0400
 @@ -0,0 +1,1117 @@
 +/*	$Id: man_term.c,v 1.127 2012/01/03 15:16:24 kristaps Exp $ */
 +/*



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20120628023934.5F7E9106566B>