[sword-devel] Comparing Verses

Chris Little chrislit at crosswire.org
Wed Jan 18 15:23:40 MST 2006



DM Smith wrote:
> Someone has ported the GNU diff algorithm to Java (see 
> http://www.bmsi.com/java/Diff.java)
> It is written as the diff of two arrays.
> I compared the code against analyze.c in GNU's diffutils and it looks 
> like a straightforward port.
> I think it would be trivial to port it to C++.
> 
> Appropriately, it is licensed with the GPL license.

I think I might be more inclined to use a BSD licensed version of diff 
as a basis and to re-write the wdiff functionality so that we own it. 
Even if we go the GNU diff route, we might want to rewrite wdiff anyway 
since it does fairly little and could be handled better with code 
specialized to our needs. (E.g. should we necessarily present "heaven" 
vs. "heavens" as a change of a whole word? Or should we just present the 
  difference of a single character, like "heaven{+s}". You could also 
use this for orthographic variation, e.g. heaven vs. heauen (1611 KJV 
spelling) > hea{v|u}en. And we could always make this flexible and 
user-selectable.)

But the main reason I'd prefer a BSD licensed version of diff would be 
that we actually have the potential of having all third-party code be 
BSD/MIT/Apache/LGPL. The only exception, currently, is GNU regexp, I 
believe. Once we get a replacement for that (probably by using either 
ICU's Regex functionality or a BSD version of regexp), we'll have the 
ability to permit groups to do non-GPL licensing from us (e.g. if ABS 
wanted to do a branded version of BibleCS). There are no explicit plans 
for anything like this (and, no, certainly no one has suggested making 
Sword closed-source), but it would be nice to maintain the possibility 
of having flexible licensing if we have the need.

--Chris




More information about the sword-devel mailing list