contrib: Add dependency diagram of libguestfs ecosystem.
[libguestfs.git] / contrib / dependency-diagram / diagram.dot
1 /* -*- C -*- */
2 /* libguestfs ecosystem dependency diagram
3  * Copyright (C) 2010 Red Hat Inc.
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18  */
19
20 /* LAST UPDATE: 2010-04-30.
21  *
22  * If the current date is significantly later than the date above,
23  * then beware this diagram may be out of date.
24  */
25
26 /* Note this diagram is greatly simplified.
27  *
28  * Some direct dependencies are omitted, if they are implied by
29  * indirect dependencies.  eg.  All the tools need perl &
30  * Sys::Guestfs, but if they have a dependency on Sys::Guestfs::Lib we
31  * only show that.
32  *
33  * Perl libraries which are not part of base perl are not shown (eg.
34  * XML::Writer).
35  */
36
37 digraph G {
38   /* Top-level libguestfs tools and what they immediately depend on. */
39   "virt-cat" -> "Sys::Guestfs::Lib";
40   "virt-df" -> "Sys::Guestfs::Lib";
41   "virt-edit" -> "Sys::Guestfs::Lib";
42   "virt-list-filesystem" -> "Sys::Guestfs::Lib";
43   "virt-list-partitions" -> "Sys::Guestfs::Lib";
44   "virt-ls" -> "Sys::Guestfs::Lib";
45   "virt-make-fs" -> "Sys::Guestfs::Lib";
46   "virt-rescue" -> "Sys::Guestfs::Lib";
47   "virt-resize" -> "Sys::Guestfs::Lib";
48   "virt-tar" -> "Sys::Guestfs::Lib";
49   "virt-win-reg" -> "Sys::Guestfs::Lib";
50   "virt-win-reg" -> "Win::Hivex";
51   "virt-win-reg" -> "Win::Hivex::Regedit";
52
53   "virt-inspector" -> "Sys::Guestfs::Lib";
54
55   guestfish -> libguestfs;
56   guestfish -> "virt-inspector"; /* to implement -i option */
57
58   guestmount -> libguestfs;
59   guestmount -> libfuse;
60
61   /* virt-v2v (greatly simplified) */
62   "virt-v2v" -> "Sys::Guestfs";
63   "virt-v2v" -> "Sys::Guestfs::Lib";
64   "virt-v2v" -> "Sys::VirtV2V";
65   "Sys::VirtV2V" [label="Sys::VirtV2V\nMany dependencies\nnot shown"];
66
67   /* Perl bindings and libraries for libguestfs. */
68   "Sys::Guestfs" -> libguestfs;
69   "Sys::Guestfs" -> perl;
70   "Sys::Guestfs" [label="Sys::Guestfs\nPerl bindings for libguestfs"];
71   "Sys::Guestfs::Lib" -> "Sys::Guestfs";
72   "Sys::Guestfs::Lib" -> "Sys::Virt";
73   "Sys::Guestfs::Lib" -> "Win::Hivex";
74   "Sys::Guestfs::Lib" [label="Sys::Guestfs::Lib\nImage inspection and\nother useful functions"];
75
76   /* Libguestfs C library. */
77   libguestfs -> appliance -> "qemu or KVM";
78   libguestfs [label="libguestfs\nThe C library"];
79
80   /* Top-level hivex tools. */
81   hivexregedit -> "Win::Hivex";
82   hivexregedit -> "Win::Hivex::Regedit";
83   hivexsh -> libhivex;
84   hivexml -> libhivex;
85   hivexget -> hivexsh; /* This tool is obsolete now. */
86
87   /* Perl bindings and libraries for hivex. */
88   "Win::Hivex" -> libhivex;
89   "Win::Hivex" -> perl;
90   "Win::Hivex" [label="Win::Hivex\nPerl bindings for hivex"];
91   "Win::Hivex::Regedit" [label="Win::Hivex::Regedit\nregedit import/export"];
92
93   /* Hivex C library. */
94   libhivex [label="hivex\nThe C library"];
95
96   /* libvirt. */
97   "Sys::Virt" -> libvirt;
98   "Sys::Virt" -> perl;
99   "Sys::Virt" [label="Sys::Virt\nPerl bindings for libvirt"];
100 }