public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Jon Forrest <nobozo@gmail.com>
To: binutils@sourceware.org
Subject: Question About 'ar' Output
Date: Mon, 25 Apr 2022 20:46:25 -0700	[thread overview]
Message-ID: <t47pui$v1f$1@ciao.gmane.io> (raw)

(GNU ar version 2.37-10.fc35)

As a learning exercise, I'm trying to duplicate some of what
the 'ar' command does. (There's nothing wrong with 'ar').

I have a .a library that ar shows has the following content:

% ar t libctf.a
libctf_la-ctf-archive.o
libctf_la-ctf-dump.o
libctf_la-ctf-create.o
libctf_la-ctf-decl.o
libctf_la-ctf-error.o
libctf_la-ctf-hash.o
libctf_la-ctf-labels.o
[rest omitted]

When I run my test program I see
/
//
/0
/25
/47
/71
/93
[rest omitted]

When I look at my .a library using 'od' I can see the names starting
with '/' characters. I can also see the names starting with 'libctf'.

I don't understand what the slash names are, nor how they're mapped to
the real names. I tried looking at the 'ar' source code but I didn't
see anything that jumped out at me.

What am I missing?

Cordially,
Jon Forrest




             reply	other threads:[~2022-04-26  3:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-26  3:46 Jon Forrest [this message]
2022-04-26  6:15 ` Jan Beulich
2022-04-26 19:17   ` Jon Forrest
2022-04-27  5:48     ` Jan Beulich
2022-04-27  6:28     ` Alan Modra

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='t47pui$v1f$1@ciao.gmane.io' \
    --to=nobozo@gmail.com \
    --cc=binutils@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).