This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Re: Why doesn't objdump display assembly code mixed with source code?


I change the linker script to:
---------------------------------
OUTPUT_ARCH(mips) 
ENTRY(main)

SECTIONS
{
	
	.text 0x80051000 : 	
	{
	 *(.text)
	 *(.rodata*)
	}
 	 
	.data :
	{
	 *(.data)
	 *(.sdata)	 
	}

	.sbss : 
  	{ 	
  	 *(.sbss) 
 	 *(.scommon)
 	}
 	
 	.bss :
 	{
 	 *(.bss)
  	 *(COMMON)
	}
	
	.pdr :
	{
		*(.pdr)
	}
	
	.mdebug.abi32 :
	{
		*(.mdebug.abi32)
	}
	
	.debug_info :
	{
		*(.debug_info)
	}
	
	.debug_line :
	{
		*(.debug_line)
	}
	
	.debug_frame :
	{
		*(.debug_frame)
	}
	
	.debug_pubnames :
	{
		*(.debug_pubnames)
	}
	
	.debug_aranges :
	{
		*(.debug_aranges)
	}
} 


There is still not source code in the dumpped list file.
BTW, mips-elf-gdb can see debug information in the same "a.out".


>How could it?  Your link script discards the debug sections, which are
>necessary to get source line information.
>
>Brian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]