Ejemplo n.º 1
0
def localpath(*args):
    return op.abspath(reduce(op.join, (op.dirname(__file__),)+args))

if sys.version_info[0] >= 3:
    # Shamelessly stolen from Cython 0.14
    import lib2to3.refactor
    from distutils.command.build_py \
         import build_py_2to3 as build_py
else:
    from distutils.command.build_py import build_py

# --- Determine HDF5 location -------------------------------------------------

settings = configure.scrape_eargs()          # lowest priority
settings.update(configure.scrape_cargs())    # highest priority

HDF5 = settings.get('hdf5')


# --- Create extensions -------------------------------------------------------

if sys.platform.startswith('win'):
    COMPILER_SETTINGS = {
        'libraries'     : ['hdf5dll18','hdf5_hldll'],
        'include_dirs'  : [numpy.get_include(),  localpath('lzf'),
                           localpath('win_include')],
        'library_dirs'  : [],
        'define_macros' : [('H5_USE_16_API', None), ('_HDF5USEDLL_', None)]
    }
    if HDF5 is not None:
Ejemplo n.º 2
0
def localpath(*args):
    return op.abspath(reduce(op.join, (op.dirname(__file__), ) + args))


if sys.version_info[0] >= 3:
    # Shamelessly stolen from Cython 0.14
    import lib2to3.refactor
    from distutils.command.build_py \
         import build_py_2to3 as build_py
else:
    from distutils.command.build_py import build_py

# --- Determine HDF5 location -------------------------------------------------

settings = configure.scrape_eargs()  # lowest priority
settings.update(configure.scrape_cargs())  # highest priority

HDF5 = settings.get('hdf5')

# --- Create extensions -------------------------------------------------------

if sys.platform.startswith('win'):
    COMPILER_SETTINGS = {
        'libraries': ['hdf5dll18', 'hdf5_hldll'],
        'include_dirs':
        [numpy.get_include(),
         localpath('lzf'),
         localpath('win_include')],
        'library_dirs': [],
        'define_macros': [('H5_USE_16_API', None), ('_HDF5USEDLL_', None)]
    }