Current-Users archive

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

build failure in rescue?



Hi,

I recently tried to build a new "virt68k" release locally.

I did this as a non-update build, so it should not fail due to
crud left in OBJDIR.  However, I left DESTDIR populated by the
previous built which was OLD, from the middle of last year.
The build failed with

    compile  ssh/auth.o
    compile  ssh/auth-options.o
       link  ssh/ssh.ro
    compile  rescue/rescue.o
       link  rescue/rescue
/u/build/HEAD/tools/virt68k/lib/gcc/m68k--netbsdelf/12.5.0/../../../../m68k--net
bsdelf/bin/ld: ssh.cro: in function `ssh_login$$from$$ssh':
(.text+0x19d42): undefined reference to `kex_is_pq_from_name'
/u/build/HEAD/tools/virt68k/lib/gcc/m68k--netbsdelf/12.5.0/../../../../m68k--net
bsdelf/bin/ld: ssh.cro: in function `_crunched_ssh_stub':
(.text.startup+0x1af6): undefined reference to `ssh_packet_set_qos'
/u/build/HEAD/tools/virt68k/lib/gcc/m68k--netbsdelf/12.5.0/../../../../m68k--net
bsdelf/bin/ld: (.text.startup+0x359e): undefined reference to `ssh_packet_free'
/u/build/HEAD/tools/virt68k/lib/gcc/m68k--netbsdelf/12.5.0/../../../../m68k--netbsdelf/bin/ld: (.text.startup+0x35a8): undefined reference to `pwfree'
collect2: error: ld returned 1 exit status
--- rescue ---

Now, I think I have found the reason for this failure.  What's
happened between the previous build and this one is that OpenSSH
has seen an update.

The build appears to pick up libssh.a from DESTDIR, and not from
OBJDIR -- running the failing command with "-Wl,--verbose=1"
reveals among other things:

attempt to open /u/build/HEAD/dest/virt68k/lib/libssh.a failed
attempt to open /u/build/HEAD/dest/virt68k/usr/lib/libssh.a succeeded
/u/build/HEAD/dest/virt68k/usr/lib/libssh.a
(/u/build/HEAD/dest/virt68k/usr/lib/libssh.a)fmt_scaled.o
(/u/build/HEAD/dest/virt68k/usr/lib/libssh.a)ttymodes.o
(/u/build/HEAD/dest/virt68k/usr/lib/libssh.a)ssh-pkcs11.o
(/u/build/HEAD/dest/virt68k/usr/lib/libssh.a)readpass.o
...

However, at this point in the build, the libssh.a in DESTDIR is
the one from the previous build, i.e. the new version has not yet
been installed, so the ssh_packet_set_qos() which should come
from packet.o in that library is not found, and therefore left as
undefined.  Most probably the same goes for the other references.

The workaround?  I suspect that removing the DESTDIR for this
target will fix the issue.

However, I'm left questioning whether the rescue build should
prefer old DESTDIR files instead of prefering the OBJDIR
instances -- I suspect it should not.

However, exactly how to get that to happen I have not yet figured
out, but perhaps someone more familiar with the build setup can
chime in?

For now I'm going to try my workaround.

Regards,

- Håvard


Home | Main Index | Thread Index | Old Index