Frama-C-discuss mailing list archives

This page gathers the archives of the old Frama-C-discuss archives, that was hosted by Inria's gforge before its demise at the end of 2020. To search for mails newer than September 2020, please visit the page of the new mailing list on Renater.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Frama-c-discuss] Caller-callee relationship from source file



Hi,

--- On Tue, Jan 17, 2012 at 1:49 PM, Pascal Cuoq <pascal.cuoq at gmail.com> wrote:
| Please report the version number as shown with "frama-c -version".
\--

=== Output of "frama-c -version" ===

Version: Carbon-20110201
Compilation date: Thu Jul 14 18:45:04 UTC 2011
Share path: /usr/share/frama-c (may be overridden with FRAMAC_SHARE variable)
Library path: /usr/lib64/frama-c (may be overridden with FRAMAC_LIB variable)
Plug-in paths: /usr/lib64/frama-c/plugins (may be overridden with
FRAMAC_PLUGIN variable)

=== END ===

I was able to use -cg to generate the .dot file for a simple hello.c
file. Is there any way to tell frama-c or gcc to ignore any header
file inclusion in the sources when doing static analysis?

I am only interested in the call graph, and if I move the source files
to a different directory or build environment where the headers don't
exist, I get an error like:

=== Error ===

cg] beginning analysis
[kernel] preprocessing with "gcc -C -E -I.  omega.c"
omega.c:34:20: fatal error: config.h: No such file or directory
compilation terminated.
[kernel] user error: failed to run: gcc -C -E -I.  -o
'/tmp/omega.ce9509e.i' 'omega.c'
                     you may set the CPP environment variable to
select the proper preprocessor command or use the option
"-cpp-command".
[kernel] user error: skipping file "omega.c" that has errors.
[kernel] Frama-C aborted because of invalid user input.

=== END ===

I tried using gcc -x option with 'cpp-output':

  $ gcc -x cpp-output file.c

But, I get the "error: stray '#' in program" errors.

Thanks for your replies.

SK

-- 
Shakthi Kannan
http://www.shakthimaan.com