[libc-commits] [libc] 1b89aeb - [libc] Add instructions for linux headers

Jeff Bailey via libc-commits libc-commits at lists.llvm.org
Tue Mar 14 20:02:21 PDT 2023


Author: Jeff Bailey
Date: 2023-03-15T03:02:16Z
New Revision: 1b89aeb517f1b0b80687825283e0765a0dadc24d

URL: https://github.com/llvm/llvm-project/commit/1b89aeb517f1b0b80687825283e0765a0dadc24d
DIFF: https://github.com/llvm/llvm-project/commit/1b89aeb517f1b0b80687825283e0765a0dadc24d.diff

LOG: [libc] Add instructions for linux headers

Reviewed By: sivachandra

Differential Revision: https://reviews.llvm.org/D146049

Added: 
    

Modified: 
    libc/docs/full_host_build.rst

Removed: 
    


################################################################################
diff  --git a/libc/docs/full_host_build.rst b/libc/docs/full_host_build.rst
index e5c5cc1e7e223..709ba70b22de4 100644
--- a/libc/docs/full_host_build.rst
+++ b/libc/docs/full_host_build.rst
@@ -95,8 +95,17 @@ Linux Headers
 =============
 
 If you are using the full libc on Linux, then you will also need to install
-Linux headers in your sysroot. It is left to the reader to figure out the best
-way to install Linux headers on the system they want to use the full libc on.
+Linux headers in your sysroot.  The way to do this varies per system.
+
+These instructions should work on a Debian-based x86_64 system:
+
+.. code-block:: sh
+
+   $> apt download linux-libc-dev
+   $> dpkg -x linux-libc-dev*deb .
+   $> mv usr/include/* /path/to/sysroot/include
+   $> rm -rf usr linux-libc-dev*deb
+   $> ln -s x86_64-linux-gnu/asm ~/Programming/sysroot/include/asm
 
 Using your newly built libc
 ===========================


        


More information about the libc-commits mailing list