From ca4942de43b2db7da32976b3be20ef0fe9051bfb Mon Sep 17 00:00:00 2001 From: Mikolaj Wielgus Date: Sat, 25 Dec 2021 21:24:54 +0000 Subject: [PATCH] Put CRTL CFFI modules in crtl dir --- src/openpower/decoder/test/pysim.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/openpower/decoder/test/pysim.py b/src/openpower/decoder/test/pysim.py index b915e413..12afe7e8 100644 --- a/src/openpower/decoder/test/pysim.py +++ b/src/openpower/decoder/test/pysim.py @@ -348,17 +348,17 @@ class PySimEngine(BaseEngine): src_file.write(src) # build module named crtlNNN in crtl subdirectory - srcname = "crtl%d" % PySimEngine._crtl_counter + modulename = "crtl.crtl%d" % PySimEngine._crtl_counter sources = ["crtl/common.c"] sources += [f"crtl/{process.name}.c" for process in self._processes] ffibuilder = FFI() ffibuilder.cdef(cdef) - ffibuilder.set_source(srcname, cdef, sources=sources) + ffibuilder.set_source(modulename, cdef, sources=sources) ffibuilder.compile(verbose=True) # append search path of crtl directory before attempting import sys.path.append(os.path.join(os.getcwd())) - self._state.crtl = importlib.import_module(srcname).lib + self._state.crtl = importlib.import_module(modulename).lib # Use a counter to generate unique names for modules, because Python # won't reload C extension modules. -- 2.30.2