Skip to content

Commit b518938

Browse files
dvarrazzodavidmalcolm
authored andcommitted
Suggest installing the gcc-plugin-dev package in the readme
See issue #113. Also tweaked some reST formatting.
1 parent d2078d5 commit b518938

File tree

1 file changed

+22
-12
lines changed

1 file changed

+22
-12
lines changed

README.rst

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ for CPython, but it could be used e.g. to teach GCC about GTK's
1717
reference-counting semantics, or about locking in the Linux kernel, or about
1818
signal-safety in APIs.
1919

20-
Other ideas include visualizations of code structure. Given a `gcc.CFG`
21-
instance, `gccutils.render_to_dot(cfg)` and `gccutils.invoke_dot(cfg)` will
20+
Other ideas include visualizations of code structure. Given a ``gcc.CFG``
21+
instance, ``gccutils.render_to_dot(cfg)`` and ``gccutils.invoke_dot(cfg)`` will
2222
use graphviz and eog to plot a handy visualization of a control flow graph,
2323
showing the source code interleaved with GCC's ``GIMPLE`` internal
2424
representation.
@@ -27,23 +27,29 @@ The documentation can be seen at:
2727

2828
http://gcc-python-plugin.readthedocs.io/en/latest/index.html
2929

30+
3031
Requirements
3132
------------
3233

3334
* GCC: 4.6 or later (it uses APIs that weren't exposed to plugins in 4.5)
3435

3536
* tested with 4.8, 4.9, 5, 6, 7, and 8.
3637

38+
* GCC plugin development package: usually available in distribution packages
39+
such as ``gcc-N-plugin-dev`` or ``gcc-plugin-devel``.
40+
3741
* Python: requires 2.7 or 3.2 or later
3842

39-
* "six": The libcpychecker code uses the "six" Python compatibility library to
43+
* "six": The libcpychecker code uses the "six_" Python compatibility library to
4044
smooth over Python 2 vs Python 3 differences, both at build-time and
4145
run-time:
4246

43-
http://pypi.python.org/pypi/six/
47+
.. _six: http://pypi.python.org/pypi/six/
48+
4449

4550
Usage
4651
-----
52+
4753
I use::
4854

4955
make
@@ -85,16 +91,17 @@ from within a script.
8591

8692
Overview of the code
8793
--------------------
94+
8895
This is currently three projects in one:
8996

90-
gcc-python-*: the plugin for GCC. The entrypoint (`init_plugin`) is in
91-
gcc-python.c
97+
``gcc-python-*``: the plugin for GCC. The entrypoint (``init_plugin``) is in
98+
``gcc-python.c``.
9299

93-
libcpychecker and cpychecker.py: a Python library (and a driver script),
100+
``libcpychecker`` and ``cpychecker.py``: a Python library (and a driver script),
94101
written for the plugin, in which I'm building new compiler warnings to
95102
help people find bugs in CPython extension code.
96103

97-
cpybuilder: a handy module for programatically generating C source code for
104+
``cpybuilder``: a handy module for programatically generating C source code for
98105
CPython extensions. I use this both to generate parts of the GCC plugin, and
99106
also in the selftests for the cpychecker script. (I initially attempted to use
100107
Cython for the former, but wrapping the "tree" type hierarchy required more
@@ -105,15 +112,18 @@ I've chosen to follow Python's (PEP-7), as I prefer it (although my code is
105112
admittedly a mess in places).
106113

107114
You'll find API documentation within the "docs" directory, written in the
108-
reStructuredText format (as is this file, in fact). If you have Sphinx
109-
installed (http://sphinx.pocoo.org/), you can regenerate these docs using::
115+
reStructuredText format (as is this file, in fact). If you have Sphinx_
116+
installed, you can regenerate these docs using::
110117

111118
make html
112119

113-
within the `docs` directory. Sphinx is the `python-sphinx` package on a
120+
within the ``docs`` directory. Sphinx is the ``python-sphinx`` package on a
114121
Fedora/RHEL box.
115122

116-
More detailed documentation can be seen within `docs/getting-involved.rst`
123+
.. _Sphinx: http://sphinx.pocoo.org/
124+
125+
126+
More detailed documentation can be seen within ``docs/getting-involved.rst``.
117127

118128
Enjoy!
119129
David Malcolm <dmalcolm@redhat.com>

0 commit comments

Comments
 (0)