ar: POSIX way of creating static library containing similarly named objects
Cary Coutant
ccoutant@google.com
Fri Apr 19 21:20:00 GMT 2013
More information about the Binutils mailing list
Fri Apr 19 21:20:00 GMT 2013
- Previous message (by thread): ar: POSIX way of creating static library containing similarly named objects
- Next message (by thread): ar: POSIX way of creating static library containing similarly named objects
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
>> Can `ar' be used to create a static library comprised of the objects >> above without either of which replacing any symbols? In other words, both >> namespace_foo/state.o and namespace_bar/state.o are put into the same >> library but no symbols are replaced. > > Use the 'q' option rather than the 'r' option when adding the object files > to the library - and create the symbol index after adding the objects, > rather than at the same time. Ie: If you don't need the archive to be self-contained, you can also use a thin archive: $ ar crT libstate.a src/namespace*/state.o $ ar t libstate.a src/namespace_bar/state.o src/namespace_foo/state.o Here, libstate.a contains just the symbol table, with references to the object files in their separate directories. -cary
- Previous message (by thread): ar: POSIX way of creating static library containing similarly named objects
- Next message (by thread): ar: POSIX way of creating static library containing similarly named objects
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list