forked from innobi/pantab
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
62 lines (53 loc) · 2.01 KB
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
import os
import sys
from glob import glob
import numpy as np
from setuptools import Extension, find_packages, setup
here = os.path.abspath(os.path.dirname(__file__))
with open(os.path.join(here, "README.md"), encoding="utf-8") as f:
long_description = f.read()
# MSVC compiler has different flags; assume that's what we are using on Windows
if os.name == "nt":
# Enable extra warnings except implicit cast, which throws a few
# see https://bugzilla.mozilla.org/show_bug.cgi?id=857863 for justification
extra_compile_args = ["/WX", "/wd4244"]
else:
extra_compile_args = ["-Wextra", "-Werror"]
if "--debug" in sys.argv:
extra_compile_args.extend(["-g", "-UNDEBUG", "-O0"])
pantab_module = Extension(
"libpantab",
include_dirs=[np.get_include()],
define_macros=[("NPY_NO_DEPRECATED_API", "0")],
sources=list(glob("pantab/src/*.c")),
depends=list(glob("pantab/src/*.h")),
extra_compile_args=extra_compile_args,
)
setup(
name="pantab",
version="2.1.1",
description="Converts pandas DataFrames into Tableau Hyper Extracts and back",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/WillAyd/pantab",
author="Will Ayd",
author_email="william.ayd@icloud.com",
license="BSD",
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Topic :: Office/Business",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
],
keywords="tableau visualization pandas dataframe",
packages=find_packages(),
package_data={"": ["*.h"], "pantab.tests": ["data/*"]},
data_files=[("", ["LICENSE.txt", "README.md"])],
python_requires=">=3.8",
install_requires=["pandas>=1.0.0", "tableauhyperapi<0.0.14567", "numpy"],
extras_require={"dev": ["pytest"]},
ext_modules=[pantab_module],
)