

import setuptools
import numpy as np
import sys

#platform specific compilation flags
if sys.platform == 'win32':
    extra_compile_args = ['/W4']
else:
    extra_compile_args=['-std=c99', '-Wall', '-Wextra'] 

c_ext = setuptools.Extension("_creader",
                    sources = [
                        "src/creader_module.c", 
                        "src/cluster_reader.c", 
                        "src/ClusterReader.c",
                        "src/RawFileReader.c",
                        "src/arr_desc.c",
                        "src/raw_reader.c"
                        ],
                    include_dirs=[
                            np.get_include(),"src/"
                            ],
                    extra_compile_args=extra_compile_args,
)
                    

c_ext.language = 'c'
setuptools.setup(
    name= 'creader',
    version = '2023.10.25',
    description = 'Reading cluster files',
    packages=setuptools.find_packages(exclude=[
        'tests',
    ]),
    ext_modules=[c_ext],
     install_requires=[
        'numpy',
    ]
)
