[PATCH] libc++: Add option to disable access to the global filesystem namespace

Eric Fiselier eric at efcs.ca
Thu Mar 12 11:27:02 PDT 2015


REPOSITORY
  rL LLVM

================
Comment at: libcxx/trunk/include/__config:731
@@ +730,3 @@
+// used, as they attempt to access the global filesystem namespace.
+#ifdef __CloudABI__
+#define _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
----------------
jroelofs wrote:
> EricWF wrote:
> > jroelofs wrote:
> > > EricWF wrote:
> > > > jroelofs wrote:
> > > > > EricWF wrote:
> > > > > > Where do we get the definition for `__CloudABI__` from?
> > > > > Compiler provides it, just like `__APPLE__` and all the others.
> > > > Where can I find more information about when Clang defines this macro?
> > > http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20150302/264362.html
> > > 
> > > http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20150309/125077.html
> > Thanks. Since `_LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE` is set in the `__config` file I don't really see why we need to manually define it in CMake and LIT unless we want to be able to test these configurations on platforms which are not `__CloudABI__` (ex FreeBSD which was mentioned).
> > 
> > Can someone explain why we need this?
> > Can someone explain why we need this?
> 
> Same reason we need the corresponding thing for the singlethreaded stuff...
> 
> http://reviews.llvm.org/D8293
We need the single threaded stuff because that macro is not defined it the `__config` header but this one is.

http://reviews.llvm.org/D8194

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the cfe-commits mailing list