Permalink
Browse files

Add setup.py warning.

Make sure the user does not try to run the setup.py from the source tree.
  • Loading branch information...
1 parent d88f017 commit 986770b2da89a6bdd62e7504abefb6c88473419e @thewtex committed Nov 3, 2011
Showing with 9 additions and 1 deletion.
  1. +1 −1 readme.rst
  2. +8 −0 setup.py
View
@@ -17,7 +17,7 @@ This repository has CMake utilities for building Cython projects with CMake.
The rectangle example from the Cython documentation is built to demonstrate
their use.
-The advantages of this build system include:
+The features of this build system include:
- Easy configuration of build settings.
- Easy integration of external libraries.
View
@@ -1,6 +1,14 @@
from setuptools import setup
from distutils.sysconfig import get_python_lib
import glob
+import os
+import sys
+
+if os.path.exists('readme.rst'):
+ print("""The setup.py script should be executed from the build directory.
+
+Please see the file 'readme.rst' for further instructions.""")
+ sys.exit(1)
setup(

0 comments on commit 986770b

Please sign in to comment.