## The `cythonize' function generates the C sources immediately, so we have
## to generate its inputs even earlier.
genfiles = [
-# MS.Derive('base64.pyx', 'codec.pyx.in',
-# {'CLASS': 'Base64', 'PREFIX': 'base64'}),
-# MS.Derive('base32.pyx', 'codec.pyx.in',
-# {'CLASS': 'Base32', 'PREFIX': 'base32'}),
-# MS.Derive('hex.pyx', 'codec.pyx.in',
-# {'CLASS': 'Hex', 'PREFIX': 'hex'})
+ MS.Derive('base64.pyx', 'codec.pyx.in',
+ {'CLASS': 'Base64', 'PREFIX': 'base64'}),
+ MS.Derive('base32.pyx', 'codec.pyx.in',
+ {'CLASS': 'Base32', 'PREFIX': 'base32'}),
+ MS.Derive('hex.pyx', 'codec.pyx.in',
+ {'CLASS': 'Hex', 'PREFIX': 'hex'})
]
for g in genfiles: g.gen()
## Generate the main C code.
if OS.path.exists(pyxc): OS.rename(pyxc, "mLib.c")
-CB.cythonize("mLib.pyx", compile_time_env = dict(PYVERSION = PYVERSION))
+CB.cythonize("mLib.pyx",
+ compile_time_env = dict(PYVERSION = PYVERSION),
+ compiler_directives = dict(c_string_encoding = 'utf8'))
OS.rename("mLib.c", pyxc)
MS.setup(name = 'mLib-python',