0
Wondering if you have to use the -llib option in clang. For instance:
clang -lasdf foo.c -o foo.o
will link library /usr/local/lib/libasdf.dylib
to foo.c
, but wondering if there is any way to not have to include it, so it works like other system libraries, where you can just do #include <math.h>
and don't have to link anything.
Or perhaps that's what they're talking about here:
The libSystem library also includes functions that you would normally expect to find in libc and libm, RPC services, and a name resolver. Because libSystem is automatically linked into your application, you do not need to explicitly add it to the compiler’s link line. For your convenience, many of these libraries exist as symbolic links to libSystem, so while explicitly linking against -lm (for example) is not needed, it will not cause an error