<div dir="ltr">I would be happy to commit better instructions to the web site (aka “patches welcome”)<div><br></div><div>This is how I build libc++ with cmake (on Mac OS, not Linux)</div><div><br></div><div>LLVM_BUILD  is a directory where my builds go<br>
</div><div>LIBCXX is where libc++ is checked out<br></div><div><br></div><div><div># Set up cmake build</div><div><br></div><div>cd $LLVM_BUILD</div><div>rm -rf libcxx-cmake-build ; mkdir libcxx-cmake-build ; cd libcxx-cmake-build </div>
<div>TRIPLE=-apple- CXX=$LLVM_BIN/clang++ CXX=$LLVM_BIN/clang++ cmake -DCMAKE_BUILD_TYPE=Release $LIBCXX</div><div><br></div><div># build libcxx with CMake</div><div>cd $LLVM_BUILD/libcxx-cmake-build</div><div>make -j 4 <br>
</div></div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Jul 8, 2014 at 10:23 PM, Ben Pope <span dir="ltr"><<a href="mailto:benpope81@gmail.com" target="_blank">benpope81@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="">On Wednesday, July 09, 2014 02:48 AM, Larry Evans wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
The instructions on:<br>
   <a href="http://libcxx.llvm.org/" target="_blank">http://libcxx.llvm.org/</a><br>
say:<br>
    We can now run CMake:<br>
<br>
     CC=clang CXX=clang++ cmake -G "Unix Makefiles"<br>
-DLIBCXX_CXX_ABI=libstdc++<br>
-DLIBCXX_LIBSUPCXX_INCLUDE_<u></u>PATHS="/usr/include/c++/4.7/;/<u></u>usr/include/c++/4.7/x86_64-<u></u>linux-gnu/"<br>
-DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr <libc++-source-dir><br>
<br>
however, it does not say what to put for <libc++-source-dir><br>
or in which directory this command is to be run.  One might<br>
guess this command is to be run inb the directory where the buildit<br>
script is located, because that's what the earlier instructions<br>
(for Mac OS) were run from; however, that's not at all clear.<br>
</blockquote>
<br></div>
CMake encourages out of source build.<br>
<br>
You run CMake in your build directory and you point it to your source diectory (the one with CMakeLists.txt).<br>
<br>
E.g.:<br>
<br>
/libcxx_build<br>
/libcxx<br>
   /include<br>
   CMakeLists.txt<br>
<br>
cd /libcxx/build<br>
CMake ../libcxx<br>
<br>
Or:<br>
/libcxx<br>
   /build<br>
   /include<br>
   CMakeLists.txt<br>
<br>
cd /libcxx/build<br>
CMake ..<span class="HOEnZb"><font color="#888888"><br>
<br>
Ben</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
______________________________<u></u>_________________<br>
cfe-users mailing list<br>
<a href="mailto:cfe-users@cs.uiuc.edu" target="_blank">cfe-users@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-users" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/cfe-users</a><br>
</div></div></blockquote></div><br></div>