diff options
author | Brian Feldman <green@FreeBSD.org> | 1999-11-20 03:05:31 +0000 |
---|---|---|
committer | Brian Feldman <green@FreeBSD.org> | 1999-11-20 03:05:31 +0000 |
commit | c2edf69286d82baf566cccf05838dbafb0811837 (patch) | |
tree | 6cdfc2031ba93f47f658458f1483cd3c06f3dd27 | |
parent | 5d725fe00c8de8a2ee9ce36283f52c25197808f2 (diff) | |
download | freebsd-ports-c2edf69286d82baf566cccf05838dbafb0811837.zip |
Turn on HAVE_OPENPTY so more than 16 terminals work with sshd.
Put sshd.sh installation in the pre-install, ssh_host_key generation
back in the PLIST, and check for ssh_config, too. This port now
works much better as a package. The configuration files and sshd.sh
are also part of the package, and as such removed on deinstall.
The proper upgrade procedure from one OpenSSH version to a newer one is:
chflags schg /usr/local/etc/ssh* # preserve them from deletion
cd /usr/ports/security/openssh
make all deinstall reinstall clean
Partially submitted by: peter
-rw-r--r-- | security/openssh/Makefile | 13 | ||||
-rw-r--r-- | security/openssh/pkg-plist | 4 |
2 files changed, 8 insertions, 9 deletions
diff --git a/security/openssh/Makefile b/security/openssh/Makefile index 7f4690b4b602..3b05a587cffc 100644 --- a/security/openssh/Makefile +++ b/security/openssh/Makefile @@ -21,6 +21,7 @@ RESTRICTED= "Links with cryptographic code." CAT?= /bin/cat DISTFILES!= ${CAT} ${FILESDIR}/distfiles +CFLAGS+= -DHAVE_OPENPTY CVS_CMD?= cvs -z3 CVS_DATE= Fri Nov 19 20:25:38 EST 1999 CVS_SITES= anoncvs@anoncvs1.ca.openbsd.org:/cvs \ @@ -83,15 +84,14 @@ post-patch: ${WRKSRC}/*.[ch] pre-install: - @if [ ! -f ${PREFIX}/etc/sshd_config ]; then \ + @if [ ! -f ${PREFIX}/etc/ssh_config -a \ + ! -f ${PREFIX}/etc/sshd_config ]; then \ cd ${WRKSRC} && ${MAKE} DESTDIR=${PREFIX} distribution; \ else \ - ${ECHO_MSG} ">> ${PREFIX}/etc/sshd_config exists, not being replaced!"; \ + ${ECHO_MSG} ">> ${PREFIX}/etc/ssh{,d}_config exists, not being replaced!"; \ ${ECHO_MSG} ">> If this is left over from another version of SSH, you will"; \ ${ECHO_MSG} ">> need to update it to work with OpenSSH."; \ fi - -post-install: @if [ ! -f ${PREFIX}/etc/rc.d/sshd.sh ]; then \ ${ECHO_MSG} ">> Installing ${PREFIX}/etc/rc.d/sshd.sh startup file."; \ ${MKDIR} ${PREFIX}/etc/rc.d; \ @@ -100,10 +100,5 @@ post-install: ${PERL} -pi -e 's:__PREFIX__:${PREFIX}:g' \ ${PREFIX}/etc/rc.d/sshd.sh; \ fi - @if [ ! -f ${PREFIX}/etc/ssh_host_key ]; then \ - ${ECHO_MSG} "Generating a secret host key..."; \ - ${PREFIX}/bin/ssh-keygen -N "" -f ${PREFIX}/etc/ssh_host_key; \ - fi - .include <bsd.port.mk> diff --git a/security/openssh/pkg-plist b/security/openssh/pkg-plist index e7a874dc1d0b..5f2fb2c24945 100644 --- a/security/openssh/pkg-plist +++ b/security/openssh/pkg-plist @@ -4,6 +4,9 @@ bin/ssh bin/ssh-add bin/ssh-agent bin/ssh-keygen +etc/rc.d/sshd.sh +etc/ssh_config +etc/sshd_config man/man1/scp.1.gz man/man1/slogin.1.gz man/man1/ssh-add.1.gz @@ -12,3 +15,4 @@ man/man1/ssh-keygen.1.gz man/man1/ssh.1.gz man/man8/sshd.8.gz sbin/sshd +@exec if [ ! -f %D/etc/ssh_host_key ]; then echo ">> Generating a secret host key."; %D/bin/ssh-keygen -N "" -f %D/etc/ssh_host_key; fi |