From nobody@FreeBSD.org  Mon Nov 12 07:28:37 2001
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id A320537B405
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 12 Nov 2001 07:28:37 -0800 (PST)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.4/8.11.4) id fACFSbr99393;
	Mon, 12 Nov 2001 07:28:37 -0800 (PST)
	(envelope-from nobody)
Message-Id: <200111121528.fACFSbr99393@freefall.freebsd.org>
Date: Mon, 12 Nov 2001 07:28:37 -0800 (PST)
From: "Alexander S. Usov" <usov@ukr.net>
To: freebsd-gnats-submit@FreeBSD.org
Subject: A small bug in "make update". cvsup binary not found.
X-Send-Pr-Version: www-1.0

>Number:         31932
>Category:       conf
>Synopsis:       A small bug in "make update". cvsup binary not found.
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    matusita
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Nov 12 07:30:00 PST 2001
>Closed-Date:    Wed Nov 14 04:46:48 PST 2001
>Last-Modified:  Wed Nov 14 06:00:01 PST 2001
>Originator:     Alexander S. Usov
>Release:        FreeBSD 4.4-SRABLE
>Organization:
ITV
>Environment:
FreeBSD darkini.itv 4.4-RC FreeBSD 4.4-RC #1: Thu Nov  1 17:12:36 EET 2001 root@darkini.itv:/usr/src/sys/compile/DARKINI i386
>Description:
When trying to run "make update" in /usr/src all I got is:
cvsup:No such file or directory

The same bug is present in latest STABLE cvs snapshot too. (I do not build it yet).
>How-To-Repeat:
cd /usr/src
make update

>Fix:
Here is a diff. I understand That it is broken, but the idea is simple :)

--- Makefile.inc1       Thu Oct 11 18:10:34 2001
+++ Makefile.inc1.new   Mon Nov 12 17:30:27 2001
@@ -113,7 +113,7 @@
 CLEANDIR=      cleandir
 .endif
 
-SUP?=          cvsup
+SUP?=          /usr/local/bin/cvsup
 SUPFLAGS?=     -g -L 2 -P -
 .if defined(SUPHOST)
 SUPFLAGS+=     -h ${SUPHOST}

>Release-Note:
>Audit-Trail:

From: Makoto Matsushita <matusita@jp.freebsd.org>
To: usov@ukr.net
Cc: freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: conf/31932: A small bug in "make update". cvsup binary not
 found.
Date: Tue, 13 Nov 2001 13:36:31 +0900

 usov> -SUP?=          cvsup
 usov> +SUP?=          /usr/local/bin/cvsup
 
 If it works, your PATH environment variable apparantly doesn't have
 '/usr/local/bin'.  We may respect ${LOCALBASE} in ports makefiles, but
 "setting up $PATH before make update" is more simple solution.
 
 Would you please try following commands:
 
 	cd /usr/src
 	env PATH=/sbin:/bin:usr/sbin:/usr/bin:/usr/local/bin make update
 
 If it works for you, you don't need to modify Makefile.  Set your PATH
 will help you.
 
 BTW, what's your (root's) shell?  /root/.cshrc and /root/.profile does
 contain /usr/local/bin in PATH definition.  I wonder why your shell
 does NOT include /usr/local/bin...
 
 -- -
 Makoto `MAR' Matsushita
State-Changed-From-To: open->feedback 
State-Changed-By: matusita 
State-Changed-When: Mon Nov 12 20:42:26 PST 2001 
State-Changed-Why:  
It seems that PATH is not set collectly. I want to get a feedback 
from the original submitter what's happen if PATH is explicitly set. 


Responsible-Changed-From-To: freebsd-bugs->matusita 
Responsible-Changed-By: matusita 
Responsible-Changed-When: Mon Nov 12 20:42:26 PST 2001 
Responsible-Changed-Why:  
I'll handle this. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=31932 

From: Makoto Matsushita <matusita@jp.freebsd.org>
To: usov@ukr.net, freebsd-gnats-submit@FreeBSD.ORG
Cc:  
Subject: Re: conf/31932: A small bug in "make update". cvsup binary not
 found.
Date: Wed, 14 Nov 2001 00:58:50 +0900

 matusita> If it works, your PATH environment variable apparantly
 matusita> doesn't have '/usr/local/bin'.  We may respect ${LOCALBASE}
 matusita> in ports makefiles, but "setting up $PATH before make
 matusita> update" is more simple solution.
 
 As you said in your private email, it doesn't work since PATH is
 explicitly set in src/Makefile.  Users cannot overwrite PATH, so all
 you can do is to define 'SUP' variable to your cvsup path.
 
 So, you'll be happy with "make update SUP=/usr/local/bin/cvsup".
 
 However, most users install cvsup /usr/local/bin via ports/net/cvsup
 or ports/net/cvsup-devel.  I think there is no reason to stick
 SUP to 'cvsup'.  Note that "make update" without specifying SUP works
 before the change of src/Makefile rev 1.232 was made.
 
 I've changed src/Makefile.inc1 as you said.  If it works fine and
 doesn't hurt anything,  I close this PR, OK?
 
 -- -
 Makoto `MAR' Matsushita
State-Changed-From-To: feedback->closed 
State-Changed-By: matusita 
State-Changed-When: Wed Nov 14 04:46:48 PST 2001 
State-Changed-Why:  
Set 'cvsup' full-path in src/Makefile.inc1. 
Both 5-current and 4-stable are fixed (rev 1.223 and 1.141.2.35 respectively). 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=31932 

From: "Alexander S. Usov" <usov@ukr.net>
To: freebsd-gnats-submit@FreeBSD.ORG
Cc:  
Subject: Re: conf/31932: A small bug in "make update". cvsup binary not found.
Date: Wed, 14 Nov 2001 15:56:11 +0200

 Hello Makoto,
 
 Tuesday, November 13, 2001, 6:36:31 AM, you wrote:
 
 MM> Would you please try following commands:
 
 MM>         cd /usr/src
 MM>         env PATH=/sbin:/bin:usr/sbin:/usr/bin:/usr/local/bin make update
 
 MM> If it works for you, you don't need to modify Makefile.  Set your PATH
 MM> will help you.
 
 I did that. All I go is:
 cvsup:No such file or directory
 *** Error code 1
 
 Stop in /usr/src.
 *** Error code 1
 
 Stop in /usr/src.
 
 MM> BTW, what's your (root's) shell?  /root/.cshrc and /root/.profile does
 MM> contain /usr/local/bin in PATH definition.  I wonder why your shell
 MM> does NOT include /usr/local/bin...
 
 root's shell is /bin/sh.
 PATH is set in /usr/src/Makefile
 
 MM> -- -
 MM> Makoto `MAR' Matsushita
 
 There is one more path:
 --- Makefile    Thu Jul 12 20:07:33 2001
 +++ Makefile.new   Tue Nov 13 13:57:23 2001
 @@ -90,7 +90,7 @@
         maninstall mk most obj objlink regress reinstallkernel rerelease \
         tags update
  
 -PATH=  /sbin:/bin:/usr/sbin:/usr/bin
 +PATH=  /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin
  MAKE=  PATH=${PATH} make -m ${.CURDIR}/share/mk -f Makefile.inc1
 
  
 -- 
 Best regards,
  Alexander                            mailto:usov@ukr.net
 
>Unformatted:
