Can't pass an option to IAR compiler

PC-lint Plus User Discussion
Post Reply
asavch

Can't pass an option to IAR compiler

Post by asavch » Tue Feb 19, 2019 12:38 pm

Hi.

I'm working with trial version of PC Lint and trying to make it work with our IAR project.
IAR compiler wants to get a parameter --dlib_config in command line, which is a path and name of special header file.
But the problem is that file compilers.yaml doesn't know that parameter (and many others too).
I've tried to modify it manually in this way:

Code: Select all

            '--dlib_config':
                transforms: [ ['--dlib_config[= ](?P<dlibtype>.+)$', '--dlib_config="\g<dlibtype>"'] ]
But this kind of regexp is taking only part of parameter value breaking with first space.
How can I modify this one regexp to take whole parameter value?
Or is there some other way to send this parameter to IAR compiler?

mmetivier

Re: Can't pass an option to IAR compiler

Post by mmetivier » Wed Feb 20, 2019 1:53 pm

PC-Lint takes the place of your compiler, so passing anything "to the compiler" isn't actually going to do anything. It might be more interesting to see what the internal effect of these flags is by using the "--predef_macros" option to have the compiler dump is internal, predefined macros when they're set. Then, they could be replicated for the PC-Lint configuration.

Post Reply