From owner-freebsd-ports Thu Jun 17 23:40: 4 1999 Delivered-To: freebsd-ports@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 6795614F23 for ; Thu, 17 Jun 1999 23:40:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id XAA49364; Thu, 17 Jun 1999 23:40:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from mx.issei.org (mx.issei.org [210.169.187.134]) by hub.freebsd.org (Postfix) with ESMTP id 572A014E2F for ; Thu, 17 Jun 1999 23:35:31 -0700 (PDT) (envelope-from issei@jp.FreeBSD.ORG) Received: from localhost (localhost [127.0.0.1]) by mx.issei.org (Postfix) with ESMTP id 1BD211F45 for ; Fri, 18 Jun 1999 15:35:27 +0900 (JST) Message-Id: <19990618153328C.issei@issei.org> Date: Fri, 18 Jun 1999 15:33:28 +0900 From: issei@jp.FreeBSD.ORG Reply-To: issei@jp.FreeBSD.ORG To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: ports/12269: Fix port : security/ssh : Cannot build security/ssh port on old FreeBSD Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 12269 >Category: ports >Synopsis: Fix building problem of security/ssh port on old FreeBSD. >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Jun 17 23:40:01 PDT 1999 >Closed-Date: >Last-Modified: >Originator: Issei Suzuki >Release: FreeBSD 3.2-STABLE i386 >Organization: Personal >Environment: >Description: You cannot build security/ssh port on old FreeBSD (before 3.2-RELEASE) because old FreeBSD does not have trimdomain() function that pateches/patch-a[wo] uses. I know ports-current only supports FreeBSD-stable and FreeBSD-current, but supporting old FreeBSDs is good idea if possible. >How-To-Repeat: Try to build current security/ssh port on FreeBSD 2.2.8-RELEASE. >Fix: Apply the following patch to the ports-current. This patch affects nothing when you build security/ssh port on FreeBSD-stable or FreeBSD-current. diff -urN ssh.old/patches/patch-ao ssh/patches/patch-ao --- ssh.old/patches/patch-ao Fri Jun 18 15:11:43 1999 +++ ssh/patches/patch-ao Fri Jun 18 15:13:35 1999 @@ -1,5 +1,5 @@ --- newchannels.c.orig Wed May 12 20:19:27 1999 -+++ newchannels.c Sun Jun 6 01:49:22 1999 ++++ newchannels.c Fri Jun 18 15:13:21 1999 @@ -282,6 +282,10 @@ #endif /* NEED_SYS_SYSLOG_H */ #endif /* LIBWRAP */ @@ -15,7 +15,7 @@ fatal("gethostname: %.100s", strerror(errno)); snprintf(buf, sizeof(buf), "%.400s:%d.%d", hostname, display_number, screen_number); -+#ifdef __FreeBSD__ ++#ifdef __FreeBSD_version >= 320000 + trimdomain(buf, UT_HOSTSIZE); +#endif #else /* HAVE_GETHOSTNAME */ diff -urN ssh.old/patches/patch-aw ssh/patches/patch-aw --- ssh.old/patches/patch-aw Fri Jun 18 15:11:43 1999 +++ ssh/patches/patch-aw Fri Jun 18 15:15:04 1999 @@ -1,12 +1,14 @@ --- login.c.orig Wed May 12 20:19:26 1999 -+++ login.c Sun Jun 6 01:51:33 1999 -@@ -301,12 +301,13 @@ ++++ login.c Fri Jun 18 15:14:49 1999 +@@ -301,12 +301,15 @@ strncpy(u.ut_user, user, sizeof(u.ut_user)); #endif /* HAVE_NAME_IN_UTMP */ #ifdef HAVE_HOST_IN_UTMP - strncpy(u.ut_host, host, sizeof(u.ut_host)); #ifdef __FreeBSD__ ++#if __FreeBSD_version >= 320000 + trimdomain(host, sizeof u.ut_host); ++#endif if (strlen(host) > sizeof(u.ut_host)) { strncpy(u.ut_host, get_remote_ipaddr(), sizeof(u.ut_host)); - } >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message