ports/ia64: klibc-utils in Sid should use static binaries

Frank Scheiner <[email protected]>
Newsgroups gmane.linux.debian.ports.ia64
Message-ID <[email protected]>
Dear all,

recently a kernel package for ia64 appeared on ftp.p.d.o and hence I 
thought it might be a good time to give it a try to create a Debian 
GNU/Linux Sid for ia64 FS with `debootstrap` from Sid but executing from 
a Debian Wheezy installation. After some trial and error I was 
successful - at least to some degree.

Many thanks to all people that were/are involved in getting Debian back 
on Itanium. :-)

## Long story short ##

1. The kernel image provided by [1] does not work on my rx2620 but 
panics early:

```
[    0.000000] Linux version 4.17.0-rc7-mckinley 
([email protected]) (gcc version 7.3.0 (Debian 7.3.0-18)) 
#1 SMP Debian 4.17~rc7-1~exp1 (2018-05-29)
[...]
[    0.052000] Kernel panic - not syncing: corrupted stack end detected 
inside scheduler
[    0.052000]
[    0.052000] ---[ end Kernel panic - not syncing: corrupted stack end 
detected inside scheduler
[    0.052000]  ]---
[    1.048000] random: fast init done
[   53.528000] random: crng init done
```

[1]: 
http://ftp.ports.debian.org/debian-ports/pool-ia64/main/l/linux/linux-image-4.17.0-rc7-mckinley_4.17~rc7-1~exp1_ia64.deb

..but I remember I could successfully run a v4.15.11 Debian kernel 
(though built under Debian Wheezy with the .config of the Wheezy kernel 
as basis for `make oldconfig`) on this machine in mid of April. I 
currently run the Sid FS with the v3.14.x kernel from Wheezy backports 
and the `klibc-utils` from Wheezy.

2. The currently available `klibc-utils` (for the initramfs) on Sid are 
broken for ia64 (most likely due to no longer being built as static 
binaries like in Wheezy, see [2] for details). When executed most tools 
segfault, others (without interpreter, meaning non-shared) do not:
```
root@rx2620:/usr/lib/klibc/bin# file cat zcat

cat:  ELF 64-bit LSB executable, IA-64, version 1 (SYSV), statically 
linked, interpreter /lib/klibc-LUey2dkAvJnuUY2c2omL8wPG9DQ.so, stripped

zcat: ELF 64-bit LSB executable, IA-64, version 1 (SYSV), statically 
linked, stripped

root@rx2620:/usr/lib/klibc/bin# ./cat /proc/cpuinfo
Segmentation fault

root@rx2620:/usr/lib/klibc/bin# lscpu | gzip -c | ./zcat
Architecture:        ia64
[...]
Model name:          Dual-Core Intel(R) Itanium(R) Processor 9020
[...]
```
...whereas on Wheezy the tools (also without interpreter!) work without 
issue:
```
root@rx2620:/tmp/wheezy/usr/lib/klibc/bin# file cat zcat

cat:  ELF 64-bit LSB executable, IA-64, version 1 (SYSV), statically 
linked, stripped

zcat: ELF 64-bit LSB executable, IA-64, version 1 (SYSV), statically 
linked, stripped

root@rx2620:/tmp/wheezy/usr/lib/klibc/bin# ./cat /proc/cpuinfo
processor  : 0
vendor     : GenuineIntel
arch       : IA-64
family     : 32
model      : 0
model name : Dual-Core Intel(R) Itanium(R) Processor 9020
[...]
```

[2]: 
https://salsa.debian.org/kernel-team/klibc/commit/07809ffd86e1e4ca5a4e98e4708a1c1fae10babf

I don't have a clue how to rebuild the `klibc-utils` package in this Sid 
FS with some of the build dependencies missing. So could someone please 
rebuild them with the ia64 parts of [2] reverted and upload a new 
package to ftp.p.d.o?

Cheers,
Frank
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.