-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
41 lines (33 loc) · 1.02 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
"""
Micro80: Setup.py
Sas2k 2024 ~ 2025
- Micro80 Cython Compilation Setup -
"""
from setuptools import setup, find_packages
from Cython.Build import cythonize
import os
files = os.listdir("Micro80")
compile = []
options = input("Do you wish to cythonize all files? (y/n): ")
if options.lower() == "n":
file = input("Enter the file names separated by a space: ")
files = file.split(" ")
for i in range(len(files)):
if (
files[i] != "__init__.py"
and files[i] != "__main__.py"
and files[i] != "Assembler.py"
and files[i].endswith(".py")
):
compile.append("Micro80/" + files[i])
else:
for i in range(len(files)):
if (
files[i] != "__init__.py"
and files[i] != "__main__.py"
and files[i] != "Assembler.py"
and files[i].endswith(".py")
):
compile.append("Micro80/" + files[i])
print(compile)
setup(name="Micro80", ext_modules=cythonize(compile), packages=find_packages())