2 from distutils
import sysconfig
5 print(
'-I' + sysconfig.get_python_inc() +
' -I' + sysconfig.get_python_inc(plat_specific=
True))
7 flags=sysconfig.get_config_var(
'CFLAGS').split()
8 for unflag
in [
'-Wno-unused-result',
'-Wstrict-prototypes']:
9 if flags.count(unflag) > 0:
11 print(
' '.join(flags))
13 print(
'-lpython' + sysconfig.get_config_var(
'VERSION') +
' ' + sysconfig.get_config_var(
'LIBS') +
' ' + sysconfig.get_config_var(
'SYSLIBS'))
15 print(sysconfig.get_config_var(
'LDFLAGS') +
' -L' + sysconfig.get_config_var(
'LIBPL'))
16 if option==
'headerdir':
17 print(sysconfig.get_python_inc())
19 print(sysconfig.get_config_var(
'VERSION'))