Python.h quirk

Hal Murray hmurray at
Sun Sep 22 08:34:47 UTC 2019

esr at said:
> The problem, of course, is that the Python 2 and Python3 development package
> both want to own Python.h,  and the name is not versioned. 

They are in different directories.  The version number is in the directory.
  [murray at hgm raw]$ locate Python.h
  [murray at hgm raw]$

I don't know what the "m" in "3.7m" is for.

waf sets things up with a --I/usr/include/python2.7 and -lpython2.7
[murray at hgm raw]$ ldd ./build/main/pylib/ (0x00007ffc5e173000) => /lib64/ (0x00007faec6933000) => /lib64/ (0x00007faec6912000) => /lib64/ (0x00007faec690c000) => /lib64/ (0x00007faec6907000) => /lib64/ (0x00007faec67c1000) => /lib64/ (0x00007faec67b7000) => /lib64/ (0x00007faec64d4000) => /lib64/ (0x00007faec630e000)
        /lib64/ (0x00007faec6bcd000) => /lib64/ (0x00007faec62f4000)
[murray at hgm raw]$ 

It works if I say:
  python3 ./waf ...

Seems like a simple bug in waf.  It's getting the version info from the command line argument rather than asking the running python what version it is.  Or something like that.

These are my opinions.  I hate spam.

More information about the devel mailing list