Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does the gcc compiler insert the version in data section? [duplicate]

Tags:

c++

gcc

gnu

When i compile a c++ application with gcc, I noticed that gcc is inserting the gnu version string inside the rdata section. How do i make gcc not to insert this?

enter image description here

like image 803
user3575889 Avatar asked Aug 09 '26 01:08

user3575889


1 Answers

You can either use objcopy to edit the object file or you can remove the ident line from the assembler file that gcc can create before you assemble it.

Not that you'd ever need to.

like image 158
user3710044 Avatar answered Aug 11 '26 18:08

user3710044