File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -175,17 +175,15 @@ Linux Headers
175175=============
176176
177177If you are using the full libc on Linux, then you will also need to install
178- Linux headers in your sysroot. The way to do this varies per system.
179-
180- These instructions should work on a Debian-based x86_64 system:
178+ Linux headers in your sysroot. Let's build them from source.
181179
182180.. code-block :: sh
183181
184- $> apt download linux-libc-dev
185- $> dpkg -x linux-libc-dev * deb .
186- $ > cp -r usr/ * /path/to/sysroot/
187- $ > rm -r usr linux-libc-dev * deb
188- $ > ln -s /path/to/sysroot/include/x86_64-linux-gnu/asm /path/to/sysroot/include/asm
182+ $> git clone --depth=1 git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git /tmp/linux
183+ $> make LLVM=1 INSTALL_HDR_PATH=/path/to/sysroot -C /tmp/ linux headers_install
184+
185+ The headers can be built to target non-host architectures by adding the
186+ `` ARCH={arm|arm64|i386} `` to the above invocation of `` make ``.
189187
190188Using your newly built libc
191189===========================
You can’t perform that action at this time.
0 commit comments