[Mingw-w64-public] Windows 8 Store patches

2013-11-16 Thread Rafaël Carré
Hello,

As you probably know we have been working on VLC for Windows Store for 
a long time already.

Here are the latest patches we have to be able to build vlc.git without 
using forbidden symbols that would fail us at the validation step, using 
Microsoft Windows App Cert Kit (WACK).

Those are in raw form, so probably not committable as is but I would like 
to have a discussion about them.

Fix declarations in headers
That one is a couple of hacks put together just to have VLC to build.

- Use WINAPI in gai_strerrorA prototype. I have absolutely no idea why I 
did that 

- Check _WIN32_WINNT define additionally to WINVER. I don't know why 
WINVER was added here in r6188. What is its role compared to _WIN32_WINNT ?

- Revert a couple of #if WINAPI_FAMILY_PARTITION (WINAPI_PARTITION_DESKTOP):
- winnls.h : no idea here.. I guess other headers depend on these 
declarations and were not commented out. I'll have to check.
- winbase.h : CreateSemaphoreW is reimplemented in libwinstorecompat, 
so we need to have the prototype available.
- combaseapi.h : same remark for CoCreateInstance
- shlobjidl.h : comment out FreeKnownFolderDefinitionFields, I guess 
that it brings a runtime dependency on CoTaskMemFree/ole32. Not sure 
I remember what was the problem here.

Of those hacks the ones of importance (because I don't remember the 
details for the other ones..) are CreateSemaphoreW / CoCreateInstance.

Do we want a special define to still have the prototypes for functions 
reimplemented in winstorecompat?
e.g. -D_WIN32_WINNT=0x602 (is it 0x603 for 8.1?) -DWINSTORECOMPAT


gai_strerrorA: reimplement without FormatMessageA
As vlc is cross platform we use the char * version of gai_strerror,
which is forbidden by Microsoft (only UNICODE APIs are allowed).
This patch makes it use the UNICODE version and convert the message to
ASCII.
I had to add WINAPI for it to build, as it's now declared as WINAPI in the 
header (see above patch).
Note that there were some comments about using mbstowcs which would pull 
another dependency.
Can we use WideCharToMultiByte here ?

Reimplement SHGetFolderPathW using WinRT functions
That one comes from Jean-Baptiste and is for libwinstorecompat.
Jean-Baptiste was there something else we need to do here?

winstorecompat: *QueueTimer replacements (deactivated for
I don't think I had sent that one, it is in the spirit of other functions 
already present in libwinstorecompat so likely not controversial.

More Windows Store forbidden APIs
Comment out a bunch of forbidden functions in the headers.


--
DreamFactory - Open Source REST  JSON Services for HTML5  Native Apps
OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
Free app hosting. Or install the open source package on any LAMP server.
Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
http://pubads.g.doubleclick.net/gampad/clk?id=63469471iu=/4140/ostg.clktrk
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] Windows 8 Store patches

2013-11-16 Thread Rafaël Carré
Le 16/11/2013 19:03, Rafaël Carré a écrit :
 Hello,
 
 As you probably know we have been working on VLC for Windows Store for 
 a long time already.
 
 Here are the latest patches we have to be able to build vlc.git without 
 using forbidden symbols that would fail us at the validation step, using 
 Microsoft Windows App Cert Kit (WACK).

I forgot to add that since we are now targetting Windows 8.1 through
VS2013, we need to add a def file for msvcr120 before we validate with
the Store Cert Kit.

--
DreamFactory - Open Source REST  JSON Services for HTML5  Native Apps
OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
Free app hosting. Or install the open source package on any LAMP server.
Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native!
http://pubads.g.doubleclick.net/gampad/clk?id=63469471iu=/4140/ostg.clktrk
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public