Skip to content

Commit

Permalink
Force g++ to accept "long long" type
Browse files Browse the repository at this point in the history
We are using --pedantic, and in that mode (old?) g++ treats the usage of "long
long" as an hard error.

Should fix issue #69.
  • Loading branch information
lelit committed Mar 21, 2017
1 parent acce989 commit a263ae4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
8 changes: 8 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
Changes
-------

* next (unreleased)
~~~~~~~~~~~~~~~~~~~

* Compilable with somewhat old g++ (`issue #69__`)

__ https://github.com/python-rapidjson/python-rapidjson/issues/69


0.0.11 (2017-03-05)
~~~~~~~~~~~~~~~~~~~

Expand Down
6 changes: 4 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,10 @@
cflags = cflags.replace('-Wstrict-prototypes', '')
sysconfig.get_config_vars()['CFLAGS'] = cflags

# Add -pedantic, so we get a warning when using non-standard features
extension_options['extra_compile_args'] = ['-pedantic']
# Add -pedantic, so we get a warning when using non-standard features, and
# -Wno-long-long to pacify old gcc (or Apple's hybrids) that treat "long
# long" as an error under C++ (see issue #69)
extension_options['extra_compile_args'] = ['-pedantic', '-Wno-long-long']

rapidjson = Extension('rapidjson', **extension_options)

Expand Down

0 comments on commit a263ae4

Please sign in to comment.