Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Oct 2019 15:16:26 -0600
From:      Ian Lepore <ian@freebsd.org>
To:        Alan Somers <asomers@freebsd.org>
Cc:        Mark Johnston <markj@freebsd.org>, src-committers <src-committers@freebsd.org>, svn-src-all <svn-src-all@freebsd.org>, svn-src-head <svn-src-head@freebsd.org>
Subject:   Re: svn commit: r352909 - in head: contrib/elftoolchain/nm usr.bin/nm
Message-ID:  <179d7a5e30169f4b51fe0123a173571605fb8f28.camel@freebsd.org>
In-Reply-To: <CAOtMX2g=pMBFKsLEDdZ42dG8%2BZ-9ObrO=Szg1JeP7c3Z0U_K3w@mail.gmail.com>
References:  <201909301728.x8UHS0QF070658@repo.freebsd.org> <CAOtMX2g_85vwwTTPyARtBNykL9Gkugstu4qhHurrkWZ4c0-%2BBw@mail.gmail.com> <20191017174801.GA6447@raichu> <CAOtMX2juqyedRt2o1zv3hRcz21A4cJpy8S1QfhVB6b0c6%2BEJmg@mail.gmail.com> <ec18fab647ae7e0a2b3585380e513811f5f8ff2b.camel@freebsd.org> <CAOtMX2g=pMBFKsLEDdZ42dG8%2BZ-9ObrO=Szg1JeP7c3Z0U_K3w@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 2019-10-17 at 13:05 -0600, Alan Somers wrote:
> On Thu, Oct 17, 2019 at 12:48 PM Ian Lepore <ian@freebsd.org> wrote:
> 
> > On Thu, 2019-10-17 at 12:17 -0600, Alan Somers wrote:
> > > There might be something wrong with my environment:
> > > /usr/include/libcasper.h is absent.  But still, shouldn't the
> > > build
> > > be
> > > using the version from the source tree, instead of from the
> > > environment?
> > > -Alan
> > > 
> > 
> > There should be copies of libcasper.h in your objdir:
> > 
> > obj/arm.armv7/tmp/legacy/usr/include/libcasper.h
> > obj/arm.armv7/tmp/usr/include/libcasper.h
> > 
> > -- Ian
> 
> 
> Uh, I found the problem.  I had WITHOUT_CASPER=1 in
> /etc/src.conf.  So the
> problem is that nm can't build without casper.  Perhaps the #include
> should
> be guarded, as it is in usr.bin/kdump/kdump.c.  But plenty of other
> programs, like usr.bin/tail and usr.bin/wc, don't have such
> guards.  And
> looking at lib/libcasper/libcasper/Makefile, it seems as though
> libcasper.h
> should be installed regardless.  So I still need to figure out why it
> wasn't installed on my system.
> 
> -Alan

It's probably because Makefile.inc1 contains:

.if ${MK_CASPER} != "no"
_lib_casper=	lib/libcasper
.endif

so WITHOUT_CASPER means that the libcasper dir isn't even visited when
prebuilding libs.  But you need to visit that dir so that it can
install the header file (but not the lib, because MK_CASPER will be
"no").  I think lib/libcasper just needs to be unconditionally listed
as one of the prebuild libs in Makefile.inc1.

-- Ian




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