source: trunk/README.developer @ 494

Last change on this file since 494 was 494, checked in by Peter Johansson, 15 years ago

short paragraph describing output file structure

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
  • Property svn:mime-type set to text/x-trac-wiki
File size: 5.4 KB
RevLine 
[84]1$Id: README.developer 494 2007-10-14 02:42:09Z peter $
[26]2
[338]3= Developer Information =
4
5This file contains developer specific information.
6
[394]7
8=== Coding style ===
9
10Developers should follow the coding style outlined in the
11[http://www.thep.lu.se/~jari/documents/c++_coding_guidelines/index.html C++ coding guidelines].
12
13
14=== Subversion usage ===
15
16Commits should be minimalistic and the projects should always compile
[442]17(`make` and `make check`) when someone makes a clean checkout. There is
[394]18a short introduction to subversion and its usage available as
19[http://www.thep.lu.se/~jari/documents/subversion_guidelines/index.html Subversion guidelines].
20We follow these guidelines.
21
22
[481]23=== bootstrap and autoreconf ===
[387]24
[481]25At first checkout from the repository you must run the bootstrapping
26utility
[338]27
28  `./bootstrap`
29
[481]30to setup autoconf files. To push subsequent changes of this file into
31the build scripts you run
[338]32
[481]33   `autoreconf`
[394]34
[481]35
[338]36=== configure ===
37
[387]38Run the generated configure script with
39
[338]40  `./configure --enable-debug --enable-wctests`
41
42The option flag `--enable-debug` turns on debug options (e.g. enables
43assertions). The option flag `--enable-wctests` turns on some
44additional tests. All tests are not enabled by default since some of
45the tests depend on being run from a subversion WC.
46
[394]47
48=== Testing ===
49
50Test programs should be created and added to the `make check`
51execution. Always check that the test runs before committing code to
52the repository, i.e., run `make check`.
53
54There is a test repository in source:trunk/test/repo that is a part of
55the svndigest repository. The logic behind this is that it is nice to
56have a common test repository that can be used off-line. Changes to
57the repository are usually made to create new test cases and it is
58important that these changes are committed to svndigest repository as
59well. All changes to the test repository are not automatically
60propagated to the svndigest repository and it is important that some
61files created in the test repository are manually added to the
62svndigest repository. Assuming that `make check` is run before a
63commit, a warning is generated if the test repository is inconsistent
64with the svndigest repository. There will be a diagnostic message and
65a resolution hint, however the developer must examine and resolve the
66problem manually.
67
68The problem is simply that the file source:trunk/test/repo/db/current
69is changed compared to the svndigest repository. The `current` file
70indicates a specific number of change sets within the test repository
71and the directories source:trunk/test/repo/db/revs and
72source:trunk/test/repo/db/revprops contains a matching number of
73change sets. However, the change sets added to the test repository are
74not automatically added to the svndigest repository, therefore the new
75files in the `revs` and `revprops` directories must be added manually
76to the svndigest repository.
77
78There is also a race condition when developers make changes to the
79test repository simultaneously: It is easy to create severe conflicts
80in the test repository. Imaging the case when two developers adds test
81commits to the test repository, and then tries to add these to the
82svndigest repository. Since there are different versions of the same
83test repository revisions, the second developer committing to the
84svndigest will get messages about files being in the way. This is just
85one situation with possible conflicts. This conflict is of course
86resolved by the second developer having to throw away his changes and
87redo them after a new checkout of the test repository.
88
89The take home message is that developers should communicate with each
90other when changing the test repository in order to avoid to large
91repository conflicts. AND read the output of `make check`.
92
93
[494]94=== Output file structure ===
95
96A directory reflecting the parsed directory is generated for each
97combination of StatsType, Author, and LineType, which is located in
98`<TARGET>/<ROOT>/StatsType/Author/LineType/`.
99
100
[338]101=== Create a distribution ===
[387]102
[338]103Create a distribution package with `make dist`. Remember to test
104the package with `make distcheck`. If required packages are installed
105in non-standard locations you need to pass this information to
106`distcheck`. This is done by using the variable
107DISTCHECK_CONFIGURE_FLAGS as
108
[409]109   `DISTCHECK_CONFIGURE_FLAGS="--with-apr=/usr/local/apr" make distcheck`
[338]110
111Usually you need to set DISTCHECK_CONFIGURE_FLAGS to whatever options
112you pass to configure with the exception of `--enable-wctests`.
[387]113Passing `--enable-wctests` to distcheck will always make the `make` to
[388]114fail because a distribution does not contain all files needed for WC
[387]115tests.
[338]116
117
[394]118== Releasing ==
[338]119
[439]120See http://trac.thep.lu.se/trac/svndigest/wiki/ReleaseProcedure
[394]121
122
[338]123-------------------------------------------------------------------------
124{{{
[408]125Copyright (C) 2005, 2006 Jari Häkkinen
[394]126Copyright (C) 2007 Jari Häkkinen, Peter Johansson
[84]127
[439]128This file is part of svndigest, http://trac.thep.lu.se/trac/svndigest
[84]129
[149]130svndigest is free software; you can redistribute it and/or modify it
[84]131under the terms of the GNU General Public License as published by the
132Free Software Foundation; either version 2 of the License, or (at your
133option) any later version.
134
[149]135svndigest is distributed in the hope that it will be useful, but
136WITHOUT ANY WARRANTY; without even the implied warranty of
137MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
138General Public License for more details.
[84]139
140You should have received a copy of the GNU General Public License
141along with this program; if not, write to the Free Software
142Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
143USA.
144
[338]145}}}
Note: See TracBrowser for help on using the repository browser.