[Mingw-w64-public] [PATCH 2/2] headers: add netcfgn.idl

2020-05-07 Thread Biswapriyo Nath
... From 74461602a56ba0e7fa8247792a0efb3245f6c43b Mon Sep 17 00:00:00 2001 From: Biswapriyo Nath Date: Fri, 8 May 2020 09:40:27 +0530 Subject: [PATCH 2/2] headers: add netcfgn.idl Signed-off-by: Biswapriyo Nath --- mingw-w64-headers/Makefile.am | 1 + mingw-w64-headers/include/netcfgn

[Mingw-w64-public] [PATCH 1/2] headers: add netcfgx.idl

2020-05-07 Thread Biswapriyo Nath
... From c04cabd4b705ee12028b5988a83c928256a9c427 Mon Sep 17 00:00:00 2001 From: Biswapriyo Nath Date: Fri, 8 May 2020 09:40:27 +0530 Subject: [PATCH 1/2] headers: add netcfgx.idl Signed-off-by: Biswapriyo Nath --- mingw-w64-headers/Makefile.am | 1 + mingw-w64-headers/include/netcfgx

[Mingw-w64-public] [PATCH] crt: Build crt sources with -D__USE_MINGW_ANSI_STDIO=0

2020-05-07 Thread Martin Storsjö
This fixes lots of warnings like these: stdio/snprintf.c:9:13: warning: no previous prototype for function '__ms_snprintf' [-Wmissing-prototypes] stdio/vwscanf.c:15:10: warning: implicit declaration of function '__ms_vfwscanf' is invalid in C99 [-Wimplicit-function-declaration] Signed-off-by: M

[Mingw-w64-public] [PATCH 1/4] winstorecompat: Use __asm__() instead of asm() for setting symbol names

2020-05-07 Thread Martin Storsjö
The previous form caused compiler warnings like "warning: extension used [-Wlanguage-extension-token]" when built with clang. Signed-off-by: Martin Storsjö --- .../winstorecompat/src/CreateEventW.c| 4 ++-- .../winstorecompat/src/CreateFileW.c | 4 ++-- .../winstorecomp

[Mingw-w64-public] [PATCH 3/4] winstorecompat: Fix the return type of the non-i386 version of __imp__beginthreadex

2020-05-07 Thread Martin Storsjö
Signed-off-by: Martin Storsjö --- mingw-w64-libraries/winstorecompat/src/beginthread.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mingw-w64-libraries/winstorecompat/src/beginthread.c b/mingw-w64-libraries/winstorecompat/src/beginthread.c index e0e286bb1..f96d1f7ef 100644

[Mingw-w64-public] [PATCH 4/4] winstorecompat: Add missing WINAPI in the GetUserName function pointer declaration

2020-05-07 Thread Martin Storsjö
Signed-off-by: Martin Storsjö --- mingw-w64-libraries/winstorecompat/src/GetUserName.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mingw-w64-libraries/winstorecompat/src/GetUserName.c b/mingw-w64-libraries/winstorecompat/src/GetUserName.c index 0ecdc0ab1..4e64bc3e

[Mingw-w64-public] [PATCH 2/4] winstorecompat: Add a cast to silence a warning about conversion between void pointer and function pointer

2020-05-07 Thread Martin Storsjö
Signed-off-by: Martin Storsjö --- .../winstorecompat/src/SetUnhandledExceptionFilter.c| 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mingw-w64-libraries/winstorecompat/src/SetUnhandledExceptionFilter.c b/mingw-w64-libraries/winstorecompat/src/SetUnhandledExcepti

Re: [Mingw-w64-public] [PATCH v3 05/10] winstorecompat: provide GetUserName

2020-05-07 Thread Martin Storsjö
On Thu, 7 May 2020, Steve Lhomme wrote: On 2020-05-06 15:27, Martin Storsjö wrote: On Wed, 6 May 2020, Jacek Caban wrote: On 06.05.2020 15:09, Martin Storsjö wrote: Or call directly GetEnvironment directly? If it works on all relevant Windows versions, that sounds good. MSDN says it's s

Re: [Mingw-w64-public] [PATCH v2] winstorecompat: handle LoadLibraryA alongside LoadLibraryW

2020-05-07 Thread Martin Storsjö
On Thu, 7 May 2020, Steve Lhomme wrote: --- mingw-w64-headers/include/winbase.h| 3 +-- .../winstorecompat/src/LoadLibraryW.c | 18 -- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/mingw-w64-headers/include/winbase.h b/mingw-w64-headers/incl

[Mingw-w64-public] [PATCH] crt: Don't make sections executable when not necessary

2020-05-07 Thread Martin Storsjö
With this in place, a VirtualProtect implementation in winstorecompat that just straight redirects to VirtualProtectFromApp will work fine even on UWP without any codeGeneration capability, as long as there's no runtime pseudo relocs in code sections. And code compiled by LLVM (and as far as I've s

Re: [Mingw-w64-public] [PATCH v3 08/10] winstorecompat: allow building with code that needs codeGeneration capability

2020-05-07 Thread Martin Storsjö
On Thu, 7 May 2020, Steve Lhomme wrote: Would there be any harm in removing the whole configure option? If I read MSDN correctly, only certain flags to VirtualProtectFromApp are disallowed (and some flags requires codeGeneration while others are totally fine) - so it should be fine to keep the

[Mingw-w64-public] [PATCH] crt: Remove the unused mingw-fseek.c

2020-05-07 Thread Martin Storsjö
The functions in this file, __mingw_fseek/__mingw_fseeko64/__mingw_fwrite haven't ever been used within mingw-w64 throughout the SCM history, but were originally intended to work around issues with seeking past the end of files on Win9x. Signed-off-by: Martin Storsjö --- mingw-w64-crt/Makefile.a

[Mingw-w64-public] [PATCH] crt/libsrc: include devguid.h in devguid.c and remove all defines

2020-05-07 Thread Biswapriyo Nath
Main goal is to update the devguid.c in libsrc folder for libuuid.a. There are two options I guess: 1. Copy the new GUIDs from devguid.h to devguid.c. 2. Include devguid.h in devguid.c. Option 2 is done in the attached patch file. Because if a new GUID is added to the library in Windows SDK then

Re: [Mingw-w64-public] [PATCH 2/3] d2d1_1.h: Add C declaration for ID2D1Factory1

2020-05-07 Thread Ruslan Garipov
On 5/7/2020 5:46 PM, Biswapriyo Nath wrote: > I was thinking of adding a IDL file so that managing/editing the interface > declaration would be simple. Don't do that if d2d1_1.h will end up with overloaded member functions in a parent and child structs for C code, as dwrite.h and IDWriteTextLayout

Re: [Mingw-w64-public] [PATCH] headers/devguid.h: add missing guids and winapi family

2020-05-07 Thread Liu Hao
在 2020/5/7 3:37, Biswapriyo Nath 写道: > ... > > > Thanks. Pushed this one. -- Best regards, LH_Mouse signature.asc Description: OpenPGP digital signature ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourc

Re: [Mingw-w64-public] [PATCH] headers: Fix include order of fvec.h/ivec.h/dvec.h referring to each other

2020-05-07 Thread Liu Hao
在 2020/5/7 3:02, Martin Storsjö 写道: > Previously, these headers expanded properly if dvec.h was included > first, but not if fvec.h or ivec. were included first. > > Move the cyclical includes last, so that the bits that these headers > are expected to declare are declared before the next level he

Re: [Mingw-w64-public] [PATCH v3 08/10] winstorecompat: allow building with code that needs codeGeneration capability

2020-05-07 Thread Steve Lhomme
On 2020-05-06 15:20, Martin Storsjö wrote: On Mon, 27 Apr 2020, Steve Lhomme wrote: By default winstorecompat is built without the need for this capability. VirtualProtect may be mapped to VirtualProtectFromApp but only if the app has the codeGeneration capability. It is needed when compilin

Re: [Mingw-w64-public] [PATCH 1/3] dwrite.h: Add missed parenthesis

2020-05-07 Thread Liu Hao
在 2020/5/7 19:03, Ruslan Garipov 写道: > This commit partially fixes compilation of a C code module which > #include's dwrite.h.  One still can't compile such modules successfully > because some classes in dwrite.h declare overloaded member functions. > > No functional changes intended. > > Signed-

[Mingw-w64-public] [PATCH v2] winstorecompat: handle LoadLibraryA alongside LoadLibraryW

2020-05-07 Thread Steve Lhomme
--- mingw-w64-headers/include/winbase.h| 3 +-- .../winstorecompat/src/LoadLibraryW.c | 18 -- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/mingw-w64-headers/include/winbase.h b/mingw-w64-headers/include/winbase.h index 1bc85317..8dd03dee 1

Re: [Mingw-w64-public] [PATCH v3 07/10] headers: allow some forbidden functions winstore calls with WINSTORECOMPAT

2020-05-07 Thread Steve Lhomme
On 2020-05-06 15:12, Martin Storsjö wrote: On Mon, 27 Apr 2020, Steve Lhomme wrote: The stubs don't do anything but they are used by the crt. --- mingw-w64-headers/include/winnt.h | 30 +- 1 file changed, 21 insertions(+), 9 deletions(-) I think these aren't used un

Re: [Mingw-w64-public] [PATCH v3 05/10] winstorecompat: provide GetUserName

2020-05-07 Thread Steve Lhomme
On 2020-05-06 15:27, Martin Storsjö wrote: On Wed, 6 May 2020, Jacek Caban wrote: On 06.05.2020 15:09, Martin Storsjö wrote: Or call directly GetEnvironment directly? If it works on all relevant Windows versions, that sounds good. MSDN says it's supported since XP so I suppose so, but I c

Re: [Mingw-w64-public] [PATCH 2/3] d2d1_1.h: Add C declaration for ID2D1Factory1

2020-05-07 Thread Nikolay Sivov
Going with idl will make it dependent on widl, for both C and C++. I don't know if it's a problem, those idl's should not be a part of mingw installation anyway. ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.so

Re: [Mingw-w64-public] [PATCH v3 03/10] crt: use UWP allowed API's in __mingw_fwrite

2020-05-07 Thread Steve Lhomme
On 2020-05-06 14:52, Martin Storsjö wrote: On Mon, 27 Apr 2020, Steve Lhomme wrote: GetFileSize is not allowed. Switching to GetFileSizeEx and SetFilePointerEx makes the types and comparison cleaner. Both API's are available in XP as the one they replace. --- mingw-w64-crt/misc/mingw-fseek.c

Re: [Mingw-w64-public] [PATCH v3 02/10] crt: use UWP allowed API's in ftruncate64

2020-05-07 Thread Steve Lhomme
Hi, On 2020-05-06 14:32, Martin Storsjö wrote: On Mon, 27 Apr 2020, Steve Lhomme wrote: GetFileInformationByHandle, FindFirstVolumeW, FindNextVolumeW, FindVolumeClose are not allowed. GetFinalPathNameByHandleW is allowed in win8 and win10 https://docs.microsoft.com/en-us/uwp/win32-and-com/wi

Re: [Mingw-w64-public] [PATCH 2/3] d2d1_1.h: Add C declaration for ID2D1Factory1

2020-05-07 Thread Biswapriyo Nath
I was thinking of adding a IDL file so that managing/editing the interface declaration would be simple. ___ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

[Mingw-w64-public] [PATCH 3/3] .gitignore: Add Vim swap files

2020-05-07 Thread Ruslan Garipov
Signed-off-by: ‡Ruslan Garipov --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index d89921897a..f13c3ba471 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ autom4te.cache +*.sw? ___ Mingw-w64-public

Re: [Mingw-w64-public] [PATCH 2/3] d2d1_1.h: Add C declaration for ID2D1Factory1

2020-05-07 Thread Ruslan Garipov
On 5/7/2020 4:04 PM, Ruslan Garipov wrote: Signed-off-by: ‡Ruslan Garipov ---  mingw-w64-headers/include/d2d1_1.h | 52 +-  1 file changed, 51 insertions(+), 1 deletion(-) There are still plenty of other declarations of incomplete types in d2d1_1.h. I just start

[Mingw-w64-public] [PATCH 2/3] d2d1_1.h: Add C declaration for ID2D1Factory1

2020-05-07 Thread Ruslan Garipov
Signed-off-by: ‡Ruslan Garipov --- mingw-w64-headers/include/d2d1_1.h | 52 +- 1 file changed, 51 insertions(+), 1 deletion(-) diff --git a/mingw-w64-headers/include/d2d1_1.h b/mingw-w64-headers/include/d2d1_1.h index de2cb091b6..5c97245dcf 100644 --- a/mingw-w64-h

[Mingw-w64-public] [PATCH 1/3] dwrite.h: Add missed parenthesis

2020-05-07 Thread Ruslan Garipov
This commit partially fixes compilation of a C code module which #include's dwrite.h. One still can't compile such modules successfully because some classes in dwrite.h declare overloaded member functions. No functional changes intended. Signed-off-by: ‡Ruslan Garipov --- mingw-w64-headers/in

Re: [Mingw-w64-public] [PATCH 8/9] winstorecompat: allow building with code that needs codeGeneration capability

2020-05-07 Thread Martin Storsjö
On Wed, 6 May 2020, Jacek Caban wrote: On 06.05.2020 15:17, Martin Storsjö wrote: That lld patch is approved now FWIW, but I realized I want to refine it a bit further. I also came to think about another trick I implemented in lld - for the cases where the address is in a .refptr$ stub, ll