bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] stat: implement GetFileInformationByHandle with Winstore app


From: Steve Lhomme
Subject: Re: [PATCH] stat: implement GetFileInformationByHandle with Winstore apps restrictions
Date: Sat, 30 May 2020 16:51:25 +0200 (CEST)

> On May 30, 2020 4:35 PM Bruno Haible <bruno@clisp.org> wrote:
> 
>  
> Steve Lhomme wrote:
> > > So, it makes sense to put your code into a separate library, that 
> > > implements
> > > Windows API on top of UWP API. Gnulib focuses (partially) on providing the
> > > POSIX and glibc API on top of the Windows API.
> > 
> > That's the case in mingw-w64 which has winstorecompat to mimick some of the 
> > forbidden APIs without having to recompile the code:
> > https://github.com/mirror/mingw-w64/tree/master/mingw-w64-libraries/winstorecompat
> 
> Thanks for confirming that such a library already exists!
> 
> > You can see one of the last commit is adding GetFileInformationByHandle() 
> > for example. But that means anyone building with an older version of 
> > winstorecompat cannot rely on this helper.
> 
> That's not a good enough reason for adding this code to gnulib.

I agree. But there should be a way to compile gnulib without calling the 
forbidden/old/deprecated API's. That's currently not possible. For example in 
stat-w32.c the "_GL_WINDOWS_STAT_INODES == 2" mode is not enabled yet. And even 
then it would still do a call GetFileInformationByHandle() which will not link 
in the end. (in mingw-w64 it will because they don't builds libs for 
UWP/not-UWP)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]