Build on Illumos and Solaris
Dropbear didn't build on Illumos and Solaris for a few reasons:
-
mv is not the coreutils one, so the
-voption doesn't exist. However, the gnu coreutils are shipped under/usr/gnu/binso we can just change which mv to use on Illumos or Solaris to/usr/gnu/bin/mv, if not on Solaris or Illumos it will default tomv; -
we need to set STDC_WANT_LIB_EXT1 to 1 to use memory safe functions, so I added a definition for Solaris, defined to 1 if we are on Solaris/Illumos and a check in dbhelper.h to define STDC_WANT_LIB_EXT1 to 1 if we are on Solaris and then we can use memset_s;
-
there is no lastlog file on Solaris/Illumos;
-
linking fails only on Solaris because we need to link with libssp (
-lssp) to use__stack_chk_guardand__stack_chk_fail, linking with libssp on Illumos doesn't seem to add problems.
With all those little fixes, Dropbear now works on Illumos and Solaris. I tested those fixes on OmniOS r151054 (latest LTS), SmartOS 20250710T000436Z (latest release), on Solaris 11.4 and also on Void Linux with glibc to see if didn't obliterate something. However while working on that, I did not pay attention to the version of autoconf installed of my system, it was 2.72, so I rolled back to 2.71 to generate a new configure script, as it was before.
I'll investigate checks later today, at first glance it doesn't seem too weird. Checks also don't work on solaris and illumos because calling make in the Makefile calls dmake (sun make). Should add something to specify gmake if we are on solaris.
I'll investigate checks later today, at first glance it doesn't seem too weird.
Don't bother about it - it's a spurious failure I've been meaning to track down.
Checks also don't work on solaris and illumos because calling make in the Makefile calls dmake (sun make). Should add something to specify gmake if we are on solaris.
Ah, I'll see how easy it is to make more portable.
Checks also don't work on solaris and illumos because calling make in the Makefile calls dmake (sun make). Should add something to specify gmake if we are on solaris.
Hopefully it's a bit better in https://github.com/mkj/dropbear/commit/beb0616d21539c3eb024e30a76d370392f205620
There are still a few problems related to tests with some python libraries, I'll see what's possible to be done there. In the meantime, it looks good.