[cfe-dev] [PATCH] Libc++ Windows fixes
Ruben Van Boxem
vanboxem.ruben at gmail.com
Tue Jun 28 12:15:28 PDT 2011
This is a larger patch with a bit more changes. I added a
win32/support.h/cpp to add any missing functionality. For now that's
only a simple enum and a simple vasprintf implementation.
Note that to get as far as this, with the current _STD macro problem
(because it is used internally in the MS headers), you need to add a
temporary workaround #define in the problematic file. That does not
have to be committed!
The cerrno macro's are from Boost, so "yes, they are correct", and
"no, there are no license restrictions whatsoever". The _strto*_l
functions are available on Windows msvcrt version 7. That's the
default somewhere Vista/7-ish, so those aren't available on XP. I
believe the Linux locale patch also takes into consideration providing
a Windows alternative with little or no modification.
I'm quite sure the win32/support.h/cpp isn't the nicest solution,
please do as you wish, there just needs to be a central place to add
missing fundamental functionality. Perhaps a larger splitting of OS
dependent functionality might be appropriate in the future.
As of with this patch (which includes the _STD clash workaround, I am
now stranded at the catopen call in __locale, which as a little
googling shows is very non-Windows-ish, and perhaps needs a lot more
than just extra constants, #defines and #includes.
I would be pleased if anyone would commit at least the part of it they like :)
Thanks,
Ruben
-------------- next part --------------
A non-text attachment was scrubbed...
Name: windows2.patch
Type: application/octet-stream
Size: 7784 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20110628/24ef43d9/attachment.obj>
More information about the cfe-dev
mailing list