--disable-newlib-atexit-alloc

Jeff Johnston jjohnstn@redhat.com
Fri May 10 20:14:00 GMT 2013


Thanks Freddie.  Patch checked in.

-- Jeff J.

On 05/09/2013 02:38 AM, Freddie Chopin wrote:
> W dniu 2013-05-04 15:30, Freddie Chopin pisze:
>> Hi!
>>
>> The wording in the configure script's usage section:
>>
>>>   --disable-newlib-atexit-alloc    disable dynamic allocation of
>>> atexit entries
>>
>> suggests that if this option is NOT given then atexit has dynamic
>> allocation. And indeed - when this option is NOT given newlib.h has:
>>
>>> /* True if atexit() may dynamically allocate space for cleanup
>>>    functions.  */
>>> #define _ATEXIT_DYNAMIC_ALLOC 1
>>
>> But, if this option IS given, then newlib.h still has exactly the same
>> entry, so malloc() and free() are NOT disabled.
>>
>> By examining the configure script's fragment
>>
>>> # Check whether --enable-newlib-atexit-dynamic-alloc was given.
>>> if test "${enable_newlib_atexit_dynamic_alloc+set}" = set; then :
>>>   enableval=$enable_newlib_atexit_dynamic_alloc; if test
>>> "${newlib_atexit_dynamic_alloc+set}" != set; then
>>>   case "${enableval}" in
>>>     yes) newlib_atexit_dynamic_alloc=yes ;;
>>>     no)  newlib_atexit_dynamic_alloc=no  ;;
>>>     *)   as_fn_error $? "bad value ${enableval} for
>>> newlib-atexit-dynamic-alloc option" "$LINENO" 5 ;;
>>>   esac
>>>  fi
>>> else
>>>   newlib_atexit_dynamic_alloc=${newlib_atexit_dynamic_alloc}
>>> fi
>>
>> it seems that the wording in the info section is wrong, and the option
>> should be "--disable-newlib-atexit-dynamic-alloc" (with "-dynamic"),
>> right?
>>
>> If that's the case, then patch is attached.
>>
>> Regards,
>> FCh
>
> Any comments? (; I attach the patch again
>
> 4\/3!!



More information about the Newlib mailing list