Allow access to segment information.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4796 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
@@ -63,12 +63,13 @@ static void Usage (void)
|
||||
|
||||
int main (int argc, char** argv)
|
||||
{
|
||||
const char* Input;
|
||||
cc65_dbginfo Info;
|
||||
cc65_filelist* Files;
|
||||
cc65_lineinfo* L;
|
||||
unsigned I;
|
||||
unsigned long Addr;
|
||||
const char* Input;
|
||||
cc65_dbginfo Info;
|
||||
cc65_filelist* Files;
|
||||
cc65_segmentlist* Segments;
|
||||
cc65_lineinfo* L;
|
||||
unsigned I;
|
||||
unsigned long Addr;
|
||||
|
||||
|
||||
/* Input file is argument */
|
||||
@@ -93,6 +94,17 @@ int main (int argc, char** argv)
|
||||
}
|
||||
cc65_free_filelist (Info, Files);
|
||||
|
||||
/* Output a list of segments */
|
||||
printf ("Segments processed when linking:\n");
|
||||
Segments = cc65_get_segmentlist (Info);
|
||||
for (I = 0; I < Segments->count; ++I) {
|
||||
printf (" %-20s $%06lX-$%06lX\n",
|
||||
Segments->data[I].name,
|
||||
(unsigned long) Segments->data[I].start,
|
||||
(unsigned long) Segments->data[I].end);
|
||||
}
|
||||
cc65_free_segmentlist (Info, Segments);
|
||||
|
||||
/* Check one line */
|
||||
printf ("Requesting line info for crt0.s(59):\n");
|
||||
L = cc65_lineinfo_byname (Info, "crt0.s", 59);
|
||||
|
||||
Reference in New Issue
Block a user