From patchwork Mon Jun 9 16:24:37 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaron Merey X-Patchwork-Id: 114058 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 405D93830687 for ; Mon, 9 Jun 2025 16:25:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 405D93830687 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=aCwRE4Wo X-Original-To: elfutils-devel@sourceware.org Delivered-To: elfutils-devel@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id A16B63830683 for ; Mon, 9 Jun 2025 16:24:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A16B63830683 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org A16B63830683 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1749486292; cv=none; b=lRfL4unLeweByrmJmxGukOX8idPPr3SCMZ+q5hhZ/piikhJ0jkSl+GheL9KJZ8quLQ22BETmWwvyBmLcpn0Ykcoi862jJq/vz4B6e9AWyB0Mwc5JRggtf3yuCwGClyHd+EOUQY2MXSE3OEKdYblj52/20Z1CcgHODhYZkfjIJUs= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1749486292; c=relaxed/simple; bh=KdsYhm4tLcYR1DlEFAJUZZmbxVZed7Qc8F+2XkY9KzU=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=ZTk1E+nlxT5vqYVi7AIZksG1yhQT3E6zzOqjgCDQlL47t3CQXXFYVrIiw/HNuQc80PbIrMusXYrBFsP2VNjGb2b7i6kDeDW2ta02rrBm6nPkg+TGM/MNpgCOthE9sazavD7aOPVP2Q2+cwh8Sy/3XwB1I2rEHdaVybQStLomMHk= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A16B63830683 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1749486292; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bCbDzn50rXkdF2WvXXH10M1feqDEOvyRKvyfcys141Q=; b=aCwRE4WogiXJzJ7gpYeBxWUYI4oQMl0pYUkRs/1JfCT+NCsJV635fIZnWkY+esMaE9ygkU M+G5YGg5oPoO2OLKuZZ9A5wXUMN7KHcrdJ8OPgoHNDV1Lad73OnJc2UD5bAKESlIPwya7W 9Nlm4cboybshvvMwQl6xXdoEgjHZ3wM= Received: from mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-642-saWxgx29OBSj6KDJ5MifSQ-1; Mon, 09 Jun 2025 12:24:51 -0400 X-MC-Unique: saWxgx29OBSj6KDJ5MifSQ-1 X-Mimecast-MFC-AGG-ID: saWxgx29OBSj6KDJ5MifSQ_1749486290 Received: from mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.40]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 6CA141808984 for ; Mon, 9 Jun 2025 16:24:50 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.22.89.91]) by mx-prod-int-04.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id A82C819560A3; Mon, 9 Jun 2025 16:24:49 +0000 (UTC) From: Aaron Merey To: elfutils-devel@sourceware.org Cc: Aaron Merey Subject: [PATCH 2/4] doc: Add elf_getaroff.3 Date: Mon, 9 Jun 2025 12:24:37 -0400 Message-ID: <20250609162439.89825-2-amerey@redhat.com> In-Reply-To: <20250609162439.89825-1-amerey@redhat.com> References: <20250609162439.89825-1-amerey@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.40 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: -WA7hcuCvRbPKdtGf-zdbMNu8u28E02QOeylauDZ4sI_1749486290 X-Mimecast-Originator: redhat.com content-type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: elfutils-devel@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Elfutils-devel mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: elfutils-devel-bounces~patchwork=sourceware.org@sourceware.org Signed-off-by: Aaron Merey --- doc/Makefile.am | 1 + doc/elf_getaroff.3 | 55 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 doc/elf_getaroff.3 diff --git a/doc/Makefile.am b/doc/Makefile.am index fbfebfe0..6451ffab 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -55,6 +55,7 @@ notrans_dist_man3_MANS= elf32_checksum.3 \ elf_errmsg.3 \ elf_errno.3 \ elf_fill.3 \ + elf_getaroff.3 \ elf_getbase.3 \ elf_getdata.3 \ elf_getscn.3 \ diff --git a/doc/elf_getaroff.3 b/doc/elf_getaroff.3 new file mode 100644 index 00000000..05072ad5 --- /dev/null +++ b/doc/elf_getaroff.3 @@ -0,0 +1,55 @@ +.TH ELF_GETAROFF 3 2025-06-06 "Libelf" "Libelf Programmer's Manual" + +.SH NAME +elf_getaroff \- retrieve the offset of an archive member + +.SH SYNOPSIS +.nf +.B #include + +.BI "int64_t elf_getaroff(Elf *" elf ");" +.fi +.SH DESCRIPTION +Return the file offset, in bytes, of the archive member currently +referred to by an ELF descriptor. + +.SH PARAMETERS +.TP +.I elf +Elf descriptor referring to a member of an archive file. + +.SH RETURN VALUE +Return the file offset, in bytes, of the archive member referred to by +.IR elf . +If +.I elf +is NULL or is not a member of an archive, +return +.BR ELF_C_NULL . + +.SH SEE ALSO +.BR elf_begin (3), +.BR elf_next (3), +.BR libelf (3), +.BR elf (5) + +.SH ATTRIBUTES +.TS +allbox; +lbx lb lb +l l l. +Interface Attribute Value +T{ +.na +.nh +.BR elf_getaroff () +T} Thread safety MT-Safe +.TE + +.SH REPORTING BUGS +Report bugs to or https://sourceware.org/bugzilla/. + +.SH HISTORY +.B elf_getaroff +first appeared in elfutils 0.114. This elfutils libelf function may not be +found in other libelf implementations.