First, when building your library, create it as libmyLib.so.
Second, when building your application use -l myLib (-ell) to specify the
library, and -L /usr/lib to specify the library search paths. These only
need to be specified in LDFLAGS.
Please note, the default behaviour for the linker is to add lib…<a|so>. So
when it goes to link in the shared library, it will turn myLib into
libmyLib.so. However, when you specify -lmyLib.so it will look for
Hope this helps.
“Lungwen Han” <firstname.lastname@example.org> wrote in message
I tried to link a DLL into my application and failed. The error message "
Could not find library myLib.so". Please kindly let me know what I have
The makefile of the …/dll/nto/x86/o.so has -shared added into CCFLAGS and
the library is created as myLib.so.
The makefile of the …/application/nto/x86/o/ has -Bdynamic -l myLib.so
added into CCFLAGS and the binary is created.
The common.mk of …/application has LDFLAGS = -l /usr/lib/myLib.so added.
Thanks in advance.