How to package python extensions that need a special preprocessor?
Guy Streeter
streeter at redhat.com
Thu Sep 3 16:17:00 UTC 2015
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 09/03/2015 10:36 AM, David Howells wrote:
> Guy Streeter <streeter at redhat.com> wrote:
>
>>> I'm trying to package a python module that has a C extension that has
>>> a special preprocessor that turns protocol definition files into C.
>> ... See the setup.py in this package:
>>
>> https://git.fedorahosted.org/cgit/python-libnuma.git/
>>
>> It runs msgfmt on the provided message catalog files at build time.
>
> Okay, thanks for the reference. That takes me part the way there - but
> as I understand it, message catalogue files aren't then compiled with the
> C compiler and built into the extension module, right?
>
No, they are just installed with the package.
Do you just need to control the build order, so your preprocessor runs
first? You can over-ride "build" to make that happen. Or use something like
./setup.py build_prep build_ext build
- --Guy
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iEYEARECAAYFAlXocnwACgkQ0Bme0QyNhPSBrACgnuRY1BK8lJwZHyY+PJjQn52g
wKUAn0lEt/qlNRMkyno26Uv0G42syMjt
=E9Jf
-----END PGP SIGNATURE-----
More information about the devel
mailing list