]> git.saurik.com Git - bison.git/blame - HACKING
Add HACKING.
[bison.git] / HACKING
CommitLineData
2ed0e35f
AD
1-*- outline -*-
2
3This file attempts to describe the rules to use when hacking Bison.
4Don't put this file into the distribution. Don't mention it in the
5ChangeLog.
6
7* Administrivia
8
9** If you incorporate a change from somebody on the net:
10First, if it is a large change, you must make sure they have signed
11the appropriate paperwork. Second, be sure to add their name and
12email address to THANKS.
13
14** If a change fixes a test, mention the test in the ChangeLog entry.
15
16** Bug reports
17If somebody reports a new bug, mention his name in the ChangeLog entry
18and in the test case you write. Put him into THANKS.
19
20The correct response to most actual bugs is to write a new test case
21which demonstrates the bug. Then fix the bug, re-run the test suite,
22and check everything in.
23
24** Visible changes
25Which include serious bug fixes, must be mentioned in NEWS.
26
27
28* Test suite
29
30** make check
31Use liberally.
32
33** Release checks
34Try to run the test suite with more severe conditions before a
35release:
36
37- Configure the package with --enable-gcc-warnings, so that one checks
38 that 1. Bison compiles cleanly, 2. the parsers it produces compile
39 cleanly too.
40
41- Change tests/bison to run `valgrind -q bison' to run Bison under
42 Valgrind.
43
44- Run the test suite with `./testsuite PREPARSER='valgrind -q' to make
45 sure the parser behave properly.
46
47- Change tests/atlocal/CFLAGS to add your preferred options. For
48 instance, `-traditional' to check that the parsers are K&R. Note
49 that it does not make sense for glr.c, which should be ANSI,
50 but currently is actually GNU C, nor for lalr1.cc, which anyway is
51 not exercised yet in the test suite.
52
53- Change tests/atlocal/CC to use a C++ compiler.
54
55
56* Release Procedure
57
58** Tests
59See above.
60
61** Update the foreign files
62Running `make update' in the top level should make it all for you.
63This covers PO files too. Beware that it happens that some PO files
64contain serious problems and are rejected by recent Gettext releases:
65fix them all, and complain to the Translation Project!
66
67Note that there might be *new* PO files. Don't forget to update the
68whole machinery, which not only includes LINGUAS, but `cvs add'ing the
69PO files too.
70
71** Update NEWS
72The version number, *and* the date of the release (including for
73betas).
74
75** Update ChangeLog
76Should have an entry similar to `Version 1.49b.'.
77Check all this in once `make distcheck' passes.
78
79** make alpha
80Running `make alpha' is absolutely perfect for beta releases: it makes
81the tarballs, the xdeltas, and prepares (in /tmp/) a proto
82announcement. It is so neat, that that's what I use anyway for
83genuine releases, but adjusting things by hand (e.g., the urls in the
84announcement file, the ChangeLog which is not needed etc.).
85
86If it fails, you're on your own...
87
88It requires GNU Make.
89
90** Upload
91Put the tarballs/xdeltas where they should be. Or put it somewhere,
92and send the URL to ftp-upload@gnu.org.
93
94** Bump the version number
95In configure.ac. Run `make', check this in.
96
97** Announce
98Complete/fix the announcement file, and send it at least to
99info@gnu.org (if a real release, or a ``serious beta''),
100bison@gnu.org, and translation@iro.umontreal.ca.
101
102
103-----
104
105Copyright (C) 2002 Free Software Foundation, Inc.
106
107This file is part of GNU Bison.
108
109GNU Bison is free software; you can redistribute it and/or modify
110it under the terms of the GNU General Public License as published by
111the Free Software Foundation; either version 2, or (at your option)
112any later version.
113
114GNU Bison is distributed in the hope that it will be useful,
115but WITHOUT ANY WARRANTY; without even the implied warranty of
116MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
117GNU General Public License for more details.
118
119You should have received a copy of the GNU General Public License
120along with GNU Bison; see the file COPYING. If not, write to the Free
121Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
12202111-1307, USA.