sambayless / monosat

MonoSAT - An SMT solver for Monotonic Theories
MIT License
106 stars 29 forks source link

distutils -> setuptools #19

Closed yasoob closed 5 years ago

yasoob commented 5 years ago

Fixes the "Unknown distribution option: 'install_requires'" error while running make install.

distribute is deprecated according to http://pythonhosted.org/distribute/:

Distribute is a deprecated fork of the Setuptools project.

Since the Setuptools 0.7 release, Setuptools and Distribute have merged and
Distribute is no longer being maintained. All ongoing effort should reference the
Setuptools project and the Setuptools documentation.
sambayless commented 5 years ago

Thanks for submitting a patch! Can I ask which OS/platform/distribution you've tested this on? I'm concerned that if I merge this patch in, it might be the case that older systems will no longer be able to install the python API correctly (I'm not sure yet if that is the case or now).

yasoob commented 5 years ago

I tested this on Mac OS High Sierra with Python 3.7.

yasoob commented 5 years ago

I also successfully installed it on Ubuntu 18.04.1 LTS with this patch. Python version 3.6.7. Once you merge this patch, I can also write install instructions for Ubuntu and add them to the readme.

sambayless commented 5 years ago

Hmm, I also need to maintain support for older distributions. What if we instead did:

try:
   from setuptools import setup
except ImportError as e:
   from distutils.core import setup

(As seen here: https://stackoverflow.com/a/25359853)

yasoob commented 5 years ago

Yeah that seems reasonable. 👍