Re: HEADSUP: drm-current-kmod now installs sources

John Baldwin <[email protected]>
Newsgroups gmane.os.freebsd.devel.x11
Message-ID <[email protected]>
On 8/14/19 1:19 PM, Ian Lepore wrote:
> On Wed, 2019-08-14 at 13:59 -0600, Warner Losh wrote:
>> On Wed, Aug 14, 2019 at 1:56 PM Ian Lepore <[email protected]> wrote:
>>
>>> On Wed, 2019-08-14 at 12:00 -0700, John Baldwin wrote:
>>>> On 8/14/19 11:06 AM, Kyle Evans wrote:
>>>>> LOCAL_MODULES="" does seem like a sensible default when we're
>>>>> not
>>>>> building a native kernel.
>>>>
>>>> Unfortunately kern.post.mk has no way of knowing that as
>>>> MACHINE_*
>>>> are already set to the TARGET_* values by the time this target is
>>>> invoked.  Also, the 'make tinderbox' use case is a legit use case
>>>> that some folks want (for CI, etc.)
>>>>
>>>
>>> BUILDHOST_ARCH!= uname -p
>>> .if ${BUILDHOST_ARCH} != ${TARGET_ARCH}
>>>
>>> Unfortunately, I don't think it's as easy to compare the buildhost
>>> running version with the version of source being built, unless the
>>> build is started from the top level so that Makefile.inc1 sets the
>>> variables.
>>>
>>
>> We already know MACHINE_ARCH != TARGET_ARCH in Makefile.inc1 and
>> already do
>> different things based on it. But to be honest, I'd think there'd be
>> times
>> I'd absolutely want to build them all, and other times I wouldn't
>> which
>> strongly suggests some kind of knob specific for cross building the
>> port/pkg-based kernel modules. We could then pass that knob into the
>> kernel
>> builds which would then not try to guess whether or not to build
>> LOCAL_MODULES...
>>
>>
> 
> This is just about AUTOMATICALLY deciding to build something, based on
> the presence of source code in an arbitrary fixed location outside of
> the source tree on the build machine.  Anything set by the user should
> be honored without question, including LOCAL_MODULES.  
> 
> My point is only that the build machinery should not be deciding to
> build something the user didn't specify based on the existence of out-
> of-tree files on the build machine (I'd like to put the period right
> here in this sentence), unless there's a very high likelyhood that the
> build being done is for the build machine.
> 
> Things like CI that want to include more than in-tree sources as part
> of the build should be handling that by setting appropriate knobs as
> part of invoking the build.

I talked with Warner some offline and I think having some knob that
controls whether or not LOCAL_MODULES auto-populates and having make
buildkernel default it to on/off for native/cross builds (but it can
always be forcefully set on the command line) is fine with me.

-- 
John Baldwin
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-x11
To unsubscribe, send any mail to "[email protected]"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.