Skip to content

Commit

Permalink
Fix compilation errors
Browse files Browse the repository at this point in the history
  • Loading branch information
bab2min committed Jul 31, 2024
1 parent a0d59b1 commit 63f7027
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,13 @@ 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")
add_definitions(-D__SSE2__)
elseif (TARGET_ARCH STREQUAL "avx2")
set (ADDITIONAL_FLAGS "/arch:AVX2")
add_definitions(-D__SSE2__)
endif()

set ( CMAKE_C_FLAGS_DEBUG "-DDEBUG -DC_FLAGS -Zc:__cplusplus -Zi -Od ${ADDITIONAL_FLAGS}" )
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
numpy>=1.10.0
numpy>=1.10.0,<2
5 changes: 4 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down

0 comments on commit 63f7027

Please sign in to comment.