Final read-through. This is ready to go.
[to_fork_or_not] / to_fork_or_not_to_fork.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3   "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4
5 <article id="paper-11194">
6   <articleinfo>
7     <title>To Fork or Not To Fork</title>
8     <subtitle>Lessons From Ubuntu and Debian</subtitle>
9     <author>
10       <firstname>Benjamin</firstname>
11       <othername>Mako</othername>
12       <surname>Hill</surname>
13       <affiliation>
14         <orgname>Canonical Limited</orgname>
15       </affiliation>
16       <affiliation>
17         <orgname>The Debian GNU/Linux Project</orgname>
18       </affiliation>
19       <affiliation>
20         <orgname>Software in the Public Interest, Inc.</orgname>
21       </affiliation>
22
23       <authorblurb>
24         <para>Benjamin Mako Hill is an intellectual property
25           researcher and activist and a professional Free/Open Source
26           Software (FOSS) advocate and developer. He is active
27           participant in the Debian Project in both technical and
28           non-technical roles. He is the author of the Free Software
29           Project Management HOWTO and many published works on Free
30           and Open Source Software. He currently is working full time
31           for Canonical Ltd. on Ubuntu, a new Debian-based
32           distribution.</para>
33       </authorblurb>
34
35     </author>
36
37     <copyright>
38       <year>2005</year>
39       <holder>Benjamin Mako Hill</holder>
40     </copyright>
41   </articleinfo>
42
43   <section>
44     <title>Introduction</title>
45   
46     <para>The explosive growth of free and open source software over
47       the last decade has been mirrored by an equally explosive growth
48       in the ambitiousness of free software projects in choosing and
49       tackling problems. The free software movement approaches these
50       large problems with more code and with more expansive
51       communities than was thinkable a decade ago. Example of these
52       massive projects include desktop environments &mdash; like GNOME
53       and KDE &mdash; and distributions like Debian, RedHat, and
54       Gentoo.</para>
55
56     <para>These projects are leveraging the work of thousands of
57       programmers &mdash; both volunteer and paid &mdash; and are
58       producing millions of lines of code. Their software is being
59       used by millions of users with diverse sets of needs. This
60       paper focuses on two major effects of this situation:</para>
61
62     <itemizedlist>
63       <listitem>
64
65         <para>The communities that free software projects &mdash; and
66           in particular large projects &mdash; serve are increasingly
67           diverse.  It is becoming increasingly difficult for a single
68           large project to release any single product that can cater
69           to all of its potential users.</para>
70
71       </listitem>
72       <listitem>
73
74         <para>It's becoming increasingly difficult to reproduce these
75           large projects. While reproducing entire project is
76           impossible for small groups of hackers, it is often not even
77           possible for small groups to even track and maintain a fork
78           of a large project over time.</para>
79
80       </listitem>
81     </itemizedlist>
82
83     <para>Taken together, these facts imply an increasingly realized
84       free software community in which programmers frequently derive
85       but where traditional forking is often untenable.  "Forks," as
86       they are traditionally defined, must be improved upon.
87       Communities around large free software projects must be smarter
88       about the process of derivation than they have been in the
89       past.</para>
90
91     <para>We are already seeing this with GNU/Linux distributions. New
92       distributions are rarely built from scratch today. Instead, they
93       adapted from and built on top of the work of existing projects.
94       As projects and user-bases grow, these derived distributions are
95       increasingly common. Most of what I describe in this essay are
96       tools and experiences of derived distributions.</para>
97
98     <para>Software makers must pursue the idea of an
99       <emphasis>ecosystem</emphasis> of free software projects and
100       products that have forked but that maintain a close relationship
101       as they develop parallelly and symbiotically. To do this,
102       developers should:</para>
103
104     <itemizedlist>
105       <listitem>
106         <para>Break down the process of derivation into a set of
107           different types of customization and derivation and
108           prioritize methods of derivation.</para>
109       </listitem>
110       <listitem>
111         <para>Create and foster social solutions to the social aspects
112           of the derivation problem.</para>
113       </listitem>
114       <listitem>
115         <para>Build and use new tools specifically designed to
116           coordinate development of software in the context of an
117           ecosystem of projects.</para>
118       </listitem>
119       <listitem>
120         <para>Distribute and utilize distributed version control tools
121           with an emphasis on maintaining differences over
122           time.</para>
123       </listitem>
124     </itemizedlist>
125
126     <para>This paper is an early analysis of this set of problems. As
127       such, it is highly focused on the experience of the Ubuntu
128       project and its existence as a derived Debian distribution. It
129       also pulls from my experience with Debian-NP and the Custom
130       Debian Distribution (CDD) community. Since I participate in both
131       the Ubuntu and CDD projects, these are areas that I can discuss
132       with some degree of knowledge and experience.</para>
133   </section>
134
135   <section>
136     <title>"Fork" Is A Four Letter Word</title>
137
138     <para>The act of taking the code for a free software project and
139       bifurcating it to create a new project is called "forking."
140       There have been a number of famous forks in free software
141       history. One of the most famous was the schism that led to the
142       parallel development of two versions of the Emacs text editor:
143       GNU Emacs and XEmacs. This schism persists to this day.</para>
144
145     <para>Some forks, like Emacs and XEmacs, are permanent. Others are
146       relatively short lived. An example of this is the GCC project
147       which saw two forks &mdash; EGCS and PGCC &mdash; that both
148       eventually merged back into GCC. Forking can happen for any
149       number of reasons. Often developers on a project develop
150       political or personal differences that keep them from continuing
151       to work together. In some cases, maintainers become unresponsive
152       and other developers fork to keep the software alive.</para>
153
154     <para>Ultimately though, most forks occur because people do not
155       agree on the features, the mechanisms, or the technology at the
156       core of a project. People have different goals, different
157       problems, and want different tools. Often, these goals, problems
158       and tools are similar up until a certain point before the need
159       to part ways becomes essential.</para>
160
161     <para>A fork occurs on the level of code but a fork is not merely
162       &mdash; or even primarily &mdash; technical. Many projects create
163       "branches." Branches are alternative versions of a piece of
164       software used to experiment with intrusive or unstable features
165       and fixes. Forks are distinguished from branches both in
166       that they are often more significant departures from a technical
167       perspective (i.e., more lines of code have been changed and/or
168       the changes are more invasive or represent a more fundamental
169       rethinking of the problem) and in that they are bifurcations
170       defined in social and political terms. Branches involve a
171       <emphasis>single</emphasis> developer or community of developers
172       &mdash; even if it does boil down to distinct subgroups within a
173       community &mdash; whereas forks are separate projects.</para>
174
175     <para>Forking has historically been viewed as a bad thing in free
176       software communities: they are seen to stem from people's
177       inability to work together and have ended in reproduction of
178       work. When I published the first version of the <ulink
179         url="http://mako.cc/projects/howto/">Free Software Project
180         Management HOWTO</ulink> more than four years ago, I included
181       a small subsection on forking which described the concept to
182       future free software project leaders with this text:</para>
183
184     <blockquote>
185       <para>The short version of the fork section is, don't do them.
186         Forks force developers to choose one project to work with,
187         cause nasty political divisions, and redundancy of
188         work.</para>
189     </blockquote>
190
191     <para>In the <emphasis>best</emphasis> situations, a fork means
192       that two groups of people need to go on developing features and
193       doing work they would ordinarily do <emphasis>in addition
194         to</emphasis> tracking the forked project and having to
195       hand-select and apply features and fixes to their own code-base.
196       This level of monitoring and constant comparison can be
197       extremely difficult and time-consuming. The situation is not
198       helped substantially by traditional source control tools like
199       diff, patch, CVS and Subversion which are not optimized for this
200       task. The worse (and much more common) situation occurs when two
201       groups go about their work ignorant or partially ignorant of the
202       code bieng cut on the other side of the fork. Important features
203       and fixes are implemented twice &mdash; differently and
204       incompatibly.</para>
205
206     <para>The most substantial bright side to these drawbacks is that
207       the problems associated with forking are so severe and notorious
208       that, in most cases, the threat of a fork is enough to force
209       maintainers to work out solutions that keep the fork from
210       happening in the first place.</para>
211
212     <para>Finally, it is worth pointing out that fork is something of
213       a contested term. Because definitions of forks involve, to one
214       degree or another, statements about the political, organization,
215       and technical distinctions between projects, bifurcations that
216       many people call branches or parallel trees are described by
217       others as forks. Recently, fueled by the advent of distributed
218       version control systems, the definition of what is and is not a
219       fork has become increasingly unclear. In part due to the same
220       systems, the benefits and drawbacks of what is increasingly
221       problematically called forking is equally debatable.</para>
222
223   </section>
224
225   <section>
226     <title>Case Study</title>
227
228     <para>In my introduction, I described how the growing scope of
229       free software projects and the rapidly increasingly size and
230       diversity of user communities is spearheading the need for new
231       type of derivation that avoids, as best as possible, the
232       drawbacks of forking. Nowhere is this more evident than in the
233       largest projects with the broadest scope: a small group of
234       projects that includes operating system distributions.</para>
235
236
237     <section>
238       <title>The Debian Project</title>
239
240       <para>The Debian project is by many counts the largest free
241         software distribution in terms of code. It is the also,
242         arguably, the largest free software project in terms of the
243         number of volunteers. Debian includes more than 15,000
244         packages and the work of well over 1,000 official volunteers
245         and many more contributors without official membership.
246         Projects without Debian's massive volunteer base cannot
247         replicate what Debian has accomplished; they can rarely hope
248         to even maintain what Debian has produced.</para>
249
250       <para>At the time that this paper was written, Distrowatch lists
251         129 distributions based on Debian<footnote>
252           <para>Information is listed on the distrowatch homepage
253             here: <ulink
254               url="http://distrowatch.com/dwres.php?resource=independence">http://distrowatch.com/dwres.php?resource=independence</ulink></para>
255
256         </footnote> &mdash; most of them currently active to varying
257         degrees. Each distribution represents at least one person &mdash;
258         and in most cases a community of people &mdash; who disagreed with
259         Debian's vision or direction strongly enough to want to create
260         a new distribution <emphasis>and</emphasis> who had the
261         technical capacity to follow through with this goal. Despite
262         Debian's long-standing slogan &mdash; "the universal operating
263         system" &mdash; the fact that the Debian project has become the
264         fastest growing operating system while spawning so many
265         derivatives is testament to the fact that, as far as software
266         is concerned, one size <emphasis>can not</emphasis> fit
267         all.<footnote>
268           <para>Netcraft posts yearly updates on the speed at which
269             Linux distributions are growing. The one in question can
270             be found at: <ulink
271               url="http://news.netcraft.com/archives/2004/01/28/debian_fastest_growing_linux_distribution.html">http://news.netcraft.com/archives/2004/01/28/debian_fastest_growing_linux_distribution.html</ulink></para>
272         </footnote>
273       </para>
274
275
276       <para>Organizationally, Debian derivers are located both inside
277         and outside of the Debian project. A group of derivers working
278         within the Debian project has labeled themselves "Custom
279         Debian Distributions" and has created nearly a dozen projects
280         customizing and deriving from Debian for specific groups of
281         users including non-profit organization, the medical
282         community, lawyers, children and many others.<footnote>
283           <para>I spearheaded and help build a now mostly defunct
284             derivation of Debian called Debian-Nonprofit (Debian-NP)
285             geared for non-profit organizations by working within the
286             Debian project.</para>
287         </footnote> These projects build on the core Debian distribution and
288         the canonical archive from <emphasis>within</emphasis> the
289         organizational and political limits of the Debian project and
290         constantly seek to minimize the delta by focusing on less
291         invasive changes and by advancing creative ways of building
292         the <emphasis>ability</emphasis> to alter the core
293         Debian code base through established and policy compliant
294         procedures.</para>
295
296 <!-- http://linktocddinformation -->
297
298       <para>A second group of Debian customizers includes those
299         working outside of the Debian project organizationally.
300         Notable among this list are (in alphabetical order) Knoppix,
301         Libranet, Linspire (formerly Lindows), Progeny, MEPIS, Ubuntu,
302         Userlinux, and Xandros. With its strong technological base,
303         excellent package management, wide selection of packages to
304         choose from, and strong commitment to software freedom which
305         ensures derivability, Debian provides an ideal point from
306         which to create a GNU/Linux distribution.</para>
307
308     </section>
309
310
311     <section>
312       <title>Ubuntu</title>
313
314       <para>The Ubuntu project was started by Mark Shuttleworth in
315         April 2004 and the first version was built almost entirely
316         by a small group of a Debian developers employed by Shuttleworth's
317         company Canonical Limited.<footnote>
318           <para>Information Ubuntu can be found on the <ulink
319               url="http://www.ubuntu.com">Ubuntu homepage.</ulink>
320             Information Canonical Limited can be found at <ulink
321               url="http://www.canonical.com">Canonical's
322               homepage</ulink>.</para>
323         </footnote> It was released to the world in late 2004.
324         The second version was released six months later in April
325         2005. The goals of Ubuntu are to provide a distribution based
326         on a subset of Debian with:</para>
327
328       <itemizedlist>
329         <listitem>
330           <para>Regular and predictable releases &mdash; every six months
331             with support for eighteen months.</para>
332         </listitem>
333         <listitem>
334           <para>An emphasis on free software that will maintain the
335             derivability of the distribution.</para>
336         </listitem>
337         <listitem>
338           <para>An emphasis on usability and a consistent desktop
339             vision. As an example, this has translated into less
340             questions in the installer and a default selection and
341             configuration of packages that is usable for most desktop
342             users "out of the box."</para>
343         </listitem>
344
345       </itemizedlist>
346
347       <para>The Ubuntu project provides an interesting example of a
348         project that aims to derive from Debian to an extensive
349         degree. Ubuntu made code-level changes to nearly 1300 packages
350         in Debian at the time that this paper was written and the
351         speed of changes will not decelerate with time; the total
352         number of changes and the total size of the delta will
353         grow.<footnote>
354           <para>Scott James Remnant maintains a list of these patches
355             online here: <ulink
356               url="http://people.ubuntu.com/~scott/patches/">http://people.ubuntu.com/~scott/patches/</ulink></para>
357         </footnote> The changes that Ubuntu makes are primarily of the
358         most intrusive kind &mdash; changes to the code itself.</para>
359
360       <para>That said, the Ubuntu project is explicit about the fact
361         that it could not exist with the work done by the Debian
362         project.<footnote>
363           <para>You can see that explicit statement on Ubuntu's
364             website here: <ulink
365               url="http://www.ubuntulinux.org/ubuntu/relationship/">http://www.ubuntulinux.org/ubuntu/relationship/</ulink></para>
366         </footnote> More importantly, Ubuntu explains that it cannot
367         continue to provide the complete set of packages that its
368         users depend on without the ongoing work by the Debian
369         project. Even though Ubuntu has made changes to the nearly
370         1300 packages, this is less than ten percent of the total
371         packages shipped in Ubuntu and pulled from Debian.</para>
372
373       <para>Scott James Remnant, a prominent Debian developer and a
374         hacker on Ubuntu who works for Canonical Ltd., described the
375         situation this way on his web log to introduce the Ubuntu
376         development methodology in the week after first public
377         announcement of Canonical and Ubuntu:<footnote>
378           <para>The entire post can be read here: <ulink
379               url="http://www.netsplit.com/blog/work/canonical/ubuntu_and_debian.html">http://www.netsplit.com/blog/work/canonical/ubuntu_and_debian.html</ulink></para>
380         </footnote>
381       </para>
382
383       <blockquote>
384
385         <para>I don't think Ubuntu is a "fork" of Debian, at least not
386           in the traditional sense.  A fork suggests that at some
387           point we go our separate way from Debian and then
388           occasionally merge in changes as we carry on down our own
389           path.</para>
390
391         <para>Our model is quite different; every six months we take a
392           snapshot of Debian's unstable distribution, apply any
393           outstanding patches from our last release to it and spend a
394           couple of months testing and bug-fixing it.</para>
395
396
397         <para>
398           <inlinemediaobject>
399             <imageobject>
400               <imagedata fileref="tfontf-picture-01.png" format="PNG"/>
401             </imageobject>
402           </inlinemediaobject>
403         </para>
404
405         <para>One thing that should be obvious from this is our job is
406           a lot easier if Debian take all of our changes, the model
407           actually encourages us to give back to Debian.</para>
408
409         <para>That's why from the very first day we started fixing
410           bugs we began sending <ulink
411             url="http://www.no-name-yet.com/patches/">the
412             patches</ulink> back to Debian through the BTS.  Not only
413           will it make our job so much easier when we come to freeze
414           for "hoary", our next release, but it's exactly what every
415           derivative should do in the first place.</para>
416
417       </blockquote>
418
419       <para>There is some debate on the degree to which Ubuntu
420         developers have succeeded in accomplishing the goals laid out
421         by Remnant. Ubuntu has filed hundreds of patches in the bug
422         tracking system but it has also run into problems in deciding
423         <emphasis>what</emphasis> constitutes something that should be
424         fed back to Debian. Many changes are simply not relevant to
425         Debian developers. For example, they may include changes to a
426         package in response to another change made in another package
427         in Ubuntu that will not or has not been taken by Debian. In
428         many other cases, the best action in regards to a particular
429         change, a particular package, and a particular upstream Debian
430         developer is simply unclear.</para>
431
432       <para>The Ubuntu project's track record in working
433         constructively with Debian is, at the moment, a mixed one.
434         While an increasingly large number of Debian developers are
435         maintaining their packages actively within both projects, many
436         in both Debian and Ubuntu feel that Ubuntu has work left to do
437         in living up to its own goal of a completely smooth productive
438         relationship with Debian.</para>
439
440       <para>That said, the importance of the goals described by
441         Remnant in the context of of the Ubuntu development model
442         cannot be overstated. Ever line of delta between Debian and
443         Ubuntu has a cost for Ubuntu developers. Technology, social
444         practices, and wise choices may reduce that cost but it cannot
445         eliminate it. The resources that Ubuntu can bring to bear upon
446         the problem of building a distribution are limited &mdash; far
447         more limited than Debian's. As a result, there is a limit to
448         how far Ubuntu can diverge; it is always in Ubuntu's advantage
449         to minimize the delta where possible.</para>
450
451     </section>
452
453     <section>
454       <title>Applicability</title>
455
456       <para>Ubuntu and Debian are distributions and &mdash; as such
457         &mdash; operate on a different scale than the vast majority of
458         free software projects. They include more code and more
459         people. As a result, there are questions as to whether the
460         experiences and lessons learned from these projects are
461         particularly applicable to the experience of smaller free
462         software projects.</para>
463
464       <para>Clearly, because of the difficulties associated with
465         forking massive amount of code and the problems associated
466         with duplicating the work of large volunteer bases,
467         distributions are forced into finding a way to balance the
468         benefits and drawbacks of forking. However, while the need is
469         stronger and more immediate in larger projects, the benefits
470         of their solutions will often be fully transferable.</para>
471
472       <para>Clearly, modifiability of free software to better fit the
473         needs of its users lies at the heart of the free software
474         movement's success. However, while modification usually comes
475         in the form of collaboration on a single code-base, this is
476         function of limitations in software development methodologies
477         and tools rather than the best response to the needs or
478         desires of users or developers.</para>
479
480       <para>I believe that the fundamental advantage of free software
481         in the next decade will be in the growing ability of any
482         single free software project to be multiple things to multiple
483         users simultaneously. This will translate into the fact that,
484         in the next ten years, technology and social processes will
485         evolve so that forking is increasingly less of a bad thing.
486         Free software development methodology will become less
487         dependent on a single project and begin to emphasize parallel
488         development within an ecosystem of related projects. The
489         result is that free software projects will gain a competitive
490         advantage over propriety software projects through their
491         ability to better serve the increasingly diverse needs of
492         increasingly large and increasingly diverse user-bases.
493         Although it sounds paradoxical today, more projects will
494         derive and less redundant code will be written.</para>
495  
496       <para>Projects more limited in code and scope may use the tools
497         and methods described in the remainder of this paper in
498         different combinations, in different ways, and to different
499         degrees than the examples around distributions introduced
500         here. Different projects with different needs will find that
501         certain solutions work better than others. Because communities
502         of the size of Debian are difficult to fork in a way that is
503         beneficial to any party, it is in these communities that the
504         technology and development methodologies are first
505         emerging. With time, these strategies and tools will find
506         themselves employed productively in a wide variety of projects
507         with a broad spectrum of sizes, needs, scopes and
508         descriptions.</para>
509
510     </section>
511
512   </section>
513
514   <section>
515     <title>Balancing Forking With Collaboration</title>
516
517     <section>
518       <title>Derivation and Problem Analysis</title>
519
520       <para>The easiest step in creating a productive derivative
521         software project is to break down the problems of derivations
522         into a series of different classes of modification. Certain
523         types of modification are more easily done and are
524         intrinsically more maintainable.</para>
525
526       <para>In the context of distributions, the problem of derivation
527         can be broken down into the following types of changes (sorted
528         roughly according to the intrusiveness inherent in solving the
529         problem and the severity of the long-term maintainability
530         problems that they introduce):</para>
531
532       <orderedlist>
533         <listitem>
534           <para>Selection of individual pieces of software;</para>
535         </listitem>
536         <listitem>
537           <para>Changes to the way that packages are installed or run
538             (e.g., in a Live CD type environment or using a different
539             installer);</para>
540         </listitem>
541         <listitem>
542           <para>Configuration of different pieces of software;</para>
543         </listitem>
544         <listitem>
545           <para>Changes made to the actual software package (made on
546             the level of changes to the packages code);</para>
547         </listitem>
548       </orderedlist>
549
550       <para>By breaking down the problem in this way. Debian derivers
551         have been able to approach derivation in ways that focus
552         energy on the less intrusive problems first.</para>
553
554       <para>The first area that Ubuntu focused on was selecting a
555         subset of packages that Ubuntu would support. Ubuntu selected
556         and supports approximate 2,000 packages. These became the
557         <command>main</command> component in Ubuntu. Other packages in
558         Debian were included in a separate section of the Ubuntu
559         archive called <command>universe</command> but were not
560         guaranteed to be supported with bug or security fixes. By
561         focusing on a small subset of packages, the Ubuntu team was
562         able to select a maintainable subsection of the Debian archive
563         that they could maintain over time.</para>
564
565       <para>The most simple derived distributions &mdash; often
566         working within the Debian project as CDDs but also including
567         projects like Userlinux &mdash; are merely lists of packages
568         and do nothing outside of package selection. The installation
569         of lists of packages and the maintenance of those lists over
570         time can be aided through the creation of what are called
571         <emphasis>metapackages</emphasis>: empty packages with long
572         lists of "dependencies."</para>
573
574       <para>The second item, configuration changes, are also
575         relatively low-impact. Focusing on moving as many changes as
576         possible into the realm of configuration changes is a
577         sustainable strategy that derivers working within the Debian
578         project intent on a single code-base have pursued actively.
579         Their idea is that rather than forking a piece of code due to
580         disagreement in how the program should work, they can leave
581         the code intact but add the <emphasis>ability</emphasis> to
582         work in a different way to the software. This alternate
583         functionality is made toggleable through a configuration
584         change in the same manner that applications are configured
585         through questions asked at install time. Since the Debian
586         project has a unified package configuration framework called
587         Debconf, derivers are able to configure an entire system in a
588         highly centralized manner.<footnote> <para>More information on
589             Debconf can be
590             found online at: <ulink
591               url="http://www.kitenet.net/programs/debconf/">http://www.kitenet.net/programs/debconf/</ulink></para>
592         </footnote> This is not unlike RedHat's Kickstart although the
593         emphasis is on maintenance of those configuration changes over
594         the life and evolution of the package; Kickstart is focused
595         merely on installation of the package.</para>
596
597       <para>A third type of configuration is limited to changes in the
598         environment through which a system is run or installed. One is
599         example is Progeny's Anaconda-based Debian installer which
600         provides an alternate installer but results in an identical
601         system. Another example is the Knoppix project which is famous
602         for its "Live CD" environments. While, Knoppix makes a wide
603         range of invasive changes that span all items in my list
604         above, other Live CD projects, including Ubuntu's "Casper"
605         project, are much closer to an alternate shell through which
606         the same code is run.</para>
607
608       <para>Because these three methods are relatively non-invasive,
609         they are reasonable strategies for small teams and individuals
610         working on creating a derived distribution. However, many
611         desirable changes &mdash; and in the case of some derived
612         distributions, <emphasis>most</emphasis> desirable changes
613         &mdash; require more invasive techniques. The final and most
614         invasive type of change &mdash; changes to code &mdash; is the
615         most difficult but also the most promising and powerful if it
616         can be done sustainably. Changes of this type involve
617         bifurcations of the code-base and will be the topic of the
618         remainder of this paper.</para>
619
620     </section>
621
622     <section>
623       <title>Distributed Source Control</title>
624
625       <para>One promising method of maintaining deltas in forked or
626         branched projects lies in distributed version control systems
627         (VCS). Traditional VCS systems work in a highly centralized
628         fashion. CVS, the archetypal free software VCS and the basis
629         for many others, is based around the model of a single
630         centralized server. Anyone who wishes to commit to a project
631         must commit to the centralized repository. While CVS allows
632         users to create branches, anyone with commit rights has access
633         to the entire repository. The tools for branching and merging
634         over time are not particularly good.</para>
635
636       <para>The branching model is primarily geared toward a system
637         where development is bifurcated and then the branch is merged
638         completely back into the main tree. Normal use of a branch
639         might include creating a development branch, making a series
640         of development releases while maintaining and fixing important
641         bugs in the stable primary branch, and then ultimately
642         replacing the stable release with the development release. The
643         CVS model is <emphasis>not</emphasis> geared toward a system
644         where an arbitrary delta, or sets of deltas, are maintained
645         over time.</para>
646
647       <para>Distributed version control aims to solve a number of
648         problems introduced by CVS and alluded to above by:</para>
649
650       <itemizedlist>
651         <listitem>
652           <para>Allowing people to work disconnected from each other
653             and to sync with each other, in whole or in part, in an
654             arbitrary and ad-hoc fashion.</para>
655         </listitem>
656         <listitem>
657           <para>Allowing deltas to be maintained over time.</para>
658         </listitem>
659       </itemizedlist>
660
661       <para>Ultimately, this requires tools that are better at merging
662         changes and in <emphasis>not</emphasis> merging certain
663         changes when that is the desired behavior. It also leads to tools capable
664         of history-sensitive merging.</para>
665
666       <para>The most famous switch to a distributed VCS model from a
667         centralized VCS model was the move by the Linux kernel
668         development community to the proprietary distributed version
669         control system BitKeeper. In his recent announcement of the
670         decision to part ways with BitKeeper, Linus Torvalds
671         said:</para>
672
673       <blockquote>
674         <para>In fact, one impact BK has had is to very fundamentally
675           make us (and me in particular) change how we do things. That
676           ranges from the fine-grained changeset tracking to just how
677           I ended up trusting sub-maintainers with much bigger things,
678           and not having to work on a patch-by-patch basis any
679           more.<footnote> <para>The full message can be read online
680               at: <ulink
681                 url="http://kerneltrap.org/mailarchive/1/message/48393/thread">http://kerneltrap.org/mailarchive/1/message/48393/thread</ulink></para>
682           </footnote>
683         </para>
684       </blockquote>
685
686       <para>At the time of the switch, free distributed version
687         control tools were less advanced than they are today. At the
688         moment, an incomplete list of free software VCS tools includes
689         GNU Arch, Bazaar, Bazaar-NG, Darcs, Monotone, SVK (based on
690         Subversion), GIT (a system developed by Linus Torvalds as a
691         temporary replacement for BitKeeper) and others.</para>
692
693       <para>Each of these tools, at least after they reach a certain
694         level of maturity, allow or will allow users to develop
695         software in a distributed fashion and to, over time, compare
696         their software and pull changes from others significantly more
697         easily than they could otherwise. The idea of parallel
698         development lies at the heart of the model, the tools for
699         merging and resolving conflicts over time, and the ability to
700         "cherry pick" certain patches or changes from a parallel
701         developer each make this type of development significantly
702         more useful than it has been in the past.</para>
703
704       <para>VCSs work entirely on the level of code. Due to the nature
705         of the types of changes that Ubuntu project is making to
706         Debian's code, Ubuntu has focused primarily on this model and
707         Canonical currently funds two major distributed control
708         products &mdash; the Bazaar and Bazaar-NG projects.</para>
709
710       <para>In many ways, employing distributed version control
711         effectively is a much easier problem to solve for small, more
712         traditional, free software development projects than it is for
713         GNU/Linux distributions. Because the problems with maintaining
714         parallel development of a single piece of software in a set of
715         related distributed repositories is the primary use case for
716         distributed version control systems, distributed VCS alone can
717         be a technical solution for certain types of parallel
718         development. As the tools and social processes for distributed
719         VCS evolve, they will become increasingly important tools in
720         the way that free software is developed.</para>
721
722       <para>Because the problems of scale associated with building an
723         entire derivative distribution are more complicated than those
724         associated with working with a single "upstream" project,
725         distributed version control is only now being actively
726         deployed in the Ubuntu project. In doing so, th project is
727         focusing on integrating these into problem specific tools
728         built on top of distributed version control.</para>
729
730     </section>
731
732     <section>
733       <title>Problem Specific Tools</title>
734
735       <para>Another technique that Canonical Ltd. is experimenting
736         with is the creation of high level tools built on top of
737         distributed version control tools specifically designed for
738         maintaining difference between packages. Because packages are
739         usually distributed as a source file with a collection of one
740         or more patches, this introduces the unique possibility of
741         creating a high-level VCS system based around this fact.</para>
742
743       <para>In the case of Ubuntu and Debian, the ideal tool creates
744         one branch per patch or feature and uses heuristics to
745         analyze patch files and create these branches
746         intelligently. The package build system section of the total
747         patch can also be kept as a separate branch. Canonical's tool,
748         called the Hypothetical Changeset Tool (HCT) (although no
749         longer hypothetical), is one experimental way of creating a
750         very simple, very streamlined interface for dealing with a
751         particular type of source that is created and distributed in a
752         particular type of way with a particular type of
753         change.</para>
754
755       <para>While HCT promises to be very useful for people making
756         derived distributions based on Debian, its application outside
757         distribution makers will, in all likelihood, be limited. That
758         said, it provides an example of the way that problem and
759         context specific tools may play an essential role in the
760         maintenance of derived code more generally.</para>
761
762     </section>
763
764
765     <section>
766       <title>Social Solutions</title>
767
768       <para>It has been said that it is a common folly of a
769         technophile to attempt to employ technical solutions toward
770         solving social problems. The problem of deriving software is
771         both a technical <emphasis>and</emphasis> a social problem and
772         adequately addressing the larger problems requires approaches that
773         take into consideration both types of solution.</para>
774
775       <para>Scott James Remnant compares the relationship between
776         distributions and derived distributions as not unlike the
777         relationship between distributions and upstream
778         maintainers:</para>
779       <blockquote>
780
781         <para>I don't think this is much different from how Debian
782           maintainers interact with their upstreams. As Debian
783           maintainers we take and package upstream software and then
784           act as a gateway for bugs and problems. Quite often we fix
785           bugs ourselves and apply the patch to the package and send
786           it upstream. Sometimes the upstream don't incorporate that
787           patch and we have to make sure we don't accidentally drop it
788           each subsequent release, we much prefer it if they take
789           them, but we don't get angry if they don't.</para>
790
791         <para>This is how I see the relationship between Ubuntu and
792           Debian, we're no more a fork of Debian than a Debian package
793           is a fork of its upstream.</para>
794       </blockquote>
795
796       <para>Scott alludes the fact that, at least in the world of
797         distributions, parallel development is already one way to view
798         the <emphasis>modus operandi</emphasis> of existing GNU/Linux
799         distributions. The relationship between a deriver and derivee
800         on the distribution level mirrors the relationship between the
801         distribution and the "upstream" authors of the packages that
802         make up the distribution. These relationships are rarely based
803         around technological tools but are entirely in the realm of
804         social solutions.</para>
805
806       <para>Ubuntu has pursued a number of different initiatives along
807         these lines. The first of these has been to regularly file
808         bugs in the Debian bug tracking system when bugs that exist in
809         Debian are fixed in Ubuntu. While this can be partially
810         automated, the choice to automate this and the manner in which
811         it it is set up is a purely social one.</para>
812
813       <para>However, as I alluded to above, Ubuntu is still left with
814         questions in regards to changes that are made to packages that
815         do not necessarily fix bugs or that fix bugs that do not exist
816         in Debian but may in the future. Some Debian developers want
817         to hear about the full extent of changes made to their
818         software in Ubuntu while others do not want to be
819         bothered. Ubuntu should continue to work with Debian to find
820         ways to allow developers to stay in sync.</para>
821
822       <para>There are also several initiatives by developers in
823         Debian, Ubuntu, and in other derivations to create a
824         stronger relationship between the Debian project and its
825         ecosystem of derivers and between Ubuntu and Debian in
826         particular. While the form that this will ultimately take is
827         unclear, projects existing within an ecosystem should explore
828         the realm of appropriate social relationships that will ensure
829         that they can work together and be informed of each others'
830         work without resorting to "spamming" each other with
831         irrelevant or unnecessary information.</para>
832
833       <para>Another issue that has recently played an important role
834         in the Debian/Ubuntu relationship is the importance of both
835         giving adequate credit to the authors or upstream maintainers
836         of software without implying a closer relationship than is the
837         case. Derivers must walk a file line where they credit others'
838         work on a project without implying that the others work for,
839         support, or are connected to the derivers project to which, for
840         any number of reasons, the "upstream" author might not want to
841         be associated.</para>
842
843       <para>In the case of Debian and Ubuntu, this has resulted in an
844         emphasis on keeping or importing changelog entries when
845         changes are imported and in noting the pedigree of changes
846         more generally. It has recently also been discussed in terms
847         of the "maintainer" field in each package in Ubuntu. Ubuntu
848         wants to avoid making changes to every unmodified source
849         package (and introducing an unnecessary delta) but does not
850         want to give the impression that the maintainer of the package
851         is someone unassociated with Ubuntu. While no solution has
852         been decided at the time of writing, one idea involved marking
853         the maintainer of the package explicitly as a Debian
854         maintainer at the time that the binary packages are built on
855         the Ubuntu build machines.</para>
856
857       <para>The emphasis on social solutions is also essential when
858         using distributed VCS technology. As Linus Torvalds alluded to
859         in the quote above, the importance of technological changes to
860         distributed VCS technology is only felt when people begin to
861         work in a different way &mdash; when they begin to employ
862         different social models of developer interaction.</para>
863
864       <para>While Ubuntu's experience can provide a good model for
865         tackling some of these source control issues, it can only
866         serve as a model and not as a fixed answer. Social solutions
867         must be appropriate for a given social relationship. Even in
868         situations where a package is branched because of social
869         disagreements, a certain level of collaboration on a social
870         level will be essential to the long term viability of the
871         derivative.</para>
872
873     </section>
874
875   </section>
876
877   <section>
878     <title>Conclusions</title>
879
880     <para>As the techniques described in this paper evolve, the role
881       that they play in free software development becomes increasingly
882       prominent and increasingly important. Joining them will be other
883       techniques and models that I have not described and cannot
884       predict.  Because of the size and usefulness of their code and
885       the size of their development communities, large projects like
886       Debian and Ubuntu have been forced into confronting and
887       attempting to mediate the problems inherent in forking and
888       deriving. However, as these problems are negotiated and tools
889       and processes are advanced toward solutions, free software
890       projects of all sizes will be able to offer users exactly what
891       they want with minimal redundancy and little duplication of
892       work. In doing this, free software will harness a power that
893       proprietary models cannot compete with. They will increase their
894       capacity to produce better products and better processes.
895       Ultimately, it will help free software capture more users, bring
896       in more developers, and produce more free software of a higher
897       quality.</para>
898
899   </section>
900
901 </article>
902
903
904 <!-- Keep this comment at the end of the file
905 Local variables:
906 mode: xml
907 sgml-omittag:t
908 sgml-shorttag:t
909 sgml-namecase-general:t
910 sgml-general-insert-case:lower
911 sgml-minimize-attributes:nil
912 sgml-always-quote-attributes:t
913 sgml-parent-document:nil
914 sgml-exposed-tags:nil
915 sgml-local-catalogs:nil
916 sgml-local-ecat-files:nil
917 sgml-indent-step: 2
918 sgml-indent-data: 2
919 sgml-set-face: t
920 End:
921 -->

Benjamin Mako Hill || Want to submit a patch?