summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--MANIFEST.in3
-rw-r--r--numpy/core/setup.py3
-rw-r--r--numpy/lib/tests/test__version.py13
-rw-r--r--pavement.py2
4 files changed, 20 insertions, 1 deletions
diff --git a/MANIFEST.in b/MANIFEST.in
index 976e283ed..6f4826478 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -12,6 +12,9 @@ include numpy/random/mtrand/generate_mtrand_c.py
recursive-include numpy/random/mtrand *.pyx *.pxd
# Add build support that should go in sdist, but not go in bdist/be installed
recursive-include numpy/_build_utils *
+# Add sdist files whose use depends on local configuration.
+include numpy/core/src/multiarray/cblasfuncs.c
+include numpy/core/src/multiarray/python_xerbla.c
# Adding scons build related files not found by distutils
recursive-include numpy/core/code_generators *.py *.txt
recursive-include numpy/core *.in *.h
diff --git a/numpy/core/setup.py b/numpy/core/setup.py
index 6d9926d89..361bf9082 100644
--- a/numpy/core/setup.py
+++ b/numpy/core/setup.py
@@ -736,6 +736,7 @@ def configuration(parent_package='',top_path=None):
join('src', 'multiarray', 'array_assign.h'),
join('src', 'multiarray', 'buffer.h'),
join('src', 'multiarray', 'calculation.h'),
+ join('src', 'multiarray', 'cblasfuncs.h'),
join('src', 'multiarray', 'common.h'),
join('src', 'multiarray', 'convert_datatype.h'),
join('src', 'multiarray', 'convert.h'),
@@ -839,6 +840,8 @@ def configuration(parent_package='',top_path=None):
blas_info = get_info('blas_opt', 0)
if blas_info and ('HAVE_CBLAS', None) in blas_info.get('define_macros', []):
extra_info = blas_info
+ # These files are also in MANIFEST.in so that they are always in
+ # the source distribution independently of HAVE_CBLAS.
multiarray_src.extend([join('src', 'multiarray', 'cblasfuncs.c'),
join('src', 'multiarray', 'python_xerbla.c'),
])
diff --git a/numpy/lib/tests/test__version.py b/numpy/lib/tests/test__version.py
index bbafe68eb..993c9d507 100644
--- a/numpy/lib/tests/test__version.py
+++ b/numpy/lib/tests/test__version.py
@@ -48,6 +48,19 @@ def test_dev_a_b_rc_mixed():
assert_(NumpyVersion('1.9.0a2.dev-6acvda54') < '1.9.0a2')
+def test_dev0_version():
+ assert_(NumpyVersion('1.9.0.dev0+Unknown') < '1.9.0')
+ for ver in ['1.9.0', '1.9.0a1', '1.9.0b2', '1.9.0b2.dev0+ffffffff']:
+ assert_(NumpyVersion('1.9.0.dev0+f16acvda') < ver)
+
+ assert_(NumpyVersion('1.9.0.dev0+f16acvda') == '1.9.0.dev0+11111111')
+
+
+def test_dev0_a_b_rc_mixed():
+ assert_(NumpyVersion('1.9.0a2.dev0+f16acvda') == '1.9.0a2.dev0+11111111')
+ assert_(NumpyVersion('1.9.0a2.dev0+6acvda54') < '1.9.0a2')
+
+
def test_raises():
for ver in ['1.9', '1,9.0', '1.7.x']:
assert_raises(ValueError, NumpyVersion, ver)
diff --git a/pavement.py b/pavement.py
index ac857a492..acceed0ad 100644
--- a/pavement.py
+++ b/pavement.py
@@ -89,7 +89,7 @@ try:
GIT_REVISION = "Unknown"
if not setup_py.ISRELEASED:
- FULLVERSION += '.dev-' + GIT_REVISION[:7]
+ FULLVERSION += '.dev0+' + GIT_REVISION[:7]
finally:
sys.path.pop(0)