EricWF added a reviewer: EricWF. EricWF added a comment. @jroelofs Thanks for this patch. I've needed this for a while.
================ Comment at: include/__config:19 @@ -18,1 +18,3 @@ +#include <__config_site> + #ifdef __GNUC__ ---------------- jroelofs wrote: > jroelofs wrote: > > mclow.lists wrote: > > > espositofulvio wrote: > > > > mclow.lists wrote: > > > > > I'm reluctant to do this; because every include file slows down > > > > > compilation - for every program that we compile. > > > > > > > > > > However, this may be the right thing to do. > > > > I'm with Jonathan here, having config params dealt with this way it's > > > > easier and make things more manageable while the price of a slowdown, I > > > > think, shouldn't be substantial. > > > I just realized that this will complicate life for libc++ developers. > > > Today, I can make a change in the checked-out directory, and test it by > > > using `clang -I <path to libcxx>`. Now, I'll have to actually build and > > > install the headers some where to test. [ Especially when testing > > > against an installed compiler whose libc++ does not have a __config_site > > > file ] > > Another option would be to rename `__config` to `__config.in`, and put the > > `#cmakedefine` lines in here. Then the include tree isn't changed. > > Now, I'll have to actually build and install the headers some where to test. > > Just building is sufficient. The headers get copied to the build directory, > along with this new file. > > > > [ Especially when testing against an installed compiler whose libc++ does > > not have a __config_site file ] > > Why does your workflow rely on testing libcxx binaries against installed > headers from a _different_ build of the library? That seems very dicey. > Just building is sufficient. The headers get copied to the build directory, > along with this new file. Except in "exceptional" configurations the `__config_site` file should essentially remain empty. We could put an empty `__config_site` file in the source directory and telling CMake to ignore it. This would prevent the need to rebuild libc++ as frequently for the majority of developers. http://reviews.llvm.org/D11963 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits