> On 29 Mar 2025, at 16:12, Jakub Jelinek <ja...@redhat.com> wrote:
> 
> On Sat, Mar 29, 2025 at 04:03:07PM +0000, Iain Sandoe wrote:
>> 
>> 
>>> On 29 Mar 2025, at 15:56, Jakub Jelinek <ja...@redhat.com> wrote:
>>> 
>>> On Sat, Mar 29, 2025 at 03:50:54PM +0000, Iain Sandoe wrote:
>>>>> I'm not sure if sed -E is portable enough (sure, I know it is in POSIX, 
>>>>> but
>>>>> that is not enough).
>>>>> How about just
>>>>>   sed -e '/^#include/s,"\([^"]*.h\)","../../libgcobol/\1",' $& > $@
>>>> 
>>>> This, unfortunately, works too well (with s/&/^) .. because it also 
>>>> processes #include “config.h”
>>>> which then points to a non-existent file.  I think we want to include 
>>>> config for both FE and
>>>> library (so we cannot get around it by indenting the config.h include - 
>>>> well we could, but …)
>>> 
>>> Neither libgcobol/charmaps.cc nor libgcobol/valconv.cc has config.h include.
>> 
>> but it’s an approved patch (just waiting for the main config change to be 
>> reviewed) and needed
>> for the other lib changes.  I’ll investigate if we could find a way to drop 
>> it fro those two files.
> 
> config.h is the only header ending with g in there, so
>       sed -e '/^#include/s,"\([^"]*[^g"].h\)","../../libgcobol/\1",' $^ > $@
> then?

Not necessary (at the moment), with the recent header shuffles I no longer need 
to include config.h
in the shared sources.  So your previous edition is fine (tested only on 
x86_64-darwin, so far).

So, with current trunk + your previous (amended) patch - Darwin can now build 
the FE.
Perhaps one might forcast needing more configure tests as other platforms start 
to pick this up.

Tomorrow, I will post a summary of what’s needed to get the library building 
using libquadmath
- most of the patches are actually approved - but i need to post the changes 
for the lib files.

thanks
Iain



Reply via email to