Building Linux API Headers

  1. Mount slax slax-6.1.2.iso as a virtual disk or burn it to real media (CD-RW/DVD-RW), and copy its contents to new folder C:\slax-merge.
  2. Copy slax "Compiler Pack" module (devel-2008.lzm) into the folder C:\slax-merge\slax\modules.
  3. Create "home" subfolder in C:\slax-merge\slax\rootcopy folder and copy linux kernel source tarball (linux-2.6.31.14.tar.bz2) there.
  4. Run "make_iso.bat c:\new-slax.iso" command from C:\slax-merge\slax folder.
  5. You may delete C:\slax-merge folder now.
  6. Boot your virtual machine with Cygwin from c:\new-slax.iso.
  7. Open the terminal, and run following commands:
    $ cd /home
    $ ls -l
    $ tar zxvf linux-2.6.31.14.tar.bz2
    $ mkdir linux-api-headers-2.6.31.14
    $ cd linux-2.6.31.14
    $ make headers_check
    $ make INSTALL_HDR_PATH=/home/linux-api-headers-2.6.31.14 headers_install
    $ cd /home
    $ ls -l
    $ rm -rf linux-2.6.31.14
    $ tar jcvf linux-api-headers-2.6.31.14.bz2 linux-api-headers-2.6.31.14
    $ df
    $ cp linux-api-headers-2.6.31.14.bz2 /mnt/hda1
    Replace 2.6.31.14 with version of your target linux kernel and maybe hda1 with sda1 if df output suggests so.


>> Read next section or buy already prepared cross-compiler ($10) to save your time.