I have written some Cil analyses to run on merged files for a colleague. In one case his top-level makefile specified pathnames to C sources. For example,

C=\
    subdir/foo.c\
    subdir/bar.c\
    <etc>

The cil merger finds those easily and adds the pathnames for the resulting subdir/foo.o and subdir/bar.o files to ___extra_files in the main directory.

In another case the subdirectories produced libraries. In that case the .a files were cil merged files that could be merged into the final combined file, and the pathnames to those .a files showed up in ___extra_files.

I used the following definitions in the makefile:


CC  = cilly --merge --keepmerged
LD  = cilly --merge --keepmerged
AR  = cilly --mode=AR --merge --keepmerged

export CC
export LD
export AR

If you want to run multiple analyses on the merged code and it is large, it's worthwhile to use saveBinaryFile and loadBinaryFile to avoid reparsing the merged sources.

Jesse Draper
On 07/11/2012 07:29 PM, Eric Monzon wrote:
I'm trying to use cil to merge a fair sized project, and while most of the source files are in a single directory, many of the drivers and support files are located elsewhere. While I could move all the files into one gigantic mire of hate, I'd much rather figure out how to tell cil where to look. I've read the documentation about arguments, but it hasn't been very helpful. The one that seemed like it would do what I want, --includedirs, seems to have more to do with updating cil than including directories. Does anyone know how to accomplish this sort of thing?


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/


_______________________________________________
CIL-users mailing list
CIL-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cil-users


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
CIL-users mailing list
CIL-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cil-users

Reply via email to