| 1 |
Import('env') |
Import('env') |
| 2 |
extfn_env = env.Copy() |
extfn_env = env.Copy() |
| 3 |
|
|
| 4 |
|
if extfn_env.get('WITH_PYTHON'): |
| 5 |
|
extfn_env.Append(CPPDEFINES=['-DWITH_PYTHON']) |
| 6 |
|
|
| 7 |
srcs = Split(""" |
srcs = Split(""" |
| 8 |
extpy.c |
extpy.c |
| 9 |
""") |
""") |
| 14 |
,CPPPATH=[env.get('PYTHON_CPPPATH')] |
,CPPPATH=[env.get('PYTHON_CPPPATH')] |
| 15 |
) |
) |
| 16 |
|
|
| 17 |
targets = [] |
lib = extfn_env.SharedLibrary("extpy",srcs |
| 18 |
targets.append( extfn_env.SharedLibrary("extpy",srcs) ) |
,SHLIBSUFFIX = env['EXTLIB_SUFFIX'] |
| 19 |
|
,SHLIBPREFIX = env['EXTLIB_PREFIX'] |
| 20 |
|
) |
| 21 |
|
|
| 22 |
# To run the test, type |
# To run the test, type |
| 23 |
# ascdev johnpye/extpy/extpytest.py |
# ascdev johnpye/extpy/extpytest.py |
| 24 |
|
|
| 25 |
# Return the targs |
# Return the targs |
| 26 |
env['extfns'] += targets |
env['extfns'] += [lib] |
| 27 |
|
|
| 28 |
# vim: set syntax=python: |
# vim: set syntax=python: |
| 29 |
|
|