I tried upgrading my tdl from 1.2.0, and I'm getting this error on Python 2.7.5 in 64bit linux (Fedora 20). I have limited experience with c compiling and none with cffi, so I'm not sure what needs to be fixed. I searched for '\r' in tcod/ and could find none outside of tcod/lib/LIBTCOD-LICENSE.txt and tcod/lib/README-SDL.txt and some binary files (.so, .dylib, .dll).
$ pip install libtcod-cffi
Collecting libtcod-cffi
Using cached libtcod-cffi-0.2.1.zip
Complete output from command python setup.py egg_info:
Installed /tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg
Searching for pycparser
Reading https://pypi.python.org/simple/pycparser/
Best match: pycparser 2.14
Downloading https://pypi.python.org/packages/source/p/pycparser/pycparser-2.14.tar.gz#md5=a2bc8d28c923b4fe2b2c3b4b51a4f935
Processing pycparser-2.14.tar.gz
Writing /tmp/easy_install-Gjrzd6/pycparser-2.14/setup.cfg
Running pycparser-2.14/setup.py -q bdist_egg --dist-dir /tmp/easy_install-Gjrzd6/pycparser-2.14/egg-dist-tmp-SFoDRZ
warning: no previously-included files matching 'yacctab.*' found under directory 'tests'
warning: no previously-included files matching 'lextab.*' found under directory 'tests'
warning: no previously-included files matching 'yacctab.*' found under directory 'examples'
warning: no previously-included files matching 'lextab.*' found under directory 'examples'
zip_safe flag not set; analyzing archive contents...
Moving pycparser-2.14-py2.7.egg to /tmp/pip-build-JG1HLV/libtcod-cffi/.eggs
Installed /tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/pycparser-2.14-py2.7.egg
Traceback (most recent call last):
File "<string>", line 20, in <module>
File "/tmp/pip-build-JG1HLV/libtcod-cffi/setup.py", line 66, in <module>
license = 'Simplified BSD License'
File "/usr/lib64/python2.7/distutils/core.py", line 112, in setup
_setup_distribution = dist = klass(attrs)
File "/home/jdklassen/projects/libtcod-cffi/env/lib/python2.7/site-packages/setuptools/dist.py", line 269, in __init__
_Distribution.__init__(self,attrs)
File "/usr/lib64/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/home/jdklassen/projects/libtcod-cffi/env/lib/python2.7/site-packages/setuptools/dist.py", line 325, in finalize_options
ep.load()(self, ep.name, value)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/setuptools_ext.py", line 154, in cffi_modules
add_cffi_module(dist, cffi_module)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/setuptools_ext.py", line 48, in add_cffi_module
execfile(build_file_name, mod_vars)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/setuptools_ext.py", line 24, in execfile
exec(code, glob, glob)
File "build_libtcod.py", line 39, in <module>
ffi.cdef(open('tcod/libtcod_cdef.h', 'r').read())
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/api.py", line 107, in cdef
self._parser.parse(csource, override=override, packed=packed)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/cparser.py", line 167, in parse
self._internal_parse(csource)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/cparser.py", line 173, in _internal_parse
ast, macros, csource = self._parse(csource)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/cparser.py", line 130, in _parse
self.convert_pycparser_error(e, csource)
File "/tmp/pip-build-JG1HLV/libtcod-cffi/.eggs/cffi-1.1.2-py2.7-linux-x86_64.egg/cffi/cparser.py", line 159, in convert_pycparser_error
raise api.CDefError(msg)
cffi.api.CDefError: parse error
:3:1: Illegal character '\r'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-JG1HLV/libtcod-cffi