Reorganize Graphviz
Swe0607
In this project you extend your (practical) knowledge of all the
construction and deployment tools that we have studied so far (make,
subversion, rpm, autoconf, automake).
Graphviz
Graphviz is a set of tools for graph layout. It contains many different
tools, including
- dot, which draws directed graphs;
- neato, which draws undirected graphs;
- lefty
The following picture of a finite state machine:
was generated from the dot file
fsm.dot.
Componentizing Graphviz
The Grapviz distribution is configured with autoconf and automake.
Graphviz provides a number of libraries that could be useful for other
projects. The libraries are not exported or installed. Graphviz is a
big monolithic distribution. If one is only interested in dot, for
example, it is still necessary to download and build the entire
distribution.
The goal of this exercise is to take the graphviz distribution apart
and divide it into small, separately distributable components.
(Note: it is not clear that such components can actually be
distributed separately, because of the licence restrictions.)
Process
- Unpack the graphviz distribution (
tar xvfz filename.tar.gz)
- Build and install the graphviz distribution
- Compile a few graphs with the
dot program
- Extract from the graphviz distribution a minimal source tree that implements the
dot and neato programs. These are in the dotneato subdirectory. Put this in a Subversion repository. The general approach is to start with (e.g.) dot.c and determine what else is needed to build it. For example, for dot you also need libdot.a (in dotneato/dotgen), and so on. Recursively add these components to the repository until you have a working program. (So don't import all of graphviz at once; it's much too big).
- Do the same for the
lefty program
- If you can, try to make sure to factor out the overlap between the two source trees into separate packages. Indeed, it would be a good idea to factor out libraries into their own packages, such that they can be used by other software. This may require the use of shared libraries. Determine the dependencies between the components. Create a dot graph to depict the dependencies.
- Put each package under control of Autoconf and Automake.
- Create RPMs for the packages produced (by extending the Makefile)
Structure of the Repository
For each package
pack that you extract create in your subversions repository a directory
pack/ with subdirectory
trunk/ in which the main branch of the package can be found.
Technical Issues
Since the Graphviz package is rather large, you may not have enough disk quotum in your home directory. You can make a subdirectory under
/praktikum/se/work to store your files. There are no quotas on
/praktikum/; don't abuse this. Also ensure that your directory is not readable for others, i.e., do:
chmod go-rwx /praktikum/se/work/your_directory
Submission
To submit the componentized graphviz send the URL of your subversion repository and the names of
the packages that you have created.