1
0
mirror of https://github.com/myhdl/myhdl.git synced 2024-12-14 07:44:38 +08:00
myhdl/setup.py

70 lines
2.1 KiB
Python
Raw Normal View History

""" myhdl's distribution and installation script. """
2003-01-30 12:19:52 +00:00
2015-03-24 03:57:27 -04:00
import ast
import fnmatch
2015-03-24 03:57:27 -04:00
import re
import os
2003-01-30 17:19:02 +00:00
import sys
from collections import defaultdict
Update makeflow (#396) * Clean up verify convert warnings * Rewrote test and remove Xfail, test is passing now (is it supposed to fail?) * Rewrote test and remove Xfail, test is passing now (is it supposed to fail?) * Fixed all tests to handle the analyze/verify deprecation * Fixed to catch the correct error, List of signals as a port is not supported * Add a way to search for and add myhdl.vpi * Add explict test to check for deprecation case * Change warning from UserWarning (which is the default) to DeprecationWarning * Change test operation from script to makefile * No longer use travis * Add some ANSI colored logging * Fixed test to look for DeprecationWarning * Add lining step * Add linting step * Add linting step * Remove matrix step * Add work/ to clean list * Hide echo commands in window * The word test is reserved in pytest only for tests, doen't use it for any thing else, like blocks * Add myhdl.vpi to clean * Mark these tests as xfail, for now, * Fix and unmark xfail 2 tests * Add black support * Remove python2 only testing * Need to relook at this test, it performs differently for verilog and vhdl * Add RTL files to the list * Need to relook at this test, it performs differently for verilog and vhdl * Upgrade to DeprecationWarnings * Initial checkin with passing flow for new convert VHDL/Verilog, there are a few xfail tests that need to be debugged * Add more examples for the Deprecation cases, toVHDL and toVerilog * Fix deprecations catching * Fix pytest to use pytest.ini * Add pypi release steps * Fix intbv error * Fix indent * Update to do a release * Add checkout to step * Update Python versions * Add dependancy on tag on push
2022-12-17 12:21:08 +00:00
if sys.version_info < (3, 7):
raise RuntimeError("Python version 3.7+ required.")
2006-03-08 16:04:18 +00:00
2003-01-23 23:21:31 +00:00
# Prefer setuptools over distutils
2003-01-30 17:19:02 +00:00
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
2015-03-24 03:57:27 -04:00
_version_re = re.compile(r'__version__\s+=\s+(.*)')
with open('myhdl/__init__.py', 'rb') as f:
version = str(ast.literal_eval(_version_re.search(
f.read().decode('utf-8')).group(1)))
data_root = 'share/myhdl'
cosim_data = defaultdict(list)
for base, dir, files in os.walk('cosimulation'):
for pat in ('*.c', 'Makefile*', '*.py', '*.v', '*.txt'):
good = fnmatch.filter(files, pat)
if good:
cosim_data[base].extend(os.path.join(base, f) for f in good)
2015-03-24 03:57:27 -04:00
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name="myhdl",
2015-03-24 03:57:27 -04:00
version=version,
description="Python as a Hardware Description Language",
long_description=read('README.md'),
long_description_content_type='text/markdown',
author="Jan Decaluwe",
author_email="jan@jandecaluwe.com",
url="http://www.myhdl.org",
packages=['myhdl', 'myhdl.conversion'],
data_files=[(os.path.join(data_root, k), v) for k, v in cosim_data.items()],
license="LGPL",
platforms='any',
keywords="HDL ASIC FPGA hardware design",
Update makeflow (#396) * Clean up verify convert warnings * Rewrote test and remove Xfail, test is passing now (is it supposed to fail?) * Rewrote test and remove Xfail, test is passing now (is it supposed to fail?) * Fixed all tests to handle the analyze/verify deprecation * Fixed to catch the correct error, List of signals as a port is not supported * Add a way to search for and add myhdl.vpi * Add explict test to check for deprecation case * Change warning from UserWarning (which is the default) to DeprecationWarning * Change test operation from script to makefile * No longer use travis * Add some ANSI colored logging * Fixed test to look for DeprecationWarning * Add lining step * Add linting step * Add linting step * Remove matrix step * Add work/ to clean list * Hide echo commands in window * The word test is reserved in pytest only for tests, doen't use it for any thing else, like blocks * Add myhdl.vpi to clean * Mark these tests as xfail, for now, * Fix and unmark xfail 2 tests * Add black support * Remove python2 only testing * Need to relook at this test, it performs differently for verilog and vhdl * Add RTL files to the list * Need to relook at this test, it performs differently for verilog and vhdl * Upgrade to DeprecationWarnings * Initial checkin with passing flow for new convert VHDL/Verilog, there are a few xfail tests that need to be debugged * Add more examples for the Deprecation cases, toVHDL and toVerilog * Fix deprecations catching * Fix pytest to use pytest.ini * Add pypi release steps * Fix intbv error * Fix indent * Update to do a release * Add checkout to step * Update Python versions * Add dependancy on tag on push
2022-12-17 12:21:08 +00:00
python_requires='>=3.7',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Intended Audience :: Developers',
'Topic :: Scientific/Engineering :: Electronic Design Automation (EDA)',
'License :: OSI Approved :: GNU Lesser General Public License v2 (LGPLv2)',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
2019-03-12 17:51:12 +02:00
'Programming Language :: Python :: 3.7',
Update makeflow (#396) * Clean up verify convert warnings * Rewrote test and remove Xfail, test is passing now (is it supposed to fail?) * Rewrote test and remove Xfail, test is passing now (is it supposed to fail?) * Fixed all tests to handle the analyze/verify deprecation * Fixed to catch the correct error, List of signals as a port is not supported * Add a way to search for and add myhdl.vpi * Add explict test to check for deprecation case * Change warning from UserWarning (which is the default) to DeprecationWarning * Change test operation from script to makefile * No longer use travis * Add some ANSI colored logging * Fixed test to look for DeprecationWarning * Add lining step * Add linting step * Add linting step * Remove matrix step * Add work/ to clean list * Hide echo commands in window * The word test is reserved in pytest only for tests, doen't use it for any thing else, like blocks * Add myhdl.vpi to clean * Mark these tests as xfail, for now, * Fix and unmark xfail 2 tests * Add black support * Remove python2 only testing * Need to relook at this test, it performs differently for verilog and vhdl * Add RTL files to the list * Need to relook at this test, it performs differently for verilog and vhdl * Upgrade to DeprecationWarnings * Initial checkin with passing flow for new convert VHDL/Verilog, there are a few xfail tests that need to be debugged * Add more examples for the Deprecation cases, toVHDL and toVerilog * Fix deprecations catching * Fix pytest to use pytest.ini * Add pypi release steps * Fix intbv error * Fix indent * Update to do a release * Add checkout to step * Update Python versions * Add dependancy on tag on push
2022-12-17 12:21:08 +00:00
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
2019-03-12 17:51:12 +02:00
'Programming Language :: Python :: 3 :: Only',
]
)