wscript: Automatically disable SSE on platforms that don't support it (i.e. raspberry pi)

Closes: #213
This commit is contained in:
Jonathan Moore Liles 2017-05-06 21:14:18 -07:00
parent 3d18cf37b9
commit 63a624414b
1 changed files with 5 additions and 0 deletions

View File

@ -39,6 +39,11 @@ def configure(conf):
conf.env['LIB_DL'] = ['dl'] conf.env['LIB_DL'] = ['dl']
conf.env['LIB_M'] = ['m'] conf.env['LIB_M'] = ['m']
if Options.options.sse:
if os.system("grep -q '^flags.*sse' /proc/cpuinfo"):
Options.options.sse = 0
print "Processor lacks sse, disabling..."
# NTK_EXTRA_FLAGS='' # NTK_EXTRA_FLAGS=''
# if not Options.options.use_system_ntk: # if not Options.options.use_system_ntk:
# print 'Using bundled NTK' # print 'Using bundled NTK'