Last active
May 29, 2017 14:56
-
-
Save redj/19a446dab7defc6788f8ff7a6c1e0878 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
D:\c\e\e\bindings\python>py build_EDA.py | |
Traceback (most recent call last): | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\cparser.py", line 260, in _parse | |
ast = _get_parser().parse(csource) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\pycparser\c_parser.py", line 151, in parse | |
debug=debuglevel) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\pycparser\ply\yacc.py", line 331, in parse | |
return self.parseopt_notrack(input, lexer, debug, tracking, tokenfunc) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\pycparser\ply\yacc.py", line 1181, in parseopt_notrack | |
tok = call_errorfunc(self.errorfunc, errtoken, self) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\pycparser\ply\yacc.py", line 193, in call_errorfunc | |
r = errorfunc(token) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\pycparser\c_parser.py", line 1721, in p_error | |
column=self.clex.find_tok_column(p))) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\pycparser\plyparser.py", line 55, in _parse_error | |
raise ParseError("%s: %s" % (coord, msg)) | |
pycparser.plyparser.ParseError: :1246:4: before: ffi_cif | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "build_EDA.py", line 25, in <module> | |
ffi_EDA.cdef(open('cffi-EDA.h').read()) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\api.py", line 105, in cdef | |
self._cdef(csource, override=override, packed=packed) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\api.py", line 119, in _cdef | |
self._parser.parse(csource, override=override, **options) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\cparser.py", line 299, in parse | |
self._internal_parse(csource) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\cparser.py", line 304, in _internal_parse | |
ast, macros, csource = self._parse(csource) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\cparser.py", line 262, in _parse | |
self.convert_pycparser_error(e, csource) | |
File "C:\sw\python\3.4\64bit\lib\site-packages\cffi\cparser.py", line 291, in convert_pycparser_error | |
raise api.CDefError(msg) | |
cffi.api.CDefError: cannot parse "ffi_cif cif;" | |
:1246:4: before: ffi_cif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from cffi import FFI | |
ffi_ec = FFI() | |
ffi_ec.cdef(open('cffi-eC.h').read()) | |
ffi_ec.set_source("_pyeC", | |
'#include "eC.h"', | |
sources=["../c/eC.c"], | |
include_dirs=["../c"], | |
libraries=["ecere"], | |
library_dirs=["C:/Program Files/Ecere SDK/bin"]) | |
ffi_ecere = FFI() | |
ffi_ecere.include(ffi_ec) | |
ffi_ecere.cdef(open('cffi-ecere.h').read()) | |
ffi_ecere.set_source("_pyecere", | |
'#include "ecere.h"', | |
sources=["../c/ecere.c"], | |
include_dirs=["../c"], | |
libraries=["ecere", "_pyeC"], | |
library_dirs=["C:/Program Files/Ecere SDK/bin", "."]) | |
ffi_EDA = FFI() | |
ffi_EDA.include(ffi_ec) | |
ffi_EDA.include(ffi_ecere) | |
ffi_EDA.cdef(open('cffi-EDA.h').read()) | |
ffi_EDA.set_source("_pyEDA", | |
'#include "ffi.h"\n#include "ED-this-stuff-doesnt-matter-A.h"', | |
sources=["../c/EDA.c"], | |
include_dirs=["../c", "../../deps/libffi-3.0.11/i686-pc-mingw32/include"], | |
libraries=["EDA", "_pyecere.pyd"], | |
library_dirs=["C:/Program Files/Ecere SDK/bin", "."]) | |
if __name__ == "__main__": | |
ffi_EDA.compile(verbose=True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment