Technical Support
On-Line Manuals
Compiler Reference Guide
Version 6.15
Tells the compiler to exclude the Arm® standard C and C++ library header files.
If you want to disable the use of the Arm standard library, then use both the -nostdlibinc and -nostdlib armclang options.
-nostdlibinc
-nostdlib
armclang
-nostdlibinc is disabled by default.
#include "math.h" double foo(double d) { return sqrt(d + 1.0); } int main(int argc, char *argv[]) { return foo(argc); }
Compiling this code without -nostdlibinc generates a call to __hardfp_sqrt, from the Arm standard library.
__hardfp_sqrt
armclang --target=arm-arm-none-eabi -mcpu=Cortex-A9 -O0 -S -o- file.c -mfloat-abi=hard
Compiling this code with -nostdlibinc and -nostdlib generates an error because the compiler cannot include the standard library header file math.h.
math.h
armclang --target=arm-arm-none-eabi -mcpu=Cortex-A9 -O0 -S -o- file.c -mfloat-abi=hard -nostdlibinc -nostdlib
Cookie Settings | Terms of Use | Privacy | Accessibility | Trademarks | Contact Us | Feedback
Copyright © 2005-2019 Arm Limited (or its affiliates). All rights reserved.
This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.
Change Settings
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers of your data.