Bug 40047

Summary: "make release" fails in games/adventure (yesterday's RELENG_4)
Product: Base System Reporter: Trevor Johnson <trevor>
Component: binAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Unspecified   
Hardware: Any   
OS: Any   

Description Trevor Johnson freebsd_committer freebsd_triage 2002-06-30 22:40:02 UTC
"make release" fails with:

===> games/adventure
install -c -s -o root -g games -m 550   adventure /usr/games/hide
(cd /usr/games; ln -fs dm adventure;  chown -h root:games adventure)
/usr/libexec/ld-elf.so.1: Shared object "libc.so.4" not found
*** Error code 1

Stop in /usr/src/games/adventure.
*** Error code 1

A build log is at http://people.freebsd.org/~trevor/release.log.bz2

How-To-Repeat: cd /usr
rm -r obj ports src
mkdir obj
cvs -R co -P -r RELENG_4 src
cvs -R co -P ports
cd src
time make buildworld && cd release && time make release \
CHROOTDIR=/scratch/release BUILDNAME=4.6-20020629-STABLE \
CVSROOT=/home/ncvs
Comment 1 dschultz 2002-07-05 13:54:39 UTC
The following patch should fix the problem.  The compat libraries
are installed in /usr/lib/compat, but they were being cleaned from
/usr/lib.

--- src/lib/compat/Makefile.inc 2002/04/18 06:46:34     1.9
+++ src/lib/compat/Makefile.inc 2002/07/05 12:52:18
@@ -7,9 +7,9 @@
 beforeinstall: __remove-stale-libs
 __remove-stale-libs: .PHONY
 .for lib in ${LIBS}
-.if exists(${DESTDIR}${SHLIBDIR}/${lib})
-       -chflags noschg ${DESTDIR}${SHLIBDIR}/${lib}
-       rm -f ${DESTDIR}${SHLIBDIR}/${lib}
+.if exists(${DESTDIR}${LIBCOMPATDIR}/${lib})
+       -chflags noschg ${DESTDIR}${LIBCOMPATDIR}/${lib}
+       rm -f ${DESTDIR}${LIBCOMPATDIR}/${lib}
 .endif
 .endfor
 .endif
Comment 2 ru freebsd_committer freebsd_triage 2002-07-05 15:37:06 UTC
[Sorry for crossposting to re@, but this seemed reasonable.]

On Fri, Jul 05, 2002 at 06:00:07AM -0700, David Schultz wrote:
> The following reply was made to PR bin/40047; it has been noted by GNATS.
> 
> From: David Schultz <dschultz@uclink.Berkeley.EDU>
> To: freebsd-gnats-submit@FreeBSD.org, trevor@FreeBSD.org
> Cc:  
> Subject: Re: bin/40047: "make release" fails in games/adventure (yesterday's RELENG_4)
> Date: Fri, 5 Jul 2002 05:54:39 -0700
> 
>  The following patch should fix the problem.  The compat libraries
>  are installed in /usr/lib/compat, but they were being cleaned from
>  /usr/lib.
>  
>  --- src/lib/compat/Makefile.inc 2002/04/18 06:46:34     1.9
>  +++ src/lib/compat/Makefile.inc 2002/07/05 12:52:18
>  @@ -7,9 +7,9 @@
>   beforeinstall: __remove-stale-libs
>   __remove-stale-libs: .PHONY
>   .for lib in ${LIBS}
>  -.if exists(${DESTDIR}${SHLIBDIR}/${lib})
>  -       -chflags noschg ${DESTDIR}${SHLIBDIR}/${lib}
>  -       rm -f ${DESTDIR}${SHLIBDIR}/${lib}
>  +.if exists(${DESTDIR}${LIBCOMPATDIR}/${lib})
>  +       -chflags noschg ${DESTDIR}${LIBCOMPATDIR}/${lib}
>  +       rm -f ${DESTDIR}${LIBCOMPATDIR}/${lib}
>   .endif
>   .endfor
>   .endif
> 
No, this patch is incorrect.  When installing compat libs, their
old copies from /usr/lib should be deleted.  This is what this
code already does.

As for the problem, Trevor was attempting to build the 5.0-CURRENT
snapshot on a 4.x box in an unsupported way (using the RELENG_4's
release/Makefile), as could be seen from How-To-Repeat section or
looking at the build logs.  To build the 4.x snapshot, one needs
to supply the RELEASETAG=RELENG_4 as documented in the release(7)
manpage.  To build the 5.0-CURRENT snapshot on a 4.x box, one needs
to:

cd /usr/src-4.x/release; make -f /usr/src-5.0/release/Makefile ...

OTOH, it would probably be a good idea to make RELEASETAG default
to RELENG_4 on RELENG_4, and default to RELENG_4_6 on RELENG_4_6,
similar to how this is done in Makefile.inc1's update: target.

(Someone from re@ needs to fix the Makefile.inc1 on RELENG_4_6
to track the RELENG_4_6, like in RELENG_4_4 and RELENG_4_5.)


Cheers,
-- 
Ruslan Ermilov		Sysadmin and DBA,
ru@sunbay.com		Sunbay Software AG,
ru@FreeBSD.org		FreeBSD committer,
+380.652.512.251	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age
Comment 3 Johan Karlsson freebsd_committer freebsd_triage 2002-08-20 18:57:45 UTC
State Changed
From-To: open->closed

According to the audit-trail this was a user error. 

Ruslans suggested change for the RELENG_4_6 branch 
has also been committed.