ranlib usage in Solaris 10 - Sparc vs i386
Hi
I have applications which use ranlib (though obseleted, but legacy software) as a part to create static libraries. Now it works fine on the SPARC Solaris 10, but when the same software is compiled in i386 Solaris 10, the static libraries are not formed. Any pointers?
Thanks in advance
Regards
[321 byte] By [
ledzepa] at [2007-11-26 18:41:09]

# 1
I created an archive on Solaris 10/x86, ran ranlib on it, and verified that the resulting .a archive was valid.
Can you explain what you tried and what didn't work?
Ranlib has been obsolete for more than 15 years. On Unix, ar always creates an indexed archive, and ranlib has no net effect (except to waste time).
# 2
Hi Clamage45
Subsequent to the posting, I dug a bit and found that ranlib was not the problem but gnumake. On the solaris10 SPARC I have gnumake.3.67 which seems to compile the object files and uses ar to create the static library fine. But on i386 Solaris 10, I have gnumake-3.80 and this does not seem to run ar implicitly when it finds that it is creating object files for an library archive. I had to explicity give the ar command for it to keep appending the object file(s) to create the archive.
My conclusion is the make rules between make-3.67 and make-3.80 have been changed and is no longer supports implicit rules for creating archive libraries.
Your input will be greatly appreciate
Thanks a ton for your ealier on
With Regards