Build failed: /usr/src/share/mk/bsd.obj.mk" line 89: Malformed conditional
David Wolfskill
david at catwhisker.org
Sun Nov 5 16:25:51 UTC 2017
On Sun, Nov 05, 2017 at 08:13:27AM -0800, Simon J. Gerraty wrote:
> Simon J. Gerraty <sjg at juniper.net> wrote:
> ...
> > I think I might have a fix for that.
>
> Or rather I know what the issue is - RELDIR isn't defined because
> .CURDIR isn't under SRCTOP,
> if OBJTOP were defined at that point, the fix is trivial, but
> in the current tree that may not be so.
> If .CURDIR isn't under SRCTOP, RELDIR is of questionable value anyway.
>
> For now you can avoid the error with below.
>
> Index: share/mk/bsd.obj.mk
> ===================================================================
> --- share/mk/bsd.obj.mk (revision 325436)
> +++ share/mk/bsd.obj.mk (working copy)
> @@ -85,7 +85,7 @@
> CANONICALOBJDIR:=/usr/obj${.CURDIR}
> .endif
>
> -.if defined(SRCTOP) && \
> +.if defined(RELDIR) && \
> (${CANONICALOBJDIR} == /${RELDIR} || ${.OBJDIR} == /${RELDIR})
> .error .OBJDIR incorrectly set to /${RELDIR}
> .endif
>
I had checked the svn-head before I saw the above, and noted bdrewery@'s
mention of:
Index: share/mk/bsd.obj.mk
===================================================================
--- share/mk/bsd.obj.mk (revision 325433)
+++ share/mk/bsd.obj.mk (working copy)
@@ -85,7 +85,7 @@
CANONICALOBJDIR:=/usr/obj${.CURDIR}
.endif
-.if defined(SRCTOP) && \
+.if defined(SRCTOP) && defined(RELDIR) && \
(${CANONICALOBJDIR} == /${RELDIR} || ${.OBJDIR} == /${RELDIR})
.error .OBJDIR incorrectly set to /${RELDIR}
.endif
which I just tried, and that got through the issue:
FreeBSD g1-252.catwhisker.org 12.0-CURRENT FreeBSD 12.0-CURRENT #3 r325433M/325433:1200052: Sun Nov 5 04:27:43 PST 2017 root at g1-252.catwhisker.org:/common/S4/obj/usr/src/amd64.amd64/sys/CANARY amd64
Peace,
david
--
David H. Wolfskill david at catwhisker.org
Unsubstantiated claims of "Fake News" are evidence that the claimant lies again.
See http://www.catwhisker.org/~david/publickey.gpg for my public key.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 603 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-current/attachments/20171105/df88f8c4/attachment.sig>
More information about the freebsd-current
mailing list