-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup.py
61 lines (54 loc) · 1.43 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
import setuptools
from distutils.command.build_ext import build_ext
from distutils.core import Extension
class LilangBuildExt(build_ext):
def get_ext_filename(self, ext_name):
filename = super().get_ext_filename(ext_name)
filename_parts = filename.split('.')
return f'{filename_parts[0]}.{filename_parts[-1]}'
iolib = Extension(
'lilang.lib.libio',
sources=['lilang/lib/io.c'],
)
strlib = Extension(
'lilang.lib.libstr',
sources=['lilang/lib/str.c'],
)
vaarglib = Extension(
'lilang.lib.libvaarg',
sources=['lilang/lib/vaarg.c'],
)
setuptools.setup(
name="lilang",
version="0.3.0",
author="Piotr Resztak",
author_email="[email protected]",
description="Lilang package",
packages=setuptools.find_packages(),
package_data={'lilang': ['lib/io.li', 'lib/str.li', 'lib/vaarg.li']},
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: POSIX",
],
python_requires='>=3.8.2',
install_requires=[
"sly>=0.4",
"llvmlite>=0.33.0",
"click>=7.1.2"
],
extras_require={
"dev": [
"isort", "flake8"
]
},
entry_points={
'console_scripts': [
'lilang = lilang.lilang:main'
],
},
cmdclass={
'build_ext': LilangBuildExt,
},
ext_modules=[iolib, strlib, vaarglib]
)