This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

gcc-arm-none-eabi: what were the Newlib compilation options?

This question has been asked before, but ignored (https://community.arm.com/support-forums/f/compilers-and-libraries-forum/52220/gnu-arm-embedded-what-were-the-newlib-compilation-options).

I would dare to ask it again:

Exactly what compilation options were used to build Newlib?

The versions of GCC tools of interest are:

  • gcc-arm-none-eabi-9-2020-q2-update
  • gcc-arm-none-eabi-10.3-2021.10

It's not just an idle interest, or an attempt to waste your valuable time. I've got a practical need to rebuild Newlib as position-independent code, if you need to know why.

Is any real developer with access to build scripts reading this?

Thank you in advance,

    Vadim Barshaw

Parents
  • Hi both,

    Sadly, those options have changed a little since the GCC 9, 10 Embedded releases... For those releases the options should have been:

    For Newlib:

    --enable-newlib-io-long-long \
    --enable-newlib-io-c99-formats \
    --enable-newlib-reent-check-verify \
    --enable-newlib-register-fini \
    --enable-newlib-retargetable-locking \
    --disable-newlib-supplied-syscalls \
    --disable-nls
    For Newlib-nano:
    --disable-newlib-supplied-syscalls \
    --enable-newlib-reent-check-verify \
    --enable-newlib-reent-small \
    --enable-newlib-retargetable-locking \
    --disable-newlib-fvwrite-in-streamio \
    --disable-newlib-fseek-optimization \
    --disable-newlib-wide-orient \
    --enable-newlib-nano-malloc \
    --disable-newlib-unbuf-stream-opt \
    --enable-lite-exit \
    --enable-newlib-global-atexit \
    --enable-newlib-nano-formatted-io \
    --disable-nls

    (as well as the usual --build, --host, --target, --prefix options)

    Hope this helps!
Reply
  • Hi both,

    Sadly, those options have changed a little since the GCC 9, 10 Embedded releases... For those releases the options should have been:

    For Newlib:

    --enable-newlib-io-long-long \
    --enable-newlib-io-c99-formats \
    --enable-newlib-reent-check-verify \
    --enable-newlib-register-fini \
    --enable-newlib-retargetable-locking \
    --disable-newlib-supplied-syscalls \
    --disable-nls
    For Newlib-nano:
    --disable-newlib-supplied-syscalls \
    --enable-newlib-reent-check-verify \
    --enable-newlib-reent-small \
    --enable-newlib-retargetable-locking \
    --disable-newlib-fvwrite-in-streamio \
    --disable-newlib-fseek-optimization \
    --disable-newlib-wide-orient \
    --enable-newlib-nano-malloc \
    --disable-newlib-unbuf-stream-opt \
    --enable-lite-exit \
    --enable-newlib-global-atexit \
    --enable-newlib-nano-formatted-io \
    --disable-nls

    (as well as the usual --build, --host, --target, --prefix options)

    Hope this helps!
Children