Although technically not a GNU product, the C runtime library newlib is the best choice for many GNU-based embedded systems that require a modest C runtime environment. This article introduces newlib’s most important features, shows you how to use newlib in a GNU-based embedded system, and describes in detail how to port newlib to a runtime environment featuring the uC/OS realtime operating system.

With minor modifications, newlib can be used in embedded systems that are not built using GNU tools. Newlib can also be used as a glibc runtime library replacement in embedded Linux systems. The classic, “Hello, world!” test application occupies less than 30k in a newlib-based Linux runtime environment; the equivalent glibc-based application is more than 380k in size.