-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update setup.py, include numpy later and string formatting
- Loading branch information
Showing
2 changed files
with
23 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ | |
import os.path as osp | ||
import sys | ||
|
||
import numpy | ||
from setuptools import Extension, setup | ||
|
||
|
||
|
@@ -14,40 +13,45 @@ def read(*parts): | |
return open(osp.join(get_script_path(), *parts)).read() | ||
|
||
|
||
lttbc_py = Extension('lttbc', sources=['lttbc.c'], | ||
class numpy_get_include: | ||
def __str__(self): | ||
import numpy | ||
return numpy.get_include() | ||
|
||
|
||
lttbc_py = Extension("lttbc", sources=["lttbc.c"], | ||
define_macros=[ | ||
('NPY_NO_DEPRECATED_API', 'NPY_1_7_API_VERSION')], | ||
include_dirs=[numpy.get_include(), | ||
("NPY_NO_DEPRECATED_API", "NPY_1_7_API_VERSION")], | ||
include_dirs=[numpy_get_include(), | ||
get_script_path()], | ||
) | ||
|
||
setup( | ||
name="lttbc", | ||
author="European XFEL GmbH", | ||
use_scm_version=True, | ||
include_dirs=[numpy.get_include(), get_script_path()], | ||
ext_modules=[lttbc_py], | ||
author_email="[email protected]", | ||
maintainer="Dennis Goeries", | ||
url="https://github.com/dgoeries/lttbc/", | ||
description="Largest triangle three buckets module for Python written in C", | ||
long_description=read("README.txt"), | ||
long_description_content_type='text/markdown', | ||
long_description_content_type="text/markdown", | ||
license="MIT", | ||
install_requires=['numpy'], | ||
setup_requires=['setuptools_scm'], | ||
install_requires=["numpy"], | ||
setup_requires=["setuptools_scm"], | ||
python_requires=">=3.5", | ||
classifiers=[ | ||
'Development Status :: 5 - Production/Stable', | ||
'Environment :: Console', | ||
'Intended Audience :: Developers', | ||
'Intended Audience :: Science/Research', | ||
'License :: OSI Approved :: MIT License', | ||
'Operating System :: OS Independent', | ||
'Programming Language :: Python :: 3', | ||
'Programming Language :: Python :: Implementation :: CPython', | ||
'Topic :: Scientific/Engineering :: Information Analysis', | ||
'Topic :: Scientific/Engineering :: Physics', | ||
'Topic :: Scientific/Engineering :: Visualization', | ||
"Development Status :: 5 - Production/Stable", | ||
"Environment :: Console", | ||
"Intended Audience :: Developers", | ||
"Intended Audience :: Science/Research", | ||
"License :: OSI Approved :: MIT License", | ||
"Operating System :: OS Independent", | ||
"Programming Language :: Python :: 3", | ||
"Programming Language :: Python :: Implementation :: CPython", | ||
"Topic :: Scientific/Engineering :: Information Analysis", | ||
"Topic :: Scientific/Engineering :: Physics", | ||
"Topic :: Scientific/Engineering :: Visualization", | ||
], | ||
) |