Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 8 Oct 2012 21:56:14 GMT
From:      Rob <pr@somerandom.net>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/172547: bsd.destdir.mk fails when DESTDIR is set
Message-ID:  <201210082156.q98LuEAh011995@red.freebsd.org>
Resent-Message-ID: <201210092230.q99MUPCt043667@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         172547
>Category:       ports
>Synopsis:       bsd.destdir.mk fails when DESTDIR is set
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 09 22:30:24 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Rob
>Release:        CURRENT r241195
>Organization:
>Environment:
FreeBSD xs36v 10.0-CURRENT FreeBSD 10.0-CURRENT #3 r241195: Fri Oct  5 23:09:26 UTC 2012     root@nfsboot:/usr/obj/usr/src/sys/CUSTOM.shuttle  amd64

>Description:
When bsd.destdir.mk iterates over $_DESTDIR_MOUNT_LIST it runs:

# realpath $_destdir/__temp__

Due to changes in realpath (prior to June 2012) this causes a non-zero exit.  This then causes the make to fail.

>How-To-Repeat:
On a freshly built installation, attempt to perform a 

# make config DESTDIR=/usr/local/jails/imap1
===>  Creating some important subdirectories
realpath: /usr/local/jails/imap1/___temp___: No such file or directory
*** [do-chroot] Error code 1

>Fix:
Change /usr/ports/Mk/bsd.destdir.mk

_full_dest_path=`${REALPATH} $${_destdir}/$${_dest_path}`; \

to:

_full_dest_path=`${REALPATH} -q $${_destdir}/$${_dest_path} || :`; \


This may not be the proper fix, but it works around the issue.

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201210082156.q98LuEAh011995>