Fork (software development)

From Free net encyclopedia

This article is about "forking" a software development project. For other uses, see fork (disambiguation).

In software engineering, a project fork or branch happens when a developer (or a group of them) takes a copy of source code from one software package and starts to independently develop a new package. The term is also used more loosely to represent a similar branching of any work (for example, there are several forks of the English-language Wikipedia), particularly with free or open source software.

Forks with free software result from a schism over different goals or personality clashes. In a fork, both parties assume closely identical copyrights but typically only the larger group, or that containing the original architect, will retain the full original name and its associated user community. Thus there is a reputation penalty associated with forking.

In proprietary software, the rights to the common code are shared; but this is rarer, as usually there are strict copyright terms associated with the source code. More commonly, a developer internally forks the code to develop two versions, such as a windowed version and a command line version.

A fork that is standard practice in many projects are stable or release versions which are modified only for bug fixes, while a development tree develops new features. This is common practice in the Linux kernel, for instance, but has been misrepresented occasionally in the trade press as the more problematic sort of fork described above. [1]

In some cases, a fork can merge back into the original project or replace it. EGCS (Experimental/Enhanced GNU Compiler System) was a fork from GCC which proved more vital than the original project and was eventually "blessed" as the official GCC project.

Forks are considered an expression of the freedom made available by free software and a weakness since they duplicate development efforts or can confuse users over which forked package to use. Developers have the option to collaborate and pool resources with free software but it is not ensured by free software licenses but only by a commitment to cooperation.

The relationship between the different teams can be cordial or very bitter. For instance, the author of the LMule file-sharing program for Linux was uninterested in porting it to other systems, the xMule team started a fork to do so. Disagreements among the developers led to xMule itself being forked into aMule, and the tension between the developers persisted.

On the matter of forking, the Jargon File says:

"Forking is considered a Bad Thing — not merely because it implies a lot of wasted effort in the future, but because forks tend to be accompanied by a great deal of strife and acrimony between the successor groups over issues of legitimacy, succession, and design direction. There is serious social pressure against forking. As a result, major forks (such as the Gnu-Emacs/XEmacs split, the fissionings of the 386BSD group into three daughter projects, and the short-lived GCC/EGCS split) are rare enough that they are remembered individually in hacker folklore."

Because of the ease of forking a project but the challenge of continuing to develop and support it, it's common for forks without extensive resources to become inactive — for instance, see GoneME, a fork of GNOME by a former developer, which was shortly discontinued despite attracting some publicity. Some well-known forks have enjoyed great success, however, such as the X.Org X11 server, a fork from XFree86. Most distributions have switched to X.Org, and overall X11 development has sped up as well.

Other examples

  • Enciclopedia Libre,a fork of the Spanish-language Wikipedia, was created to evade possible advertising.
  • Pretty Good Privacy was forked outside of the United States to free it from the restrictive laws on the exportation of cryptographic software.
  • The many varieties of proprietary UNIX — all derived from AT&T UNIX and all called "UNIX", but increasingly mutually incompatible. See UNIX wars.
  • The game NetHack has spawned a number of variants using the original code, notably Slash'EM. (Nethack was influenced by Rogue, but its code was written independently.)
  • OpenSSH was a fork from SSH, which happened because the license for SSH 2.x was non-free (even though the source was available), so an older version of SSH 1.x, the last to have been licensed as free software, was forked. Within months, virtually all Linux distributions, BSD versions and even some proprietary Unixes had replaced SSH with OpenSSH.
  • Apple Computer's WebCore is a fork of KDE's KHTML 3.1. This technology is used in two web browsers: Safari and Konqueror. In this case, open source code became integral to a proprietary project.


References

de:Fork (Projektaufspaltung) fr:Fork pl:Fork