Skip to content

Commit 746aa8b

Browse files
committed
wscript: fix arm build
1 parent 0ffcbff commit 746aa8b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

scripts/waifulib/compiler_optimizations.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@
6161
},
6262
'fastnative': {
6363
'msvc': ['/O2', '/Oy', '/MT'],
64-
'gcc': ['-Ofast', '-march=native', '-funsafe-math-optimizations', '-funsafe-loop-optimizations', '-fomit-frame-pointer'],
65-
'clang': ['-Ofast', '-march=native'],
64+
'gcc': ['-O2', '-march=native', '-funsafe-math-optimizations', '-funsafe-loop-optimizations', '-fomit-frame-pointer'],
65+
'clang': ['-O2', '-march=native'],
6666
'default': ['-O3']
6767
},
6868
'release': {

wscript

+3-3
Original file line numberDiff line numberDiff line change
@@ -370,13 +370,13 @@ def configure(conf):
370370
]
371371

372372
flags += ['-funwind-tables', '-fvisibility=default']
373-
elif conf.env.COMPILER_CC != 'msvc' and conf.env.DEST_OS != 'darwin':
374-
flags += ['-march=native']
373+
elif conf.env.COMPILER_CC != 'msvc' and conf.env.DEST_OS != 'darwin' and conf.env.DEST_CPU in ['x86', 'x86_64']:
374+
flags += ['-march=core2']
375375

376376
if conf.env.DEST_CPU in ['x86', 'x86_64']:
377377
flags += ['-mfpmath=sse']
378378
elif conf.env.DEST_CPU in ['arm', 'aarch64']:
379-
flags += ['-fsigned-char']
379+
flags += ['-fsigned-char', '-mfpu=neon-vfpv4']
380380

381381
if conf.env.DEST_OS == 'freebsd':
382382
linkflags += ['-lexecinfo']

0 commit comments

Comments
 (0)