diff --git a/CMakeLists.txt b/CMakeLists.txt index cc4fba6..2e04595 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,6 +20,7 @@ if(MSVC) set (ADDITIONAL_FLAGS "") elseif (TARGET_ARCH STREQUAL "sse2") set (ADDITIONAL_FLAGS "/arch:SSE2") + add_definitions(-D__SSE2__) elseif (TARGET_ARCH STREQUAL "avx") set (ADDITIONAL_FLAGS "/arch:AVX") elseif (TARGET_ARCH STREQUAL "avx2") diff --git a/requirements.txt b/requirements.txt index 152d9da..7e6c5fa 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1 @@ -numpy>=1.10.0 \ No newline at end of file +numpy>=1.10.0,<2 \ No newline at end of file diff --git a/setup.py b/setup.py index 3844654..cccd77e 100644 --- a/setup.py +++ b/setup.py @@ -212,7 +212,10 @@ def build_extension(self, ext): # if target is in 64bit, remove 'none' if struct.calcsize("P") == 8: - arch_levels.remove('none') + try: + arch_levels.remove('none') + except ValueError: + pass modules = [] if len(arch_levels) > 1: