[libcxx-commits] [libcxx] Fix bug in documentation regarding dependencies. (PR #84930)

via libcxx-commits libcxx-commits at lists.llvm.org
Tue Mar 12 08:20:59 PDT 2024


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-libcxx

Author: Eric (EricWF)

<details>
<summary>Changes</summary>

The docs for building modules suggest you have to build with -j1 and
build the std modules first. Fortunetly, that's just a bug in the
documentation. By correctly listing the libraries as dependencies,
the build system will order the builds correctly.


---
Full diff: https://github.com/llvm/llvm-project/pull/84930.diff


1 Files Affected:

- (modified) libcxx/docs/Modules.rst (+2) 


``````````diff
diff --git a/libcxx/docs/Modules.rst b/libcxx/docs/Modules.rst
index ee2b81d3b9e7ca..234cb53cecfb27 100644
--- a/libcxx/docs/Modules.rst
+++ b/libcxx/docs/Modules.rst
@@ -206,6 +206,8 @@ This is a small sample program that uses the module ``std``. It consists of a
   #
 
   add_executable(main)
+  add_dependencies(main std)
+  target_link_libraries(std)
   target_sources(main
     PRIVATE
       main.cpp

``````````

</details>


https://github.com/llvm/llvm-project/pull/84930


More information about the libcxx-commits mailing list