05be78383903bbf3a3ecb5fa305dad60d2b67416
[platform/upstream/gobject-introspection.git] / README
1 GObject Introspection
2 =====================
3 The goal of the project is to describe the APIs and collect them in
4 a uniform, machine readable format.
5
6 GIR XML format
7 ==============
8
9 There's an XML format called GIR used by GObjectIntrospection.
10 The purpose of it is to provide a common structure to access the complete
11 available API that a library or other unit of code exports.
12 It is meant to be language agnostic using namespaces to separate
13 core, language or library specific functionality.
14 There are currently only C based tools that work on the format, but it's
15 meant to be usable to use in other situations, for instance to/from another
16 set of languages.
17
18 Typelib
19 =======
20
21 The typelib is an on-disk version of the GIR designed to be fast, memory
22 efficient and complete enough so that language bindings can be written
23 on top of it without other sources of information.
24 It is normally compiled from a GIR when a library/program is installed and
25 accessed from the language binding or another application who wishes to
26 use the information.
27
28 Tools
29 =====
30
31 The following tools are shipped with GObject Introspection:
32 - g-ir-scanner, a tool which generates GIR XML files by parsing headers,
33   GTK-Doc comment blocks including annotations and introspecting GObject
34   based libraries.
35 - g-ir-compiler, a typelib compiler. It converts one or more GIR files
36   into one or more typelib blobs.
37 - g-ir-generate, an GIR generator, using the repository API. It generates
38   GIR files from binary typelib which can be in a shared object, or a raw
39   typelib blob.
40 - g-ir-annotation-tool, extracts annotations from source code files
41 - g-ir-doc-tool, generates API reference documentation from a GIR XML file.
42
43 API library
44 ===========
45
46 There's also a C based library called libgirepository which provides
47 an API to access to the typelib metadata. It also contains an API to
48 invoke functions, given the function info object. The implementation is
49 based on libffi (3.0 or higher of libffi required, can be found at
50 http://sourceware.org/libffi).
51
52 There are a number of GIR test files in tests/, and a script to do
53 roundtrip tests (GIR -> typelib -> GIR).
54
55 Helping out
56 ===========
57 The introspection framework needs a lot more work, see TODO.
58
59 Homepage
60 ========
61 http://live.gnome.org/GObjectIntrospection
62
63 Reporting bugs
64 ==============
65 Bugs should be reported in http://bugzilla.gnome.org/ in the gobject-introspection product.
66
67 Contact
68 =======
69 Mail: gtk-devel-list@gnome.org
70 IRC: #introspection@irc.gnome.org