blob: 9fe61dee0dc34731cc7499609a74bbab10ee2c37 [file] [log] [blame]
gdtd9fd04c2003-12-19 19:20:25 +00001-*- mode: text; -*-
2
paul85cf0a02004-01-09 16:34:54 +00003$Id: HACKING,v 1.5 2004/01/09 16:34:54 paul Exp $
gdtd9fd04c2003-12-19 19:20:25 +00004
5GUIDELINES FOR HACKING ON QUAGGA
6
gdtd9fd04c2003-12-19 19:20:25 +00007[this is a draft in progress]
8
9Generally, GNU coding standards apply. The indentation style is a bit
10different from standard GNU style, and the existing style should be
11maintained and used for new code.
12
gdt2934f282004-01-05 20:09:00 +000013Be particularly careful not to break platforms/protocols that you
14cannot test.
15
16New code should have good comments, and changes to existing code
17should in many cases upgrade the comments when necessary for a
18reviewer to conclude that the change has no unintended consequences.
19
20CHANGELOG
21
22Add a ChangeLog entry whenever changing code, except for minor fixes
23to a commit (with a ChangeLog entry) within the last few days.
24
25There is at present a mixed style for ChangeLog, with some changes
26being described in per-directory ChangeLog files, and some at top
27level.
28
29[TBD: resolve per-dir vs top-level, perhaps by reading GNU coding
30standards]
31
gdtd9fd04c2003-12-19 19:20:25 +000032PATCH SUBMISSION
33
paul85cf0a02004-01-09 16:34:54 +000034* Send a clean diff against the head of CVS in unified diff format, eg by:
35 cvs <cvs opts> diff -uwb ....
gdtd9fd04c2003-12-19 19:20:25 +000036
37* Include ChangeLog and NEWS entries as appropriate before the patch
38 (or in it if you are 100% up to date).
39
40* Inclue only one semantic change or group of changes per patch.p
41
paul85cf0a02004-01-09 16:34:54 +000042* Do not make gratuitous changes to whitespace. See the w and b arguments
43 to diff.
gdtd9fd04c2003-12-19 19:20:25 +000044
45* State on which platforms and with what daemons the patch has been
46 tested. Understand that if the set of testing locations is small,
47 and the patch might have unforeseen or hard to fix consequences that
48 there may be a call for testers on quagga-dev, and that the patch
49 may be blocked until test results appear.
50
51 If there are no users for a platform on quagga-dev who are able and
52 willing to verify -current occasionally, that platform may be
53 dropped from the "should be checked" list.
54
55PATCH APPLICATION TO CVS
56
57* Only apply patches that meet the submission guidelines.
58
59* If a patch is large (perhaps more than 100 new/changed lines), tag
60 the repository before and after the change with e.g. before-foo-fix
61 and after-foo-fix.
62
63* If the patch might break something, issue a call for testing on the
64 mailinglist.
65
66* By committing a patch, you are responsible for fixing problems
67 resulting from it (or backing it out).
68
69STABLE PLATFORMS AND DAEMONS
70
71The list of platforms that should be tested follow. This is a list
72derived from what quagga is thought to run on and for which
73maintainers can test or there are people on quagga-dev who are able
74and willing to verify that -current does or does not work correctly.
75
76 BSD (Free, Net or Open, any platform) # without capabilities
77 GNU/Linux (any distribution, i386)
78 [future: some 64-bit machine, e.g. NetBSD/sparc64]
79 [Solaris? (could address 64-bit issue)]
80
81The list of daemons that are thought to be stable and that should be
82tested are:
83
84 zebra
85 bgpd
86 ripd
87 ospfd
88 ripngd
gdt1f431d22003-12-22 15:45:01 +000089
jardin9e867fe2003-12-23 08:56:18 +000090IMPORT OR UPDATE VENDOR SPECIFIC ROUTING PROTOCOLS
91
92The source code of Quagga is based on two vendors:
93
94 zebra_org (http://www.zebra.org/)
95 isisd_sf (http://isisd.sf.net/)
96
97In order to import source code, the following procedure should be used:
98
99* Tag the Current Quagga CVS repository:
100
101 cvs tag import_isisd_sf_20031223
102
103* Import the source code into the Quagga's framework. You must not modified
104 this source code. It will be merged later.
105
106 cd dir_isisd
107 export CVSROOT=:pserver:LOGIN@anoncvs.quagga.net:/var/cvsroot
108 cvs import quagga/isisd isisd_sf isisd_sf_20031223
109 ---COMMENTS---
110 Vendor: [isisd_sf] Sampo's ISISd from Sourceforge
111 Tag: [isisd_sf_20031217] Current CVS release
112 ---
113
114* Update your Quagga's directory:
115
116 cd dir_quagga
117 cvs update -dP
118
119 or
120
121 cvs co -d quagga_isisd quagga
122
123* Merge the code, then commit:
124
125 cvs commit
126