mirror of
https://github.com/robmcmullen/atrcopy.git
synced 2024-11-26 08:49:50 +00:00
Attempt to fix setup script when numpy isn't present
* pip appears to be brokes; numpy can't be automatically installed as a dependency * added instructions to README
This commit is contained in:
parent
76c7028c0a
commit
463aa15479
10
README.rst
10
README.rst
@ -1,4 +1,4 @@
|
||||
ATRCopy
|
||||
atrcopy
|
||||
=======
|
||||
|
||||
Utilities to list files on and extract files from Atari 8-bit emulator disk
|
||||
@ -7,7 +7,13 @@ images. Eventually, I hope to add support for these images to pyfilesystem.
|
||||
Prerequisites
|
||||
-------------
|
||||
|
||||
Starting with ATRcopy 2.0, numpy is required.
|
||||
Starting with atrcopy 2.0, numpy is required.
|
||||
|
||||
The standard python install tool, pip, does not seem to be able to handle the
|
||||
automatic installation of numpy, so to install atrcopy, use::
|
||||
|
||||
pip install numpy
|
||||
pip install atrcopy
|
||||
|
||||
|
||||
References
|
||||
|
@ -5,7 +5,10 @@ __version__ = "2.1.0"
|
||||
|
||||
import types
|
||||
|
||||
import numpy as np
|
||||
try:
|
||||
import numpy as np
|
||||
except ImportError:
|
||||
raise RuntimeError("atrcopy %s requires numpy" % __version__)
|
||||
|
||||
|
||||
class AtrError(RuntimeError):
|
||||
|
9
setup.py
9
setup.py
@ -5,7 +5,12 @@ try:
|
||||
except ImportError:
|
||||
from distutils.core import setup
|
||||
|
||||
import atrcopy
|
||||
try:
|
||||
import atrcopy
|
||||
version = atrcopy.__version__
|
||||
except RuntimeError, e:
|
||||
# If numpy isn't present, pull the version number from the error string
|
||||
version = str(e).split()[1]
|
||||
|
||||
classifiers = [
|
||||
"Programming Language :: Python :: 2",
|
||||
@ -19,7 +24,7 @@ with open("README.rst", "r") as fp:
|
||||
long_description = fp.read()
|
||||
|
||||
setup(name="atrcopy",
|
||||
version=atrcopy.__version__,
|
||||
version=version,
|
||||
author="Rob McMullen",
|
||||
author_email="feedback@playermissile.com>",
|
||||
url="https://github.com/robmcmullen/atrcopy",
|
||||
|
Loading…
Reference in New Issue
Block a user