For example, we have three following libraries:
1.1.......................lib_A.a
1.2.......................lib_B.a
1.3.......................lib_C.a
Now I want to create one library which consists of all the above static libraries.
I have used following command:
ar -crs lib_Z.a lib_A.a lib_B.a lib_C.a
When I create final executable with lib_Z.a
, the compiler gives me the following error:
error adding symbols: archive has no index; run ranlib to add one
How to solve this issue?