mirror of https://github.com/ArduPilot/ardupilot
waf: wrap newlib alloc functions on ChibiOS
this prevents scripting and string library functions from calling sbrk based alloction functions that are not thread safe
This commit is contained in:
parent
58d66d7a1e
commit
e922d6225f
|
@ -699,6 +699,7 @@ def build(bld):
|
|||
'fopen', 'fflush', 'fwrite', 'fread', 'fputs', 'fgets',
|
||||
'clearerr', 'fseek', 'ferror', 'fclose', 'tmpfile', 'getc', 'ungetc', 'feof',
|
||||
'ftell', 'freopen', 'remove', 'vfprintf', 'fscanf',
|
||||
'_gettimeofday', '_times', '_times_r', '_gettimeofday_r', 'time', 'clock' ]
|
||||
'_gettimeofday', '_times', '_times_r', '_gettimeofday_r', 'time', 'clock',
|
||||
'_sbrk_r', '_malloc_r', '_calloc_r', '_free_r']
|
||||
for w in wraplist:
|
||||
bld.env.LINKFLAGS += ['-Wl,--wrap,%s' % w]
|
||||
|
|
Loading…
Reference in New Issue