develooper Front page | perl.perl5.porters | Postings from May 2018

Re: [perl #133152] Cygwin build failure with v5.27.11-16-g71e845c342

Thread Previous | Thread Next
From:
Karl Williamson
Date:
May 1, 2018 18:18
Subject:
Re: [perl #133152] Cygwin build failure with v5.27.11-16-g71e845c342
Message ID:
bd0a26dc-681e-9167-27c6-f979b2aa5163@khwilliamson.com
On 04/30/2018 12:29 PM, Achim Gratz wrote:
> Dave Mitchell writes:
>> On Tue, Apr 24, 2018 at 05:18:24PM -0700, Tony Cook (via RT) wrote:
>>> $ make locale.o
>>> gcc -c -DPERL_CORE -DPERL_USE_SAFE_PUTENV -U__STRICT_ANSI__ -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -D_FORTIFY_SOURCE=2 -std=c89 -O3 -Wall -Werror=declaration-after-statement -Werror=pointer-arith -Wextra -Wc++-compat -Wwrite-strings locale.c
>>> In file included from /usr/include/ssp/stdlib.h:4:0,
>>>                   from /usr/include/stdlib.h:338,
>>>                   from perl.h:819,
>>>                   from locale.c:49:
>>> /usr/include/ssp/wchar.h:78:1: error: conflicting types for ‘fgetws’
>>>   __ssp_decl(wchar_t *, fgetws, (wchar_t *__restrict __buf, int __wlen, FILE *__restrict __fp))
>>>   ^
>>> In file included from locale.c:54:0:
>>> /usr/include/wchar.h:228:10: note: previous declaration of ‘fgetws’ was here
>>>   wchar_t *fgetws (wchar_t *__restrict, int, __FILE *__restrict);
>>>            ^~~~~~
>>
>> Do you know any of:
>>
>>   * what the ssp/ include files are for,
> 
> That's an implementation detail of how the fortified versions of those
> functions are provided.  AFAIK, ssp == stack smashing protection.
> 
>>   * why they have alternate definitions of fgetws etc,
> 
> That's what you get when fortification is requested.
> 
>>   * why perl redefining a bunch of stdio macros cause both versions to be
>>     included?
> 
> You'd have to ask someone who knows the details of how the feature test
> macros work, probably Yaakov Selkowitz.  And no, I don't think you
> should redefine any macros that are already existing.

So a potential fix for this is to not fortify the source for this platform?

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About