News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

I don't know how to generate a map file.

Started by dedt, November 29, 2013, 08:26:56 PM

Previous topic - Next topic

dedt

As you no doubt inferred from the subject title, I'm pretty inexperienced with C++ (and programming more generally). I'm trying to generate a map file but I don't know how. From the search I did through the forum, the most I could find out was that I'm supposed to add "-Wl,-Map=main.map" to build options->link settings->other link option, but that didn't seem to do anything.

oBFusCATed

(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

dedt

I was asked to generate a map file by my prof.

stahta01

Did you try this option found on http://gcc.gnu.org/onlinedocs/gcc/Link-Options.html in extra/other linker or compiler options.

-Wl,-Map,output.map


Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]

dedt

No, it didn't work unfortunately.

Then again, maybe my expectations about what's supposed to happen are naive. I'm expecting a file to pop up after I run the program. Is this assumption correct?

stahta01

Quote from: dedt on November 29, 2013, 10:13:20 PM
No, it didn't work unfortunately.

Then again, maybe my expectations about what's supposed to happen are naive. I'm expecting a file to pop up after I run the program. Is this assumption correct?

No, the file will be placed in a folder on your hard-drive.

Tim S.
C Programmer working to learn more about C++.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ. [url="http://wiki.codeblocks.org"]http://wiki.codeblocks.org[/url]