From b15e3a2d34a91d16ff9ab9cc63c492142ac7b17b Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Sun, 10 Dec 2017 18:58:00 +0100 Subject: INSTALL: add some notes how to create Linux headers directory --- INSTALL | 58 ++++++++++++++++++++++++++++++++++------------------------ 1 file changed, 34 insertions(+), 24 deletions(-) (limited to 'INSTALL') diff --git a/INSTALL b/INSTALL index ae88aaf4b..05630d25a 100644 --- a/INSTALL +++ b/INSTALL @@ -2,32 +2,43 @@ SOFTWARE REQUIREMENTS Compiling uClibc-ng requires Linux kernel header files. uClibc-ng will be compiled to match the interfaces available in the provided - version of the Linux kernel headers. Linux kernel version 3.x is - supported. + version of the Linux kernel headers. Any modern Linux kernel is + supported (3.x/4.x). Its also helpful to have a working version of GNU binutils, and GNU gcc -- using excessively old versions of these packages can cause very strange errors that are difficult to find and fix. +INSTALLING Linux kernel headers: + + Extract a Linux kernel source tree and create a populated headers + directory: + + make INSTALL_HDR_PATH=/tmp/linux-headers headers_install CONFIGURING uClibc-ng: - Users must have a valid configuration file to compile uClibc-ng. Do not - skip this step. New configuration options are added in each - release, and odd configuration options are sometimes removed. - To configure uClibc-ng, you can run: + skip this step. New configuration options are added in each + release, and odd configuration options are sometimes removed. + To configure uClibc-ng, you can run: + + make menuconfig + or + make config - make menuconfig - or - make config + You need to point in "Target Architecture Features and Options" + the field "Linux kernel header location" to for example + /tmp/linux-headers/include if you installed the headers to + /tmp/linux-headers (Variable name KERNEL_HEADERS in .config). - If you have an existing .config file, you can update this file - using the + If you have an existing .config file, you can update this file + using the - make oldconfig + make oldconfig - command, which will only ask you about new configuration options. + command, which will only ask you about new configuration options. - Available configuration commands are: + Available configuration commands are: "make config" Text based configuration, no menus or colors. "make menuconfig" Text based color menus, radiolists & dialogs. "make oldconfig" Default all questions based on the contents of @@ -41,8 +52,8 @@ CONFIGURING uClibc-ng: COMPILING uClibc-ng: - uClibc-ng does not have proper dependancy checking so if you - change your uClibc-ng configuration, you must current rebuild the - entire library, by first running + change your uClibc-ng configuration, you must current rebuild the + entire library, by first running make clean @@ -50,8 +61,8 @@ COMPILING uClibc-ng: make - to compile uClibc-ng. or if you are cross compiling, you would - instead run something like: + to compile uClibc-ng. or if you are cross compiling, you would + instead run something like: make CROSS_COMPILE=arm-linux- @@ -62,20 +73,19 @@ INSTALLING the uClibc-ng development environment: make PREFIX= install - This will install the uClibc-ng runtime and development system (i.e. - all the header files, libraries, etc) into the directories defined - within your .config file. + This will install the uClibc-ng runtime and development system (i.e. + all the header files, libraries, etc) into the directories defined + within your .config file. USING uClibc-ng: - To compile programs with uClibc-ng you will need a complete toolchain - (i.e. binutils, gcc and uClibc-ng) that was built expressly for use - with uClibc-ng. + (i.e. binutils, gcc and uClibc-ng) that was built expressly for use + with uClibc-ng. - You have following choices at the moment: - - Use OpenADK from http://www.openadk.org + - Use OpenADK from https://openadk.org - Use Buildroot from http://www.buildroot.org - - Use OpenWrt from http://www.openwrt.org - Use Crosstool-NG from http://crosstool-ng.org - Use your own build scripts or environment -- cgit v1.2.3