Server Rack

Yggdrasil Reloaded - Breathing New Life Into a Forgotten Linux Distribution: Part 2

After almost giving up, I decided to start from scratch and do a fresh reinstall of Yggdrasil on a slightly larger hard disk.

Going from 1.2.13 to 2.2.0 for the Kernel

Yeah... no. This didn't work and still is not. Before I went straight to 2.2.0, I decided to go from 2.0 to 2.0.10, 2.0.35, then 2.2.0 but I ended up getting annoying ASM errors such as below every time I attempted to compile the kernel for 2.2.0:

/usr/src/linux/include/asm/string.h:159: Invalid asm statement: fixed or forbidden register 4 (si) was spilled for class CREG. /usr/src/linux/include/asm/string.h:140: Invalid asm statement: fixed or forbidden register 2 (cx) was spilled for class SIREG. /usr/src/linux/include/asm/string.h:118: Invalid asm statement: fixed or forbidden register 4 (si) was spilled for class CREG. /usr/src/linux/include/asm/string.h:118: Invalid asm statement: fixed or forbidden register 4 (si) was spilled for class SIREG. /usr/src/linux/include/asm/string.h:118: Invalid asm statement: fixed or forbidden register 4 (si) was spilled for class SIREG. /usr/src/linux/include/asm/string.h:140: Invalid asm statement: fixed or forbidden register 2 (cx) was spilled for class CREG. /usr/src/linux/include/asm/string.h:159: Invalid asm statement: fixed or forbidden register 4 (si) was spilled for class SIREG. make: *** [init/main.o] Error 1

These are issues with the inline assembly. In assembly language, certain registers are designated for specific purposes, and using them incorrectly can lead to unpredictable behavior or crashes. I sort of got it to work by changing my CPU from an AMD K6 to a Pentium since it would also spit out errors about -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=586.

That was just the configuration and all, as the make progress gave me errors like this:

gcc -D__KERNEL__ -I/usr/src/linux/include -Wall -Wstrict-prototypes -O2 -fomit-frame-pointer -fno-strength-reduce -pipe -m486 -malign-loops=2 -malign-jumps=2 -malign-functions=2 -DCPU=586 -c -o ics2101.o ics2101.c ... make[1]: *** [linuxsubdirs] Error 2

This was not much of a big deal because it was just a low-level driver for Turtle Beach Maui and Tropez cards(?) that I didn't have stuff for, so I fixed it by going back into the config file and removing them before compiling the kernel again. In the end I realised trying to go from 1.2.13 to 2.2.0 does not work without hacks and tweaks.

s_frexpl.c:42: #error "Cannot handle this MANT_DIG"

This error was the WORST and was another kernel-related one with a specific floating-point number’s precision. I can't remember how I fixed it, but I ended up getting to version 2.0 of the kernel.

There were many more errors such as this one:

make[2]: Leaving directory /usr/src/linux/arch/i386/mm make[1]: Leaving directory /usr/src/linux/arch/i386/mm make[1]: Entering directory /usr/src/linux/arch/i386/lib make all_targets ... make: *** [linuxsubdirs] Error 2

Which I got when trying to compile version 2.0.35. I considered trying patches again but did not and ended up finding a solution to this... which I also forgot because I did not track some of the stuff I did.

With everything done and me being at version 2.0.35 of the kernel, it was time to gather all the software I needed for 2.2.0. You need certain versions of programs to compile version 2.2.0 which I gathered but when it came to compiling each one... ugh, that was not fun either. I attempted to try it in a specific order but I got errors for programs like:

Binutils 2.9:

if [ -f .libs/libopcodes.a ]; then \ cp .libs/libopcodes.a libopcodes.tmp; \ /bin/sh ../../move-if-change libopcodes.tmp libopcodes.a; \ else true; fi touch stamp-lib make[1]: Leaving directory /usr/src/binutils-2.9/opcodes' make[1]: Entering directory /usr/src/binutils-2.9/binutils' gcc -DHAVE_CONFIG_H -I. -I. -I../include -g -O2 -c size.c gcc -DHAVE_CONFIG_H -I. -I. -I../include -g -O2 -c bucomm.c gcc -DHAVE_CONFIG_H -I. -I. -I../include -g -O2 -c version.c gcc -DHAVE_CONFIG_H -I. -I. -I../include -g -O2 -c filemode.c make[1]: *** No rule to make target ../libiberty/libiberty.a', needed by size'. Stop. make[1]: Leaving directory /usr/src/binutils-2.9/binutils' make: *** [install-binutils] Error 2

Make 3.75:

make[1]: 'libglob.a' is up to date. make[1]: Leaving directory '/usr/src/make-3.75/glob' /usr/bin/install -c make /usr/local/bin/make.new rm -f /usr/local/bin/make.old mv /usr/local/bin/make /usr/local/bin/make.old mv: /usr/local/bin/make: No such file or directory make: [/usr/local/bin/make] Error 1 (ignored) mv /usr/local/bin/make.new /usr/local/bin/make if [ -r ./make.info ]; then dir=.; else dir=.; fi; \ for file in ${dir}/make.info*; do \ name=basename $file; \ /usr/bin/install -c -m 644 $file \ echo /usr/local/info/make.info | sed "s,make.info$,$name,"; \ done if /bin/sh -c 'install-info --version' > /dev/null 2>&1; then \ if [ -r ./make.info ]; then dir=.; else dir=.; fi; \ install-info --infodir=/usr/local/info $dir/make.info; \ else true; fi * Make: (make). The GNU Make utility, which determines automatically \ which pieces of a large program need to be recompiled, and issues the commands to recompile them. install-info: failed to lock dir for editing! No such file or directory make: *** [/usr/local/info/make.info] Error 2

Glibc 2.0.7pre6:

In file included from sysdeps/unix/sysv/linux/errno.h:24, from sysdeps/unix/i386/sysdep.S:21, from sysdeps/unix/sysv/linux/i386/sysdep.S:55: /usr/include/linux/errno.h:4: asm/errno.h: No such file or directory mv -f sysdep.T sysdep.d gcc -Bsysdeps/../sysdeps/unix/sysv/linux/i386/sysdep.S -c -I. -Ilibio -Isyde ps/i386/elf -Isydeps/unix/sysv/linux/i386 -Isydeps/unix/sysv/linux -Isydeps/g mu -Isydeps/unix/common -Isydeps/unix/mman -Isydeps/unix/xinet -Isydeps/unix/ sysv/i386 -Isydeps/unix -Isydeps/posix -Isydeps/i386/i586 -Isydeps/i386/i486 -Isydeps/i386/fpu -Isydeps/i386 -Isydeps/wordsize-32 -Isydeps/ieee754 -Isyde ps/generic -Isydeps/stub -include libc-symbols.h -DASSEMBLER -DGAS_SYNTAX -o sysdep.o In file included from sysdeps/unix/sysdep.h:21, from sysdeps/unix/i386/sysdep.h:19, from sysdeps/unix/sysv/linux/i386/sysdep.S:24, from sysdeps/unix/sysv/linux/i386/sysdep.S:19: /sysdeps/unix/sysv/linux/sys/syscall.h:25: asm/unistd.h: No such file or directory In file included from sysdeps/unix/sysv/linux/errno.h:24, from sysdeps/unix/i386/sysdep.S:21, from sysdeps/unix/sysv/linux/i386/sysdep.S:55: /usr/include/linux/errno.h:4: asm/errno.h: No such file or directory make: *** [sysdep.o] Error 1

And many more. Some of these worked with make and make install after doing tweaks to their source files, while others just plain out refused to. I think I will take a break for now...