Hallo,

>> Would a 32-bit kernel work if I compile it on a 64-bit machine with the
>> 32-bit config taken from the current compile system?

> I think you need at least a multilib gcc.

I had success! After a bit of experimenting I found the following to work:

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.

Afterwards you can collect the package and move from the 64-bit system
to the 32-bit system.

cd /sources/linux-5.3.15
mkdir -p build/{boot,lib}
export INSTALL_PATH=/sources/linux-5.3.15/build/boot
export INSTALL_MOD_PATH=/sources/linux-5.3.15/build
make install modules_install
tar -C build -cf ../linux-5.3.15-32.tar boot lib

The tar file needs to be unpacked in the root directory of the 32-bit
machine, grub.cfg needs a new entry pointing to the kernel and you're done.

Failed attempt: use only the compiled kernel and try to keep the
previously installed modules (since I had the same kernel version
already running on the 32-bit system). Obviously the kernel verifies
some compiler version-specific signature and refuses to load kernel
modules compiled with a different gcc. So you need to install kernel and
modules from the same compile but that should be the usual case.

PS: is System.map required for normal operation or is it only required
for devs doing some sort of bug tracking? I'm tempted to omit the file.

Tschau...Thomas
--
Do you wanna be a legend or a passing footprint on the sands of time?
-- 
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