Commit 010b34e8 authored by Myles Hollowed's avatar Myles Hollowed

Remove redundant lines in setup.py

Fix spelling error in rect.pyx
Remove rect.cpp from the commit. Should not have been added.
parent 36f00b4e
This source diff could not be displayed because it is too large. You can view the blob instead.
# disutils: language = c++ # distutils: language = c++
# disutils: sources = Rectangle.cpp # distutils: sources = Rectangle.cpp
# Decalre the class with cdef # Decalre the class with cdef
cdef extern from "Rectangle.h" namespace "shapes": cdef extern from "Rectangle.h" namespace "shapes":
......
from distutils.core import setup, Extension from distutils.core import setup, Extension
from Cython.Build import cythonize from Cython.Build import cythonize
setup(ext_modules = cythonize(Extension( setup(ext_modules = cythonize("rect.pyx"))
"rect", # the extension name
sources=["rect.pyx", "Rectangle.cpp"], # the Cython source and
# additional C++ source files
language="c++", # generate and compile C++ code
)))
...@@ -7,6 +7,8 @@ except ImportError: ...@@ -7,6 +7,8 @@ except ImportError:
print("Module rect has not yet been built") print("Module rect has not yet been built")
print("Please run $python setup.py build_ext --inplace") print("Please run $python setup.py build_ext --inplace")
print("Then try again") print("Then try again")
import sys
sys.exit()
x0, y0, x1, y1 = 1, 2, 3, 4 x0, y0, x1, y1 = 1, 2, 3, 4
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment