Skip to content

Commit d9fb777

Browse files
committed
setup.{py,cfg}: Convert more from setup.py into setup.cfg .
Also, get rid of detailed python version classifiers, I guess they do not mean much.
1 parent 99e8d4d commit d9fb777

3 files changed

Lines changed: 30 additions & 35 deletions

File tree

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
Pure-python wrapper for libusb-1.0
1+
.. contents::
22

33
Supports all transfer types, both in synchronous and asynchronous mode.
44

setup.cfg

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,31 @@
1+
[metadata]
2+
name = libusb1
3+
url = https://github.com/vpelletier/python-libusb1
4+
author = Vincent Pelletier
5+
author_email = plr.vincent@gmail.com
6+
classifiers =
7+
Intended Audience :: Developers
8+
License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)
9+
Operating System :: OS Independent
10+
Programming Language :: Python :: 3
11+
Programming Language :: Python :: Implementation :: CPython
12+
Programming Language :: Python :: Implementation :: PyPy
13+
Topic :: Software Development :: Libraries
14+
Topic :: System :: Hardware :: Hardware Drivers
15+
license = LGPLv2.1+
16+
description = Pure-python wrapper for libusb-1.0
17+
long_description = file: README.rst
18+
keywords = usb, libusb
19+
platforms = any
20+
21+
[options]
22+
packages = find:
23+
# For backward compatibility with python-libusb1 < 1.6
24+
py_modules = libusb1
25+
26+
[options.package_data]
27+
usb1 = libusb-1.0.dll
28+
129
[versioneer]
230
VCS = git
331
style = pep440

setup.py

Lines changed: 1 addition & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
# License along with this library; if not, write to the Free Software
1515
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
1616

17-
from setuptools import find_packages
1817
from setuptools import setup
1918
from setuptools import Command
2019
from codecs import open
@@ -144,47 +143,15 @@ def run(self):
144143
)
145144
cmdclass['update_libusb'] = update_libusb
146145

147-
long_description = open(
148-
os.path.join(os.path.dirname(__file__), 'README.rst'),
149-
encoding='utf8',
150-
).read()
151-
152146
setup(
153-
name='libusb1',
154-
description=next(x for x in long_description.splitlines() if x.strip()),
155-
long_description='.. contents::\n\n' + long_description,
156-
keywords='usb libusb',
157147
version=versioneer.get_version(),
158148
cmdclass=cmdclass,
159-
author='Vincent Pelletier',
160-
author_email='plr.vincent@gmail.com',
161-
url='http://github.com/vpelletier/python-libusb1',
162-
license='LGPLv2.1+',
163-
platforms=['any'],
164-
py_modules=['libusb1'],
165-
packages=find_packages(),
166-
package_data={
167-
"usb1": ["libusb-1.0.dll"],
168-
},
149+
169150
entry_points={
170151
'pyinstaller40': [
171152
'hook-dirs=usb1.__pyinstaller:get_hook_dirs',
172153
'tests=usb1.__pyinstaller:get_PyInstaller_tests']
173154
},
174-
classifiers=[
175-
'Intended Audience :: Developers',
176-
'License :: OSI Approved :: GNU Lesser General Public License v2 or later (LGPLv2+)',
177-
'Operating System :: OS Independent',
178-
'Programming Language :: Python :: 3',
179-
'Programming Language :: Python :: 3.4',
180-
'Programming Language :: Python :: 3.5',
181-
'Programming Language :: Python :: 3.6',
182-
'Programming Language :: Python :: 3.7',
183-
'Programming Language :: Python :: Implementation :: CPython',
184-
'Programming Language :: Python :: Implementation :: PyPy',
185-
'Topic :: Software Development :: Libraries',
186-
'Topic :: System :: Hardware :: Hardware Drivers',
187-
],
188155
setup_requires=(
189156
['wheel']
190157
if 'bdist_wheel' in sys.argv else

0 commit comments

Comments
 (0)