After create dynamic library on Linux but I want to generate symbol link import library (.a) from dynamic library .so. What steps I do?
views:
21answers:
1
+1
A:
actually, the dynamic library in linux did not need 'import library'. 'import library' is the idea in windows: when you build a dll, vs will also give you a lib file as the 'import library', or you have to build your own 'import library' through some 'ref' files.
*.a in linux is archive file, which is just, we say, zip the object file and make it as one object, not exactly, but, in some meaning you can understand it in that way. get a *.a and invoke it is easy.
*.a:
{compiler, gcc is a simple example} -g -c *.c
ar -{some flags, depends your compiler, -c is a simple example} liba.a *.o
{linker, gcc is a simple example} -g -o a -la -L.
alexander.cer
2010-08-05 10:14:12
I see some public library generate both of files: Dynamic library and import library on Linux. I don't want to link .so file directly because it doesn't work on Mac OS
Tang Khai Phuong
2010-08-06 02:01:50