33import os
44import sys
55
6- from setuptools import setup , Command
7- from setuptools .extension import Extension
6+ from setuptools import setup , Command , Extension
7+ # from setuptools.extension import Extension
88
99# NOTE: setuptools build_ext does not work properly with Cython code
1010from distutils .command .build_ext import build_ext as _build_ext
@@ -44,37 +44,37 @@ def run(self):
4444
4545 _build_ext .run (self )
4646
47- class TestCommand (Command ):
48- user_options = []
47+ # class TestCommand(Command):
48+ # user_options = []
4949
50- def initialize_options (self ):
51- pass
50+ # def initialize_options(self):
51+ # pass
5252
53- def finalize_options (self ):
54- pass
53+ # def finalize_options(self):
54+ # pass
5555
56- def run (self ):
57- import subprocess , os , tempfile , shutil
56+ # def run(self):
57+ # import subprocess, os, tempfile, shutil
5858
59- old_path = os .getcwd ()
60- tempdir_path = tempfile .mkdtemp ()
61- try :
62- shutil .copytree ('./tests' , tempdir_path , dirs_exist_ok = True )
63- os .chdir (tempdir_path )
59+ # old_path = os.getcwd()
60+ # tempdir_path = tempfile.mkdtemp()
61+ # try:
62+ # shutil.copytree('./tests', tempdir_path, dirs_exist_ok=True)
63+ # os.chdir(tempdir_path)
6464
65- if subprocess .call ([sys .executable , 'runtests.py' ]):
66- raise SystemExit ("Doctest failures" )
65+ # if subprocess.call([sys.executable, 'runtests.py']):
66+ # raise SystemExit("Doctest failures")
6767
68- if subprocess .call ([sys .executable , 'setup.py' , 'build_ext' , '--inplace' ]) or \
69- subprocess .call ([sys .executable , '-c' , "import testpplitepy; testpplitepy.test(); testpplitepy.example()" ]):
70- raise SystemExit ("Cython test 1 failure" )
68+ # if subprocess.call([sys.executable, 'setup.py', 'build_ext', '--inplace']) or \
69+ # subprocess.call([sys.executable, '-c', "import testpplitepy; testpplitepy.test(); testpplitepy.example()"]):
70+ # raise SystemExit("Cython test 1 failure")
7171
72- if subprocess .call ([sys .executable , 'setup2.py' , 'build_ext' , '--inplace' ]) or \
73- subprocess .call ([sys .executable , '-c' , "import testpplitepy2; testpplitepy2.test(); testpplitepy2.example()" ]):
74- raise SystemExit ("Cython test 2 failure" )
75- finally :
76- os .chdir (old_path )
77- shutil .rmtree (tempdir_path )
72+ # if subprocess.call([sys.executable, 'setup2.py', 'build_ext', '--inplace']) or \
73+ # subprocess.call([sys.executable, '-c', "import testpplitepy2; testpplitepy2.test(); testpplitepy2.example()"]):
74+ # raise SystemExit("Cython test 2 failure")
75+ # finally:
76+ # os.chdir(old_path)
77+ # shutil.rmtree(tempdir_path)
7878
7979extensions = [
8080 Extension ('pplite.integer_conversions' , sources = ['pplite/integer_conversions.pyx' ]),
@@ -85,8 +85,10 @@ def run(self):
8585 Extension ('pplite.bounding_box' , sources = ['pplite/bounding_box.pyx' ]),
8686 Extension ('pplite.polyhedron' , sources = ['pplite/polyhedron.pyx' ])
8787 ]
88- #finish writing setup at some point
88+
8989setup (
9090 ext_modules = extensions ,
91- cmdclass = {'build_ext' : build_ext , 'test' : TestCommand },
91+ cmdclass = {'build_ext' : build_ext },
92+ # long_description=open('README.rst').read(),
93+ # long_description_content_type='text/markdown',
9294)
0 commit comments