[libc-commits] [PATCH] D146049: [libc] Add instructions for linux headers

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


This revision was automatically updated to reflect the committed changes.
Closed by commit rG1b89aeb517f1: [libc] Add instructions for linux headers (authored by jeffbailey).

Changed prior to commit:
  https://reviews.llvm.org/D146049?vs=505098&id=505354#toc

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D146049/new/

https://reviews.llvm.org/D146049

Files:
  libc/docs/full_host_build.rst


Index: libc/docs/full_host_build.rst
===================================================================
--- libc/docs/full_host_build.rst
+++ libc/docs/full_host_build.rst
@@ -95,8 +95,17 @@
 =============
 
 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
 ===========================


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D146049.505354.patch
Type: text/x-patch
Size: 892 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libc-commits/attachments/20230315/255f360e/attachment.bin>


More information about the libc-commits mailing list