diff --git a/panda/python/core/create_panda_datatypes.py b/panda/python/core/create_panda_datatypes.py index 5d7f1b1e501..5f86c2c14fa 100755 --- a/panda/python/core/create_panda_datatypes.py +++ b/panda/python/core/create_panda_datatypes.py @@ -96,6 +96,9 @@ def copy_ppp_header(filename): subcontents = trim_pypanda(contents) for line in subcontents.split("\n"): # now add void ppp_add_cb_{cb_name}({cb_name}_t); + forbidden = ["#ifndef", "#endif"] + if any(i in line for i in forbidden): + continue m = reg.match(line) if m: ret_type = m.groups(1)[0] @@ -229,6 +232,7 @@ def expand_ppp_def(line): ffi.cdef("typedef int target_pid_t;") ffi.cdef("typedef uint"+str(bits)+"_t target_ulong;") + ffi.cdef("typedef uint"+str(bits)+"_t target_ptr_t;") ffi.cdef("typedef int"+str(bits)+"_t target_long;") # PPP Headers