On Thu, 12 Dec 2019 16:29:27 +0100
Thomas Seeling <thomas.seel...@gmx.net> wrote:

> take the .config from the 32-bit system and copy into the usual place on
> the compile machine. A multilib gcc is not required. I did not build the
> LFS for my 64-bit machine with multilib afair and it works.
> 
> Since you cannot "install" and "modules_install" you need to give
> temporary install paths for the kernel and the modules. These are 2
> distinct environment variables that have to be set.


  Thomas,

FWIW, the kernel build system also has environment variables to specify
the machine/CPU architecture as well as an alternate compiler.
For example, to build a 64 bit kernel on a 32 bit system, you could
do something like:

make ARCH=x86_64 CROSS_COMPILE=/opt/crosstools/bin/x86_64-linux-gnu- menuconfig
make ARCH=x86_64 CROSS_COMPILE=/opt/crosstools/bin/x86_64-linux-gnu- -j8
make ARCH=x86_64 CROSS_COMPILE=/opt/crosstools/bin/x86_64-linux-gnu- 
modules_install

where x86_64-linux-gnu- is the name prefix assigned to a cross gcc
(a 64 bit capable gcc, built using the --program-prefix=x86_64-linux-gnu-
during gcc configuration.) You can also use this approach to use any special
version of gcc for the kernel build.

In your case, a simple

make ARCH=x86_32 ...

should do the trick as long as your system gcc supports the specified
architecture and your .config is otherwise correct (including the
processor type) for what you want.

Also, there is a patch for the kernel source that enables additional
processor types and CPU specific optimizations:

https://github.com/graysky2/kernel_gcc_patch

IMHO, this patch should be accepted into the mainstream kernel tree.


  Cheers,

  Mike Shell

-- 
http://lists.linuxfromscratch.org/listinfo/lfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page

Do not top post on this list.

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?

http://en.wikipedia.org/wiki/Posting_style

Reply via email to