Subject: Re: [boost] ASIO does not fully support Windows Runtime and a suggestion for providing support
From: Niall Douglas (s_sourceforge_at_[hidden])
Date: 2015-01-16 05:02:16
On 16 Jan 2015 at 4:05, Moshe Rubin wrote:
> I suggest you start by modifying asio/detail/config.hpp to make those
> changes, and then see what errors happen after that. There will most
> likely be other changes needed to work around Windows API functions that
> are still unsupported on Windows Phone.
Ok, I clearly read meaning into your original post which wasn't
there. I apologise.
I have a partial solution for the other problem Chris mentioned now
that WinRT 8.1 has the Winsock API, that of missing Windows API
functions. It isn't widely known that mingw-w64 provides a
winstorecompat library which provides emulations of win32 APIs using
WinRT APIs, and therefore by linking to it with one fell swoop can
make many of the forbidden symbols go away. The winstorecompat
library was developed by VLC as part of their KickStarter funding to
port VLC to WinRT, so by now it is surely reasonably well tested.
You'll find the library at
aries/winstorecompat/src/, and just from the filenames of the source
files you'll see quickly what is supported.
It may therefore be worth compiling ASIO standalone in C++ 11 mode
targeting mingw-w64 with the winstorecompat build switched on, and
see how many of the unit tests pass plus how many banned APIs are
still generated in the executables. It would at least give you a good
idea of how much work remains for a complete WinRT port, and who
knows, it may just all work and you're done (on mingw-w64 at least).
If you need help with configuring the mingw-w64 toolchain for a WinRT
target, try examining the VLC sources as I'd assume this is not a
well documented use case.
I hope this is useful.
-- ned Productions Limited Consulting http://www.nedproductions.biz/ http://ie.linkedin.com/in/nialldouglas/
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk