On Wed, Feb 10, 2010 at 9:47 AM, Andy Dougherty <[email protected]> wrote:
> On Wed, 10 Feb 2010, Will Coleda wrote:
>
>> On Tue, Feb 9, 2010 at 7:15 PM, Andy Dougherty <[email protected]> 
>> wrote:
>
>> > For example, there's no easy way to say something like
>> >
>> >    For compiling src/gc/system.c on amd64 on certain flavors of Linux
>> >    with gcc 4.3.x, optimizations -O[012] are fine, but -O3 and higher
>> >    won't work.
>> >
>
>> Whoops. We're overengineering some of this.
>
> I don't think so.  That example is very real and almost precisely the
> current state of affairs.  There are many other examples in the perl 5
> tree.
>
>> If we want to change a warnings flag, we just need to tack it on the
>> end of the command line, the second -Wno-foo will override the default
>> -Wfoo.
>
> Yes, that works for gcc.  I don't know about other compilers, but since we
> don't really support warnings on other compilers anyway, that's good
> enough for now.
>
>> We can use the existing makefile generation step to conditionally add
>> the -Wno-foo, using the #IF and #UNLESS directives already present.
>
> Yes, but they are too blunt a tool for the task above.  They are all we
> have, so that's what we do now, but they are still inadequate.  They don't
> fail, but they are suboptimal.  That's all I'm saying.
>
> Your plan preserves the status quo, which is ok, but if you can think of a
> way to generalize it, I think it would be beneficial.  That's all I was
> trying to say.
>
> --
>    Andy Dougherty              [email protected]

What about this for a more clever @@ replacement syntax? then we can
setup something complicated per-file but have a sane default.

--

Takes the specified source file, replacing entries like C<@key@> with
C<key>'s value from the configuration system's data, and writes the results
to specified target file.

If a C<?> is present in the C<@key@>, the replaced value will first
try touse the full key, but if that is not present, the key up to the
C<?> is used.
For example, if C<@cc_warnings?src/embed.c@> is used, and that key doesn't
exist, the fallback key would be C<@cc_warnings@>.

-- 
Will "Coke" Coleda
_______________________________________________
http://lists.parrot.org/mailman/listinfo/parrot-dev

Reply via email to