Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] wrap Buildroot compilation for static analysis
@ 2015-01-23  7:55 spam at douglasheld.net
  2015-01-23 11:56 ` Yann E. MORIN
  0 siblings, 1 reply; 2+ messages in thread
From: spam at douglasheld.net @ 2015-01-23  7:55 UTC (permalink / raw)
  To: buildroot

Hi list,

I have some commercial software called Fortify SCA that wraps a compiler
command, to build an analysis model of the code.  I would like to analyze
OpenWRT and I see that it implements Buildroot.

For each time the build system invokes a command like 'gcc <compiler
args>', I would like to capture this information and run a command
'sourceanalyzer <sca args> gcc <compiler args>'.

With makefiles, this is a pretty well solved problem; I can invoke
sourceanalyzer <sca args> make <make args>
and that makes some wrapper scripts for gcc, g++ etc. that invoke
sourceanalyzer correctly. But I am finding the Buildroot build sequence a
little incomprehensible.

For example, a shortcut I tried is:

#i.e., build the toolchain and then the product
make
# find and remove selected object files
find ./package/libnl-tiny | egrep '\.o$|\.so$' | xargs rm
# try my wrapper on limited number of files
sourceanalyzer <sca args> make

But the final command doesn't detect the missing .o files and rebuild
them.  Instead it indicates a fatal error in libnl-tiny.so not existing as
expected.

Any indication where I should be looking? I didn't imagine the OpenWRT guys
would be able to answer questions about the underlying build system.

Thanks
Doug



-- 
spam at douglasheld.net
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20150123/ae7602b8/attachment.html>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-01-23 11:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-23  7:55 [Buildroot] wrap Buildroot compilation for static analysis spam at douglasheld.net
2015-01-23 11:56 ` Yann E. MORIN

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox