[PATCH] D25431: [libcxx] Convert Solaris support library to C++ to fix -std=c++11 build
Michał Górny via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 18 07:07:21 PDT 2016
mgorny updated the summary for this revision.
mgorny updated this revision to Diff 74996.
mgorny added a comment.
Ok, here's a minimal change necessary to fix the build. I'm not touching anything else not to break it ;-).
https://reviews.llvm.org/D25431
Files:
lib/CMakeLists.txt
src/support/solaris/xlocale.c
src/support/solaris/xlocale.cpp
Index: src/support/solaris/xlocale.cpp
===================================================================
--- src/support/solaris/xlocale.cpp
+++ src/support/solaris/xlocale.cpp
@@ -14,12 +14,13 @@
#include <stdio.h>
#include <sys/localedef.h>
+extern "C" {
int isxdigit_l(int __c, locale_t __l) {
return isxdigit(__c);
}
-int iswxdigit_l(wchar_t __c, locale_t __l) {
+int iswxdigit_l(wint_t __c, locale_t __l) {
return isxdigit(__c);
}
@@ -63,4 +64,6 @@
return localeconv();
}
+};
+
#endif // __sun__
Index: lib/CMakeLists.txt
===================================================================
--- lib/CMakeLists.txt
+++ lib/CMakeLists.txt
@@ -6,7 +6,7 @@
file(GLOB LIBCXX_WIN32_SOURCES ../src/support/win32/*.cpp)
list(APPEND LIBCXX_SOURCES ${LIBCXX_WIN32_SOURCES})
elseif("${CMAKE_SYSTEM_NAME}" STREQUAL "SunOS")
- file(GLOB LIBCXX_SOLARIS_SOURCES ../src/support/solaris/*.c)
+ file(GLOB LIBCXX_SOLARIS_SOURCES ../src/support/solaris/*.cpp)
list(APPEND LIBCXX_SOURCES ${LIBCXX_SOLARIS_SOURCES})
endif()
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D25431.74996.patch
Type: text/x-patch
Size: 1053 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20161018/9a055a7e/attachment.bin>
More information about the cfe-commits
mailing list