0

I am trying to install wifi and bluetooth drivers using this link, http://processors.wiki.ti.com/index.php/WL18xx_System_Build_Scripts on my ARM based board (microzed) running ubuntu 12.04.

As per step 2 of the link, where they have mentioned different parameters for cross compilation, I am confused on how to set these parameters because I am compiling natively on the ARM processor itself.

1.) TOOLCHAIN_PATH : What should this parameter be set to ? I am compiling natively on my processor itself. So, not sure what this should be set to.

2.) ROOTFS: What is this path generally ? How can i find this on my OS ?

3.) KERNEL_PATH: Is this the kernel header path ? I have the folder, /usr/src/kernels/3.12.0-xillinux-1.3 Is this the kernel path that I should set to ?

And the parameters below:

export CROSS_COMPILE=arm-linux-gnueabihf-
export ARCH=arm

can be left as it is or should they be changed to something else as I am compiling natively ?

Claudio
  • 10,614
  • 4
  • 31
  • 71
bobbydf
  • 183
  • 1
  • 4
  • 13
  • `TOOLCHAIN_PATH=/bin;usr/bin` or something like that. Try `which gcc`. `ROOTFS=/` for building on the host==build==target or native. I think that `KERNEL_PATH` is for headers and an install, but I am not 100% sure. Read the [documentation](https://www.kernel.org/doc/Documentation/kbuild/modules.txt) for your kernel version. Set `CROSS_COMPILE` to empty or `unset` it. – artless noise Nov 23 '15 at 14:36

1 Answers1

0

Supposing you don't need to cross-compile (but you will natively compile on your ARM machine):

  • TOOLCHAIN_PATH: directory containing the gcc compiler (use which gcc to discover)
  • ROOTFS=/: directory containing the filesystem of the target (set to / because you're not cross-compiling)
  • KERNEL_PATH: directory containing an (already compiled) kernel for your board
  • CROSS_COMPILE: leave it blank, since you are not cross-compiling
  • ARCH=arm

By the way, if instead you need to cross-compile, then you have to set the variables as follows:

  • TOOLCHAIN_PATH: directory containing the gcc cross-compiler
  • ROOTFS: directory containing the filesystem of the target board
  • KERNEL_PATH: directory containing an (already compiled) kernel for the target board
  • CROSS_COMPILE: must be equal to the absolute path and the beginning of the name of the compiler stripped of the gcc name; for example if your compiler is arm-linux-gcc inside the directory /my/path/ then you will set CROSS_COMPILE=/my/path/arm-linux-)
  • ARCH=arm
Claudio
  • 10,614
  • 4
  • 31
  • 71
  • Thanks. For cross compiling, should I copy the kernel headers (/lib/modules/3.12.0) from the ARM board into the PC and indicate that path in the KERNEL:PATH ? Also, what should I set ROOTFS to for cross compilation ? I am a bit confused with ROOTFS. – bobbydf Nov 26 '15 at 11:56
  • No:`KERNEL_PATH` points to a directory of a *full* kernel (not just headers) that must be *already compiled*. Unfortunately, that's needed by the Linux kernel module build system. Concerning `ROOTFS`, no idea why this specific module needs it. I *suppose* that it is just where the binaries will be copied. – Claudio Nov 26 '15 at 12:45