Subject: pkg/14215: Setting WRKOBJDIR to nonstandard location breaks builds
To: None <gnats-bugs@gnats.netbsd.org>
From: None <richards+bsd@CS.Princeton.EDU>
List: netbsd-bugs
Date: 10/10/2001 14:00:00
>Number:         14215
>Category:       pkg
>Synopsis:       Setting WRKOBJDIR to nonstandard location breaks builds
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Oct 10 14:01:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Chris Richards
>Release:        NetBSD 1.5.2; pkgsrc as of 2001-10-10
>Organization:
>Environment:
NetBSD wubba.cs.princeton.edu 1.5.2 NetBSD 1.5.2 (WUBBA) #2: Sat Sep 15 22:56:25 EDT 2001     richards@wubba.cs.princeton.edu:/usr/src/sys/arch/i386/compile/WUBBA i386

>Description:
Setting WRKOBJDIR to a value other than ${PKGSRCDIR} results in broken builds.  I suspect this has something to do with the injudicious use of ${.CURDIR} to find various ".mk" files in the "mk" directory.
>How-To-Repeat:
Set WRKOBJDIR to, say, /usr/obj/${PKGSRCDIR}.  Attempting a build (procmail in this example) results in the following error messages:

===> Building for procmail-3.21
"/usr/pkgsrc/mail/procmail/../../mk/bsd.prefs.mk", line 160: Could not find /usr/obj/usr/pkgsrc/mail/procmail/work/procmail-3.21/mk/defs.NetBSD.mk
"/usr/pkgsrc/mail/procmail/../../mk/bsd.pkg.mk", line 21: Could not find ../../mk/bsd.prefs.mk
Fatal errors encountered -- cannot continue

>Fix:
I haven't tried it, but it might work to refer to the "mk" directory by specifying "${PKGSRCDIR}/mk".
>Release-Note:
>Audit-Trail:
>Unformatted: