C++ User's Guide

-xM

Outputs makefile dependency information.

Examples

When you compile the following code, hello.c,


#include <cstdio>
using std::printf;
int main () {
  printf ("Hello World!\n");
}

with this option:

demo% CC -xM hello.c

the output shows the dependencies:


hello.o : hello.c
hello.o : /opt/SUNWspro/SC5.0/include/CC/cstdio
hello.o : /usr/include/sys/va_list.h

See also

make(1) (for details about makefiles and dependencies)