Skip to content

Commit 81b8c94

Browse files
author
roman_yakovenko
committed
sphinx
1 parent 7d21cd4 commit 81b8c94

File tree

2 files changed

+24
-12
lines changed

2 files changed

+24
-12
lines changed

docs/history/history.rest

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@ Version 1.1
3232
2. Ability to extract different information from binary files ( ``.pdb``, ``.so``,
3333
``.map`` ) and merge it with a declarations tree was added.
3434

35-
3. Ability to load `GCC-XML`_ configuration from ``.ini`` like file was added
35+
3. Ability to load `GCC-XML`_ configuration from ``.ini`` like file was added.
36+
See :func:`pygccxml.parser.config.load_gccxml_configuration` for details.
3637

3738
4. From now on, :doc:`pygccxml <../pygccxml>` will use `Sphinx <http://sphinx.pocoo.org/>`_
3839
for all documentation.

pygccxml/parser/config.py

Lines changed: 22 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,8 @@ def raise_on_wrong_settings( self ):
198198
config_t = gccxml_configuration_t #backward computability
199199

200200
gccxml_configuration_example = \
201-
"""[gccxml]
201+
"""
202+
[gccxml]
202203
#path to gccxml executable file - optional, if not provided, os.environ['PATH']
203204
#variable is used to find it
204205
gccxml_path=
@@ -210,24 +211,34 @@ def raise_on_wrong_settings( self ):
210211
#You can explicitly set what compiler it should emulate.
211212
#Valid options are: g++, msvc6, msvc7, msvc71, msvc8, cl.
212213
compiler=
213-
214-
#GCC-XML site: http://gccxml.org/
215214
"""
216215

217216
def load_gccxml_configuration( configuration, **defaults ):
218-
"""loads GCC-XML configuration from a file
217+
"""
218+
loads GCC-XML configuration from an `.ini` file or any other file class
219+
:class:`ConfigParser.SafeConfigParser` is able to parse.
219220
220-
Configuration file sceleton:
221+
:param configuration: configuration could be string( configuration file path )
222+
or instance of :class:`ConfigParser.SafeConfigParser` class
221223
222-
>>> start <<<
224+
:rtype: :class:`.gccxml_configuration_t`
223225
224-
%s
226+
Configuration file sceleton::
225227
226-
>>> end <<<
228+
[gccxml]
229+
#path to gccxml executable file - optional, if not provided, os.environ['PATH']
230+
#variable is used to find it
231+
gccxml_path=
232+
#gccxml working directory - optional, could be set to your source code directory
233+
working_directory=
234+
#additional include directories, separated by ';' or ':'
235+
include_paths=
236+
#gccxml has a nice algorithms, which selects what C++ compiler to emulate.
237+
#You can explicitly set what compiler it should emulate.
238+
#Valid options are: g++, msvc6, msvc7, msvc71, msvc8, cl.
239+
compiler=
227240
228-
configuration could be string( configuration file path ) or instance of
229-
ConfigParser.SafeConfigParser class
230-
""" % gccxml_configuration_example
241+
"""
231242
parser = configuration
232243
if isinstance( configuration, types.StringTypes ):
233244
from ConfigParser import SafeConfigParser

0 commit comments

Comments
 (0)