File tree Expand file tree Collapse file tree 1 file changed +26
-58
lines changed Expand file tree Collapse file tree 1 file changed +26
-58
lines changed Original file line number Diff line number Diff line change 1919# OTHER DEALINGS IN THE SOFTWARE.
2020
2121#this file should contain only compiler and linker flags
22- if (${CMAKE_SYSTEM_PROCESSOR} MATCHES "^aarch" )
23- SET (GMMLIB_COMPILER_FLAGS_COMMON
24- #general warnings
25- #-Wall
26- -Winit-self
27- -Winvalid-pch
28- -Wpointer-arith
29- -Wno-unused
30- -Wno-unknown-pragmas
31- -Wno-comments
32- -Wno-narrowing
33- -Wno-overflow
34- -Wno-parentheses
35- -Wno-missing-braces
36- -Wno-sign-compare
37- -Werror=address
38- -Werror=format-security
39- -Werror=return-type
4022
41- # General optimization options
42- -march=${GMMLIB_MARCH}
43- -finline-functions
44- -fno-short-enums
45- -Wa,--noexecstack
46- -fno-strict-aliasing
47- # Common defines
48- -DUSE_NEON
49- # Other common flags
50- -fstack-protector
51- -fdata-sections
52- -ffunction-sections
53- -fmessage-length =0
54- -fvisibility=hidden
55- -fPIC
56- -g
57- )
58- else ()
59- SET (GMMLIB_COMPILER_FLAGS_COMMON
60- #general warnings
61- -Wall
23+ SET (GMMLIB_COMPILER_FLAGS_COMMON
6224 -Winit-self
6325 -Winvalid-pch
6426 -Wpointer-arith
@@ -70,32 +32,16 @@ else()
7032 -Wno-parentheses
7133 -Wno-missing-braces
7234 -Wno-sign-compare
73- -Wno-enum-compare
7435 -Werror=address
7536 -Werror=format-security
7637 -Werror=return-type
7738
7839 # General optimization options
7940 -march=${GMMLIB_MARCH}
80- -mpopcnt
81- -msse
82- -msse2
83- -msse3
84- -mssse3
85- -msse4
86- -msse4.1
87- -msse4.2
88- -mfpmath=sse
8941 -finline-functions
9042 -fno-short-enums
9143 -Wa,--noexecstack
9244 -fno-strict-aliasing
93- # Common defines
94- -DUSE_MMX
95- -DUSE_SSE
96- -DUSE_SSE2
97- -DUSE_SSE3
98- -DUSE_SSSE3
9945 # Other common flags
10046 -fstack-protector
10147 -fdata-sections
@@ -104,9 +50,31 @@ else()
10450 -fvisibility=hidden
10551 -fPIC
10652 -g
107- # -m32 or -m64
108- -m${GMMLIB_ARCH}
109- )
53+ )
54+
55+ if (${CMAKE_SYSTEM_PROCESSOR} MATCHES "^aarch" )
56+ list (APPEND GMMLIB_COMPILER_FLAGS_COMMON "-DUSE_NEON" )
57+ else ()
58+ list (APPEND GMMLIB_COMPILER_FLAGS_COMMON
59+ -Wall
60+ -Wno-enum-compare
61+ -mpopcnt
62+ -msse
63+ -msse2
64+ -msse3
65+ -mssse3
66+ -msse4
67+ -msse4.1
68+ -msse4.2
69+ -mfpmath=sse
70+ -DUSE_MMX
71+ -DUSE_SSE
72+ -DUSE_SSE2
73+ -DUSE_SSE3
74+ -DUSE_SSSE3
75+ # -m32 or -m64
76+ -m${GMMLIB_ARCH}
77+ )
11078endif ()
11179
11280if ("${CMAKE_CXX_COMPILER_ID} " STREQUAL "GNU" )
You can’t perform that action at this time.
0 commit comments