- remove build time CPU detection, fixed build on ppc64/ppc64le and s390(x)
This commit is contained in:
parent
da31bb8766
commit
3602f24e26
2 changed files with 44 additions and 4 deletions
38
python-blosc-alt-arch.patch
Normal file
38
python-blosc-alt-arch.patch
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
diff -up python-blosc-1.4.1/setup.py.alt-arch python-blosc-1.4.1/setup.py
|
||||
--- python-blosc-1.4.1/setup.py.alt-arch 2017-01-05 15:53:42.581675095 +0100
|
||||
+++ python-blosc-1.4.1/setup.py 2017-01-05 15:54:06.361675095 +0100
|
||||
@@ -19,7 +19,6 @@ import sys
|
||||
from setuptools import Extension
|
||||
from setuptools import setup
|
||||
from glob import glob
|
||||
-import cpuinfo
|
||||
|
||||
########### Check versions ##########
|
||||
|
||||
@@ -93,26 +93,6 @@ else:
|
||||
inc_dirs += glob('c-blosc/internal-complibs/zstd*/common')
|
||||
def_macros += [('HAVE_LZ4', 1), ('HAVE_SNAPPY', 1), ('HAVE_ZLIB', 1), ('HAVE_ZSTD', 1)]
|
||||
|
||||
- # Guess SSE2 or AVX2 capabilities
|
||||
- cpu_info = cpuinfo.get_cpu_info()
|
||||
- # SSE2
|
||||
- if 'sse2' in cpu_info['flags']:
|
||||
- print('SSE2 detected')
|
||||
- CFLAGS.append('-DSHUFFLE_SSE2_ENABLED')
|
||||
- sources += [f for f in glob('c-blosc/blosc/*.c') if 'sse2' in f]
|
||||
- if os.name == 'posix':
|
||||
- CFLAGS.append('-msse2')
|
||||
- elif os.name == 'nt':
|
||||
- def_macros += [('__SSE2__', 1)]
|
||||
- # AVX2
|
||||
- if 'avx2' in cpu_info['flags']:
|
||||
- print('AVX2 detected')
|
||||
- CFLAGS.append('-DSHUFFLE_AVX2_ENABLED')
|
||||
- sources += [f for f in glob('c-blosc/blosc/*.c') if 'avx2' in f]
|
||||
- if os.name == 'posix':
|
||||
- CFLAGS.append('-mavx2')
|
||||
- elif os.name == 'nt':
|
||||
- def_macros += [('__AVX2__', 1)]
|
||||
|
||||
classifiers = """\
|
||||
Development Status :: 5 - Production/Stable
|
||||
Loading…
Add table
Add a link
Reference in a new issue