gnu --cflowを使用して1つのファイルのコールグラフを生成することはできましたが、cflowを使用して複数のファイルのコールグラフを生成する方法を見つけることができませんでした。
フォローしてみました
cflow test.c、hello.c
test.cのコールグラフを生成し、hello.cのコールグラフは作成しません。
cflow test.c hello.c
hello.cのコールグラフを生成し、test.cのコールグラフは作成しません。
複数のファイルをcflowに渡す方法がわかりません。
これについて何か考えはありますか?
こんにちはC
int
who_am_i (void)
{
struct passwd *pw;
char *user = NULL;
pw = getpwuid (geteuid ());
if (pw)
user = pw->pw_name;
else if ((user = getenv ("USER")) == NULL)
{
fprintf (stderr, "I don't know!\n");
return 1;
}
printf ("%s\n", user);
unused_function();
return 0;
}
int
main (int argc, char **argv)
{
if (argc > 1)
{
fprintf (stderr, "usage: whoami\n");
return 1;
}
return who_am_i ();
}
void unused_function()
{
printf();
error1();
printf();
}
void error1()
{
error2();
}
void error2()
{
}
test.c
int tests()
{ return 0;}