[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Creating Archives
From: |
David Boyce |
Subject: |
Re: Creating Archives |
Date: |
Thu, 7 Apr 2011 10:09:22 -0400 |
On Thu, Apr 7, 2011 at 8:45 AM, Paul Smith <address@hidden> wrote:
> standard ar does not allow the members to be added to an archive
> to be anything other than object files.
You may not have meant to say it this way but the above isn't correct.
AFAIK you can place any kind of file into an archive. Here's a couple
of quotes from POSIX:
When an archive consists entirely
of valid object files, the implementation shall format the archive
so that it is usable as a library for link editing (see c99 and
fort77). When some of the archived files are not valid object files,
the suitability of the archive for library use is undefined. If
an archive consists entirely of printable files,
the entire archive shall be printable.
There is at least one known implementation (for a small computer)
that can accommodate only object files for that system, disallowing
mixed object and other files. The ability to handle any type of file
is not only historical practice for most implementations, but is
also a reasonable expectation.
I actually see nothing in POSIX which disallows
archives-within-archives, though some implementations reject them
anyway and in any case they wouldn't be expected to "work" in the way
the OP expects.
But as you say, this is not really a make topic.
-David Boyce