Gcc-wl,-m=helloworld.map,--cref

Source: Internet
Author: User

-wl,option Pass option options to the connector. If option contains a comma, it is split into multiple options at the comma.

-M tells the preprocessor to output a rule that is appropriate for make to describe the dependencies of each target file. For each source file, the preprocessor outputs a make rule where the target entry (target) is the target file name for the source file, and the dependency (dependency) is any file #include referenced in the source file. The generated rule can be a single row, but if it is too long, it will be Fu Yi into multiple lines with ' \ ' line wrapping. The rules are displayed in standard output and do not produce pre-processed C programs. '-M ' implies the '-e ' option.

--cref Cross Reference, export the crosstab table (reference).

-E only runs C preprocessor. Preprocess all specified C source files, and the result is sent to the standard output or to the specified output file.

Test

Use the simplest HELLOWORLD.C

#include <stdio.h>int  main () {  printf ("hello world!\n") ;   return 0 ;}

Compile

GCC helloworld.c-wl,-m=helloworld.map,--cref-o HelloWorld

View Helleworld.map File

Reference:

GCC Chinese Handbook

Gcc-wl,-m=helloworld.map,--cref

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.