Change the openssl-devel package to libssl-devel. Cygwin still has an
"obsolete" (essentially virtual) package for openssl-devel, but it
doesn't seem to work properly on Appveyor's Cygwin install.
Protobuf >= 3.6.0 requires C++11, which I added support for last year.
But when I did that, I requested strict ANSI C++ compatibility, which
causes Cygwin/newlib's libc feature test macros to be set to disable
(at least) POSIX.1 extensions. Let the Autoconf macro use its default
instead (prefer GNU/extended C++, accept anything).
Statically linking mosh-server with glibc isn’t a great idea for
various reasons (nsswitch modules, locale format incompatibilities).
But we can provide most of the benefits of static linking by allowing
specific library dependencies to be linked statically using -Bstatic
and -Bdynamic. The full set is enabled by
./configure --enable-static-libraries
which is equivalent to
./configure --enable-static-libstdc++ --enable-static-libgcc \
--enable-static-utempter --enable-static-zlib --enable-static-curses \
--enable-static-crypto --enable-static-protobuf
and results in binaries whose only runtime library dependencies are
provided with libc:
$ ldd src/frontend/mosh-server
linux-vdso.so.1 (0x00007ffe0b377000)
libutil.so.1 => /lib/x86_64-linux-gnu/libutil.so.1 (0x00007fa0d9970000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fa0d97e3000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fa0d97c2000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fa0d95d8000)
/lib64/ld-linux-x86-64.so.2 (0x00007fa0d9f6a000)
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
This shouldn't require C++11 when not required.
This hack may not always detect when C++11 *is* required,
in which case a little autoconf tweaking may be needed
to get a good compile.
Log connection change events to syslog in the auth log, logging the PID,
username and remote host.
Also log session begin and end.
Co-Authored-By: John Hood <cgull@glup.org>
These should output to stdout and exit with status 0. Passing
std-options to AM_INIT_AUTOMAKE causes ‘make installcheck’ (hence also
‘make distcheck’) to verify this.
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
There are (broken) compilers out there that accept -fstack-protector-*
parameters, but do not provide the needed ssp library. As a result,
build does not fail, but link does. Use the local check_link_flag
autoconf function to correctly test for SSP availability.
Required for the Imagination Technologies Codescape IMG MIPS
toolchain, version 2015.10 (and who knows what else).
Fixes#744.
protobuf uses an obsolete automake pthreads detection macro,
which results in "pkgconfig --libs protobuf" returning
"-lprotobuf -pthread -lpthread" on Linux. Remove
the unnecessary and dangerous -lpthread in that case.
Fixes#727, mosh-server crash in libutempter on Debian Sid.
This helps to catch inconsistent declarations in headers that weren’t
included, and local functions that are not marked static.
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Instead of looking for htobe64 which is be available both when
be64toh or betoh64 are, check for the latter functions. If we
find betoh64 but not be64toh, use compat #defines. If both
can't be found, search for OSX' OSSwapHostToBigInt64.
Also include sys/types.h in byteorder.h (which is necessary for
byteorder functions on OpenBSD), and incidentally fixes build
of networkfragment.cc.
Fixes build on OpenBSD
Signed-off-by: Jérémie Courrèges-Anglas <jca@wxcvbn.org>
There’s a bug in automake ≥ 1.10, < 1.12 where ‘-Wall foreign’
incorrectly turns off warnings about portability issues. To get
consistent results across automake versions, use ‘foreign -Wall’
instead.
http://debbugs.gnu.org/cgi-bin/bugreport.cgi?bug=7669
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Closes#413