build utmpd as 64-bit binary
With slightly older screen, I did notice the issue in output of w and who:
tsoome@openindiana:/code/illumos-gate$ w 00:04:43 2 users, load average: 0,93, 1,06, 1,05 User tty login@ idle JCPU PCPU what tsoome pts/2 23:23:57 2 1 0 /usr/bin/bash tsoome pts/1 23:52:22 0 0 0 w tsoome pts/3 23:22:05 0 0 0 - tsoome pts/3 23:22:05 0 0 0 - tsoome@openindiana:/code/illumos-gate$ who tsoome pts/2 okt 6 23:23 (10.7.33.28) tsoome pts/1 okt 6 23:52 (10.7.33.28) tsoome pts/3 okt 6 23:22 (:pts/2:S.0) tsoome pts/3 okt 6 23:22 (:pts/2:S.0) tsoome@openindiana:/code/illumos-gate$
This system was built with gcc 10 on sparc, and the problem is not about w and who commands, but about 32-bit ABI - gcc 10 does not implement complementing 32-bit signed data to 64-bit (as does gcc 4.4.4). From one hand this is bug, but in this particular case, we can work around by building utmpd as 64-bit binary. It is a bit odd reason, but as good as any other IMO.
Testing done: build/install/boot, the w/who are producing expected output on x86 and on sparc.
Updated by Toomas Soome 4 months ago
Robert Mustacchi wrote in #note-3:
Cannot we not fix the SPARC ABI? We keep working around it, but it's actually one of the big pieces (along with cross building) for IPD 19.
I'm sure we can, just that according to https://www.illumos.org/issues/2757, the full fix is some amount of work in any case.
Updated by Electric Monk about 1 month ago
- Status changed from In Progress to Closed
- % Done changed from 90 to 100
commit 2c181cc4d9d2e7a92c98a12cafffc6dadff80019 Author: Toomas Soome <email@example.com> Date: 2021-12-15T17:07:10.000Z 14141 build utmpd as 64-bit binary Reviewed by: Andrew Stormont <firstname.lastname@example.org> Reviewed by: Yuri Pankov <email@example.com> Reviewed by: Klaus Ziegler <firstname.lastname@example.org> Approved by: Dan McDonald <email@example.com>