mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-08 06:22:14 +02:00
compiler fixes for GCC/clang
This commit is contained in:
parent
8faaa36913
commit
b60b9bb312
2 changed files with 13 additions and 3 deletions
|
@ -24,6 +24,16 @@ macro(SETUP_HIFI_LIBRARY)
|
|||
set_source_files_properties(${SRC} PROPERTIES COMPILE_FLAGS -mavx)
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
# add compiler flags to AVX2 source files
|
||||
file(GLOB_RECURSE AVX2_SRCS "src/avx2/*.cpp" "src/avx2/*.c")
|
||||
foreach(SRC ${AVX2_SRCS})
|
||||
if (WIN32)
|
||||
set_source_files_properties(${SRC} PROPERTIES COMPILE_FLAGS /arch:AVX2)
|
||||
elseif (APPLE OR UNIX)
|
||||
set_source_files_properties(${SRC} PROPERTIES COMPILE_FLAGS "-mavx2 -mfma")
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
setup_memory_debugger()
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
//
|
||||
// AudioSRC_avx.cpp
|
||||
// AudioSRC_avx2.cpp
|
||||
// libraries/audio/src
|
||||
//
|
||||
// Created by Ken Cooke on 6/5/16.
|
||||
|
@ -16,8 +16,8 @@
|
|||
|
||||
#include "../AudioSRC.h"
|
||||
|
||||
#ifndef __AVX__
|
||||
#error Must be compiled with /arch:AVX or -mavx.
|
||||
#ifndef __AVX2__
|
||||
#error Must be compiled with /arch:AVX2 or -mavx2 -mfma.
|
||||
#endif
|
||||
|
||||
// high/low part of int64_t
|
Loading…
Reference in a new issue