xref: /freebsd/cddl/usr.bin/ctfconvert/ctfconvert.1 (revision fa9896e082a1046ff4fbc75fcba4d18d1f2efc19)
18be96e10SRui Paulo.\"
28be96e10SRui Paulo.\" Copyright (c) 2010 The FreeBSD Foundation
38be96e10SRui Paulo.\" All rights reserved.
48be96e10SRui Paulo.\"
58be96e10SRui Paulo.\" This software was developed by Rui Paulo under sponsorship from the
68be96e10SRui Paulo.\" FreeBSD Foundation.
78be96e10SRui Paulo.\"
88be96e10SRui Paulo.\" Redistribution and use in source and binary forms, with or without
98be96e10SRui Paulo.\" modification, are permitted provided that the following conditions
108be96e10SRui Paulo.\" are met:
118be96e10SRui Paulo.\" 1. Redistributions of source code must retain the above copyright
128be96e10SRui Paulo.\"    notice, this list of conditions and the following disclaimer.
138be96e10SRui Paulo.\" 2. Redistributions in binary form must reproduce the above copyright
148be96e10SRui Paulo.\"    notice, this list of conditions and the following disclaimer in the
158be96e10SRui Paulo.\"    documentation and/or other materials provided with the distribution.
168be96e10SRui Paulo.\"
178be96e10SRui Paulo.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
188be96e10SRui Paulo.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
198be96e10SRui Paulo.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
208be96e10SRui Paulo.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
218be96e10SRui Paulo.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
228be96e10SRui Paulo.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
238be96e10SRui Paulo.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
248be96e10SRui Paulo.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
258be96e10SRui Paulo.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
268be96e10SRui Paulo.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
278be96e10SRui Paulo.\" SUCH DAMAGE.
288be96e10SRui Paulo.\"
29*5727eceaSMark Johnston.Dd April 21, 2022
308be96e10SRui Paulo.Dt CTFCONVERT 1
318be96e10SRui Paulo.Os
328be96e10SRui Paulo.Sh NAME
338be96e10SRui Paulo.Nm ctfconvert
348be96e10SRui Paulo.Nd convert debug data to CTF data
358be96e10SRui Paulo.Sh SYNOPSIS
368be96e10SRui Paulo.Nm
378be96e10SRui Paulo.Op Fl gis
388be96e10SRui Paulo.Fl l Ar label
398be96e10SRui Paulo.Fl L Ar labelenv
408be96e10SRui Paulo.Op Fl o Ar outfile
418be96e10SRui Pauloobject_file
428be96e10SRui Paulo.Sh DESCRIPTION
438be96e10SRui PauloThe
448be96e10SRui Paulo.Nm
45*5727eceaSMark Johnstonutility converts debug information from a binary file to CTF (Compact C Type
46*5727eceaSMark JohnstonFormat) data and replaces the debug section of that file with a CTF section
47*5727eceaSMark Johnstoncalled SUNW_ctf.
488be96e10SRui PauloThis new section is added to the input file, unless the -o
498be96e10SRui Paulooption is present.
508be96e10SRui PauloYou can also opt to keep the original debugging section with the
518be96e10SRui Paulo-g option.
528be96e10SRui Paulo.Pp
538be96e10SRui PauloThe following options are available:
548be96e10SRui Paulo.Bl -tag -width indent
558be96e10SRui Paulo.It Fl l Ar label
568be96e10SRui PauloSets the label as
578be96e10SRui Paulo.Ar label .
588be96e10SRui Paulo.It Fl L Ar labelenv
598be96e10SRui PauloInstructs
608be96e10SRui Paulo.Nm
618be96e10SRui Pauloto read the label from the environment variable
628be96e10SRui Paulo.Ar labelenv .
638be96e10SRui Paulo.It Fl g
648be96e10SRui PauloDon't delete the original debugging section.
658be96e10SRui Paulo.It Fl i
668be96e10SRui PauloIgnore object files built from other languages than C.
678be96e10SRui Paulo.It Fl s
688be96e10SRui PauloUse the .dynsym ELF section instead of the .symtab ELF section.
698be96e10SRui Paulo.It Fl o Ar outfile
708be96e10SRui PauloWrite the output to file in
718be96e10SRui Paulo.Ar outfile .
728be96e10SRui Paulo.El
738be96e10SRui Paulo.Sh EXIT STATUS
748be96e10SRui Paulo.Ex -std
758be96e10SRui Paulo.Sh SEE ALSO
764990a1c0SJoel Dahl.Xr ctfdump 1 ,
77*5727eceaSMark Johnston.Xr ctfmerge 1 ,
78*5727eceaSMark Johnston.Xr ctf 5
798be96e10SRui Paulo.Sh HISTORY
808be96e10SRui PauloThe
818be96e10SRui Paulo.Nm
828be96e10SRui Pauloutility first appeared in
838be96e10SRui Paulo.Fx 7.0 .
848be96e10SRui Paulo.Sh AUTHORS
858be96e10SRui PauloThe CTF utilities came from OpenSolaris.
86