View | Details | Raw Unified | Return to bug 2641 | Differences between
and this patch

Collapse All | Expand All

(-)a/configure.ac (+25 lines)
Lines 4265-4270 AC_ARG_WITH([kerberos5], Link Here
4265
AC_SUBST([GSSLIBS])
4265
AC_SUBST([GSSLIBS])
4266
AC_SUBST([K5LIBS])
4266
AC_SUBST([K5LIBS])
4267
4267
4268
# Check whether user wants systemd support
4269
SYSTEMD_MSG="no"
4270
AC_ARG_WITH(systemd,
4271
	[  --with-systemd          Enable systemd support],
4272
	[ if test "x$withval" != "xno" ; then
4273
		AC_PATH_TOOL([PKGCONFIG], [pkg-config], [no])
4274
		if test "$PKGCONFIG" != "no"; then
4275
			AC_MSG_CHECKING([for libsystemd])
4276
			if $PKGCONFIG --exists libsystemd; then
4277
				SYSTEMD_CFLAGS=`$PKGCONFIG --cflags libsystemd`
4278
				SYSTEMD_LIBS=`$PKGCONFIG --libs libsystemd`
4279
				CPPFLAGS="$CPPFLAGS $SYSTEMD_CFLAGS"
4280
				SSHDLIBS="$SSHDLIBS $SYSTEMD_LIBS"
4281
				AC_MSG_RESULT([yes])
4282
				AC_DEFINE(HAVE_SYSTEMD, 1, [Define if you want systemd support.])
4283
				SYSTEMD_MSG="yes"
4284
			else
4285
				AC_MSG_RESULT([no])
4286
			fi
4287
		fi
4288
	fi ]
4289
)
4290
4291
4268
# Looking for programs, paths and files
4292
# Looking for programs, paths and files
4269
4293
4270
PRIVSEP_PATH=/var/empty
4294
PRIVSEP_PATH=/var/empty
Lines 5097-5102 echo " libedit support: $LIBEDIT_MSG" Link Here
5097
echo "  Solaris process contract support: $SPC_MSG"
5121
echo "  Solaris process contract support: $SPC_MSG"
5098
echo "           Solaris project support: $SP_MSG"
5122
echo "           Solaris project support: $SP_MSG"
5099
echo "         Solaris privilege support: $SPP_MSG"
5123
echo "         Solaris privilege support: $SPP_MSG"
5124
echo "                   systemd support: $SYSTEMD_MSG"
5100
echo "       IP address in \$DISPLAY hack: $DISPLAY_HACK_MSG"
5125
echo "       IP address in \$DISPLAY hack: $DISPLAY_HACK_MSG"
5101
echo "           Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG"
5126
echo "           Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG"
5102
echo "                  BSD Auth support: $BSD_AUTH_MSG"
5127
echo "                  BSD Auth support: $BSD_AUTH_MSG"
(-)a/contrib/sshd.service (+16 lines)
Line 0 Link Here
1
[Unit]
2
Description=OpenSSH server daemon
3
Documentation=man:sshd(8) man:sshd_config(5)
4
After=network.target
5
6
[Service]
7
Type=notify
8
ExecStart=/usr/sbin/sshd -D $OPTIONS
9
ExecReload=/bin/kill -HUP $MAINPID
10
KillMode=process
11
Restart=on-failure
12
RestartPreventExitStatus=255
13
14
[Install]
15
WantedBy=multi-user.target
16
(-)a/sshd.c (+9 lines)
Lines 85-90 Link Here
85
#include <prot.h>
85
#include <prot.h>
86
#endif
86
#endif
87
87
88
#ifdef HAVE_SYSTEMD
89
#include <systemd/sd-daemon.h>
90
#endif
91
88
#include "xmalloc.h"
92
#include "xmalloc.h"
89
#include "ssh.h"
93
#include "ssh.h"
90
#include "ssh2.h"
94
#include "ssh2.h"
Lines 1888-1893 main(int ac, char **av) Link Here
1888
			}
1892
			}
1889
		}
1893
		}
1890
1894
1895
#ifdef HAVE_SYSTEMD
1896
		/* Signal systemd that we are ready to accept connections */
1897
		sd_notify(0, "READY=1");
1898
#endif
1899
1891
		/* Accept a connection and return in a forked child */
1900
		/* Accept a connection and return in a forked child */
1892
		server_accept_loop(&sock_in, &sock_out,
1901
		server_accept_loop(&sock_in, &sock_out,
1893
		    &newsock, config_s);
1902
		    &newsock, config_s);

Return to bug 2641