[bitc-dev] Archive library formats
Jonathan S. Shapiro
shap at eros-os.com
Thu Jul 10 14:32:39 CDT 2008
I need some help.
I thought I had the BitC library problem under control: produce
the .bito and some .o files, pack those into libbitc.a, and then
"extract" them in two places:
1. Have the bitc static linker extract and process the .bito files.
2. Leave the .o files in there to be used directly by the system
linker, which will ignore the .bito files.
So I go to look for the file format specification for UNIX archive
libraries, and I find that there are quite a number of variations. Most
systems use either GNU or BSD format, but there are also AIX(big),
AIX(small), and Coherent formats. I'm sure that there are still other
formats used on windows.
If I use the mixed archive library trick, BitC doesn't need to be able
to construct them. That will be done by the ar command. BitC merely
needs to be able to read them.
My concern here is that I don't want to maintain archive library readers
for billions of formats -- especially when I am unable to test the
readers on platforms that I do not have.
Can somebody say how many linker archive library formats are in active
use under Windows? If a Windows archive library contains something that
is not an object file, will that file be ignored by the Windows linker?
The alternative is to simply split bitc libraries into an xxx.a and an
xxx.bita that are always installed in pairs. This would let me
standardize a .bita format that is completely independent of the native
archive library format. Because of the number of archive library formats
around, I have to say that I am definitely leaning in this direction at
More information about the bitc-dev