Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: odd behaviour of some programs on i386 cross-built from amd64



At Tue, 28 Apr 2020 16:05:10 -0700, "Greg A. Woods" <woods%planix.ca@localhost> wrote:
Subject: Re: odd behaviour of some programs on i386 cross-built from amd64
>
> I guess now I'll have to dig into my local kernel changes to see what
> might be incompatible with a 32-bit system.  Maybe I can also try an ARM
> build to see if the same problems happen on an RPi or Beaglebone.

I'm still working on the evbarm build -- there were a number of weird
little botches I have had to fix to get the build to go all the way
through to a complete release, but it's nearly there.

In the mean time I finally remembered to try running old binaries from
previous releases, and they work A-OK, so this may give me a way forward
to debugging what's going wrong with the new binaries (and maybe make
the Soekris machine more usable in the mean time too):

# pwd
/building/build/woods/building/netbsd-5-i386-ppro-destdir
# ll usr/bin/od
368 -r-xr-xr-x  2 woods  wheel  187404 Jun  5  2016 usr/bin/od
# file usr/bin/od
usr/bin/od: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), statically linked, for NetBSD 5.2, stripped
# usr/bin/od
asdlkfj
0000000   071541  066144  063153  005152
0000010
# /usr/bin/od
od: "8/2  " %06o " "\n"": bad format


However at the moment while the old gdb (6.5 from 5.2_STABLE) works, it
won't read symbols from a new binary ("Dwarf Error"):


# file hexdump
hexdump: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), statically linked, for NetBSD 8.99.32, with debug_info, not stripped
# old-gdb hexdump
GNU gdb 6.5
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386--netbsdelf"...Dwarf Error: wrong version in compilation unit header (is 4, should be 2) [in module /future/build/woods/future/current-amd64-i386-ppro-obj/more/work/woods/m-NetBSD-current/usr.bin/hexdump/hexdump]

(gdb) run
Starting program: /future/build/woods/future/current-amd64-i386-ppro-obj/more/work/woods/m-NetBSD-current/usr.bin/hexdump/hexdump
warning: shared library handler failed to enable breakpoint
hexdump: ""%07.7_ax " 8/2 "%04x " "\n"": bad format

Program exited with code 01.
(gdb) break add
No symbol table is loaded.  Use the "file" command.
(gdb)

--
					Greg A. Woods <gwoods%acm.org@localhost>

Kelowna, BC     +1 250 762-7675           RoboHack <woods%robohack.ca@localhost>
Planix, Inc. <woods%planix.com@localhost>     Avoncote Farms <woods%avoncote.ca@localhost>

Attachment: pgp4qhQaZDwTw.pgp
Description: OpenPGP Digital Signature



Home | Main Index | Thread Index | Old Index