annotate HACKING @ 12134:6c54ad0fde04 release-3-4-x ss-3-3-90

update copyright and version info for release branch
author John W. Eaton <jwe@octave.org>
date Sat, 22 Jan 2011 13:50:32 -0500
parents 711aa22ff83d
children 2162104d40b1
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
1 -*- outline -*-
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
2
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
3 This file attempts to describe the rules to use when hacking Octave.
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
4 DO NOT put this file into the distribution.
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
5
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
6 * Working from the repository
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
7
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
8 These notes are intended to help people working on sources checked-out from
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
9 the savannah source code repository.
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
10 These requirements do not apply when building from a distribution
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
11 tarball.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
12
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
13 ** Requirements
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
14
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
15 We've opted to keep only the highest-level sources in the repository.
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
16 This eases our maintenance burden, (fewer merges, etc.), but imposes
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
17 more requirements on anyone wishing to build from the just-checked-out
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
18 sources. For example, you have to use the latest stable versions of
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
19 the maintainer tools we depend upon, including:
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
20
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
21 - Autoconf <http://www.gnu.org/software/autoconf/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
22 - Automake <http://www.gnu.org/software/automake/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
23 - Bison <http://www.gnu.org/software/bison/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
24 - Flex <http://www.gnu.org/software/flex/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
25 - Git <http://git-scm.com/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
26 - Gnulib <http://www.gnu.org/software/gnulib/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
27 - GNU Make <http://www.gnu.org/software/make/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
28 - Gzip <http://www.gnu.org/software/gzip/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
29 - Libtool <http://www.gnu.org/software/libtool/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
30 - Mercurial <http://mercurial.selenic.com/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
31 - Perl <http://www.cpan.org/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
32 - Rsync <http://samba.anu.edu.au/rsync/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
33 - Tar <http://www.gnu.org/software/tar/>
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
34
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
35 Only building the initial full source tree will be a bit painful.
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
36 Later, after synchronizing from the repository, a plain `make' should
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
37 be sufficient.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
38
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
39 ** First checkout
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
40
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
41 Obviously, if you are reading these notes, you did manage to check out
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
42 this package from the repository. For the record, you will find all the
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
43 relevant information on downloading sources at:
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
44
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
45 http://savannah.gnu.org/hg/?group=octave
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
46
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
47 After checking out Octave, you will need to run the autogen.sh script:
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
48
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
49 $ ./autogen.sh
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
50
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
51 This script will examine the source tree and generate some Makefile
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
52 fragments and then runs the bootstrap script. The bootstrap script comes
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
53 from gnulib, but is kept in the Octave source archive. It should be
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
54 updated from the gnulib sources as necssary. The bootstrap script takes
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
55 care of checking out a copy of gnulib, running the autotools, and
9949
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
56 generating the configure script.
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
57
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
58 If you have a copy of gnulib in some directory apart from the Octave
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
59 source tree, then pass the name of the directory containing gnulib-tool
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
60 to the bootstrap script using the option:
9949
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
61
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
62 --gnulib-srcdir=DIRNAME
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
63
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
64 If you have downloaded gnulib directly, DIRNAME will be the directory where
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
65 gnulib was unpacked. If you have installed gnulib using a package
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
66 manager, DIRNAME is likely to be /usr/bin or /usr/local/bin(where the
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
67 gnulib-tool script resides).
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
68
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
69 By using an external gnulib directory, you can share a single gnulib source
9949
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
70 tree among several projects. Regardless of the location of the gnulib
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
71 sources, the bootstrap script will try to update them if it appears
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
72 that they are checked out using git. Otherwise, it is your
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
73 responsibility to keep the gnulib sources up to date. They change
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
74 frequently, so the best way to stay current is probably to use git to
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
75 do the job.
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
76
9977
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
77 Additional options besides --gnulib-srcdir can be passed to autogen.sh and
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
78 they will be forwarded without modification to the bootstrap script.
711aa22ff83d Elaborate which DIRNAME to use for --gnulib-srcdir option in HACKING file
Rik <rdrider0-list@yahoo.com>
parents: 9949
diff changeset
79
9949
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
80 Once the autogen.sh and bootstrap scripts complete successfully, you may
a6308dcad5ac update HACKING file
John W. Eaton <jwe@octave.org>
parents: 9946
diff changeset
81 run
9946
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
82
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
83 $ ./configure
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
84 $ make
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
85 $ make check
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
86
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
87 At this point, there should be no difference between your local copy,
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
88 and the master copy:
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
89
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
90 $ hg diff
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
91
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
92 should output no difference.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
93
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
94 Additional information about coding style
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
95
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
96 This file will eventually be extended to explain more about updating
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
97 Octave, preparing patches, and making releases.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
98
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
99 Enjoy!
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
100
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
101 -----
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
102
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
103 Copyright (C) 2009 John W. Eaton
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
104
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
105 This file is part of Octave.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
106
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
107 Octave is free software; you can redistribute it and/or modify it
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
108 under the terms of the GNU General Public License as published by the
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
109 Free Software Foundation; either version 3 of the License, or (at
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
110 your option) any later version.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
111
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
112 Octave is distributed in the hope that it will be useful, but WITHOUT
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
113 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
114 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
115 for more details.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
116
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
117 You should have received a copy of the GNU General Public License
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
118 along with Octave; see the file COPYING. If not, see
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
119 <http://www.gnu.org/licenses/>.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
120
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
121
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
122 This file was adapted for Octave from the HACKING file that is part of
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
123 GNU Bison, which contained the following Copyright notice:
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
124
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
125 Copyright (C) 2002, 2003, 2004, 2005, 2007, 2008, 2009
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
126 Free Software Foundation, Inc.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
127
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
128 This file is part of GNU Bison.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
129
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
130 This program is free software: you can redistribute it and/or modify
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
131 it under the terms of the GNU General Public License as published by
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
132 the Free Software Foundation, either version 3 of the License, or
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
133 (at your option) any later version.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
134
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
135 This program is distributed in the hope that it will be useful,
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
136 but WITHOUT ANY WARRANTY; without even the implied warranty of
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
137 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
138 GNU General Public License for more details.
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
139
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
140 You should have received a copy of the GNU General Public License
55061c7c8d6e start using gnulib
John W. Eaton <jwe@octave.org>
parents:
diff changeset
141 along with this program. If not, see <http://www.gnu.org/licenses/>.