[LLVMdev] Problem with stock llvmc configuration for C
Scott Michel
scottm at rushg.aero.org
Thu Aug 17 08:55:15 PDT 2006
Bram Adams wrote:
> Hi,
>
> Op 14-aug-06, om 09:29 heeft Reid Spencer het volgende geschreven:
>
>>
>>> Apparently, %llvmgccdir% and %llvmcc1% are not recognized as a useful
>>> variable by the llvmc configuration parser.
>>
>>
>> Actually, they are. See tools/llvmc/ConfigurationDriver.cpp around line
>> 304. Also, they are recognized by the lexer. Its more likely that when
>> you configured LLVM you didn't provide the --with-llvmgccdir= option.
>
>
> They're indeed mentioned, but somehow they were not added to the
> switch-statements in the corresponding parsing functions for the
> various configuration options. I attached a patch in which this is
> resolved, as well as two other bugs:
> * an off-by-one error in a loop copying a command's arguments into an
> array (first argument was dismissed; garbage added at the end);
> * %...%'s in a command name were not substituted, whereas they were in
> the command's arguments.
>
> The patch solved things for me, but it's not perfect yet.
Damn. And I was testing my version of the same patch... So for, IWFM
with one small problem: with the gcc 4.0 frontend, "-emit-llvm" needs to
be added to all of the translator.command lines. Not entirely sure how
to conditionalize that in the configuration files.
-scooter
More information about the llvm-dev
mailing list