buildkernel broken for META_MODE

Bryan Drewery bdrewery at FreeBSD.org
Tue Apr 18 23:05:36 UTC 2017


On 4/18/2017 3:26 PM, Simon J. Gerraty wrote:
>>> [Creating objdir /usr/obj/usr/obj/root/git/freebsd/sys/GENERIC...]
>> Wrong^
>>
>> Note we have 'cd /usr/obj/....' and 'MAKEOBJDIRPREFIX=/usr/obj' in
>> there, so we get a nested /usr/obj/.CURDIR problem of /usr/obj/usr/obj.
> 
> The following would probably help that case:
> 
> Index: auto.obj.mk
> ===================================================================
> RCS file: /volume/cvs/sjg/mk/auto.obj.mk,v
> retrieving revision 1.13
> diff -u -p -r1.13 auto.obj.mk
> --- auto.obj.mk	24 Mar 2017 20:53:22 -0000	1.13
> +++ auto.obj.mk	18 Apr 2017 22:25:08 -0000
> @@ -41,6 +41,10 @@ MKOBJDIRS= auto
>  # Use __objdir here so it is easier to tweak without impacting
>  # the logic.
>  .if !empty(MAKEOBJDIRPREFIX)
> +.if ${.CURDIR:M${MAKEOBJDIRPREFIX}/*} != ""
> +# we are already in obj tree!
> +__objdir?= ${.CURDIR}
> +.endif
>  __objdir?= ${MAKEOBJDIRPREFIX}${.CURDIR}
>  .endif
>  __objdir?= ${MAKEOBJDIR:Uobj}
> 

Yes this looks right and fixes buildkernel completely.

-- 
Regards,
Bryan Drewery

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-current/attachments/20170418/e041a538/attachment.sig>


More information about the freebsd-current mailing list