123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- # from glob import glob
- from os import path
- from setuptools import Extension, setup
- ROOT_DIR = path.dirname(path.realpath(__file__))
- MOD_DIR = path.join(ROOT_DIR, 'cpython')
- SRC_DIR = path.join(ROOT_DIR, 'src')
- INCL_DIR = path.join(ROOT_DIR, 'include')
- EXT_DIR = path.join(ROOT_DIR, 'ext')
- sources = (
- # glob(path.join(SRC_DIR, '*.c')) +
- # glob(path.join(MOD_DIR, '*.c')) +
- [
- path.join(EXT_DIR, 'xxHash', 'xxhash.c'),
- path.join(EXT_DIR, 'openldap', 'libraries', 'liblmdb', 'mdb.c'),
- path.join(EXT_DIR, 'openldap', 'libraries', 'liblmdb', 'midl.c'),
- ]
- )
- compile_args = ['-std=c99', '-DDEBUG', '-g3']
- setup(
- name="lsup_rdf",
- version="1.0a1",
- ext_modules=[
- Extension(
- "lsup_rdf.term",
- [
- path.join(EXT_DIR, 'xxHash', 'xxhash.c'),
- path.join(SRC_DIR, 'buffer.c'),
- path.join(SRC_DIR, 'term.c'),
- path.join(MOD_DIR, 'term_mod.c'),
- ],
- include_dirs=[INCL_DIR],
- libraries=['uuid'],
- extra_compile_args=compile_args,
- ),
- Extension(
- "lsup_rdf.triple",
- [
- path.join(EXT_DIR, 'xxHash', 'xxhash.c'),
- path.join(SRC_DIR, 'buffer.c'),
- path.join(SRC_DIR, 'term.c'),
- path.join(SRC_DIR, 'triple.c'),
- path.join(MOD_DIR, 'triple_mod.c'),
- ],
- include_dirs=[INCL_DIR],
- libraries=['uuid'],
- extra_compile_args=compile_args,
- ),
- ],
- )
|