Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-03-01 Thread Lucas Nali de Magalhães
> On Feb 28, 2019, at 7:40 PM, Warner Losh  wrote:
> 
> On Thu, Feb 28, 2019 at 10:00 AM Rodney W. Grimes <
> free...@pdx.rh.cn85.dnsmgr.net> wrote:
> 
> .if defined(KERNEL_LD_OVERRIDE)
> LD=${KERNEL_LD_OVERRIDE}
> .else
> LD=ld.lld
> .endif

My suggestion would be to test $LD == ld  and then use LD=ld.lld with a comment 
about the reason but my makefile syntax knowledge is limited.

Lc

-- 
rollingbits — 📧 rollingb...@gmail.com 📧 rollingb...@terra.com.br 📧 
rollingb...@yahoo.com 📧 rollingb...@globo.com 📧 rollingb...@icloud.com

___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
[ Charset UTF-8 unsupported, converting... ]
> On Thu, Feb 28, 2019 at 10:00 AM Rodney W. Grimes <
> free...@pdx.rh.cn85.dnsmgr.net> wrote:
> 
> > [ Charset UTF-8 unsupported, converting... ]
> > > On Thu, 28 Feb 2019 at 09:33, Rodney W. Grimes
> > >  wrote:
> > > >
> > > > LD?=ld.lld in the right place(s)?
> > >
> > > Perhaps, I seem to recall some issue with that, but not the specifics.
> >
> > sys.mk already does a LD?=ld so by the time we try
> > to override it in the Makefile.i386 it is too late
> > as already defined.
> >
> > *sigh*
> >
> 
> Yes, the problem is that ?= only works once. There's some gross things we
> can do, but they aren't worthwhile, imho.
> 
> eg
> 
> .if defined(KERNEL_LD_OVERRIDE)
> LD=${KERNEL_LD_OVERRIDE}
> .else
> LD=ld.lld
> .endif
> 
> or other variations on that. We could do it without the .else clause and
> just add KERNEL_LD_OVERRIDE=ld.lld to GENERIC on i386 as a build-time
> override. This would give people a way out, but would violate POLA a little
> bit. Given the frequency of overriding LD=, it may be OK. People
> sophisticated enough to do that surely are sophisticated enough to read
> changes to the kernel config files. This wouldn't help everybody
> (especially those with custom kernel configs), but short of adding it to
> DEFAULTS, it's likely pushing the edge of how disruptive one can be in a
> stable branch.
> 
> So there's a number of variations on this theme. I'm not convinced they are
> worthwhile for this issue because none are side-effect free, but it's
> certainly a solution space others can noodle through to see if they can
> find the "just so" mix of POLA and bug fixing.

I would be happy with expanding the error that is emitted by
pre.mk to add the text "You can fix this with LD=ld.lld make ..."
and an entry in UPDATING that specifically says for 12.0 on i386 you need...

> Warner
-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Warner Losh
On Thu, Feb 28, 2019 at 10:00 AM Rodney W. Grimes <
free...@pdx.rh.cn85.dnsmgr.net> wrote:

> [ Charset UTF-8 unsupported, converting... ]
> > On Thu, 28 Feb 2019 at 09:33, Rodney W. Grimes
> >  wrote:
> > >
> > > LD?=ld.lld in the right place(s)?
> >
> > Perhaps, I seem to recall some issue with that, but not the specifics.
>
> sys.mk already does a LD?=ld so by the time we try
> to override it in the Makefile.i386 it is too late
> as already defined.
>
> *sigh*
>

Yes, the problem is that ?= only works once. There's some gross things we
can do, but they aren't worthwhile, imho.

eg

.if defined(KERNEL_LD_OVERRIDE)
LD=${KERNEL_LD_OVERRIDE}
.else
LD=ld.lld
.endif

or other variations on that. We could do it without the .else clause and
just add KERNEL_LD_OVERRIDE=ld.lld to GENERIC on i386 as a build-time
override. This would give people a way out, but would violate POLA a little
bit. Given the frequency of overriding LD=, it may be OK. People
sophisticated enough to do that surely are sophisticated enough to read
changes to the kernel config files. This wouldn't help everybody
(especially those with custom kernel configs), but short of adding it to
DEFAULTS, it's likely pushing the edge of how disruptive one can be in a
stable branch.

So there's a number of variations on this theme. I'm not convinced they are
worthwhile for this issue because none are side-effect free, but it's
certainly a solution space others can noodle through to see if they can
find the "just so" mix of POLA and bug fixing.

Warner
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
[ Charset UTF-8 unsupported, converting... ]
> On Thu, 28 Feb 2019 at 09:33, Rodney W. Grimes
>  wrote:
> >
> > LD?=ld.lld in the right place(s)?
> 
> Perhaps, I seem to recall some issue with that, but not the specifics.

sys.mk already does a LD?=ld so by the time we try
to override it in the Makefile.i386 it is too late
as already defined.

*sigh*

> > And is this still an issue for stable/12 i386?
> > or has ld been changed to ld.lld?
> 
> stable/12 i386 still has GNU ld as /usr/bin/ld and there are a small
> number of ports (particularly Free Pascal ones) which fail to build
> with lld.
> 
> They're tracked as children of PR 214864:
> https://bugs.freebsd.org/bugzilla/showdependencytree.cgi?id=214864&hide_resolved=1
> The Lazarus / Free Pascal issue is in PR 233413.
> 
> In my opinion we should merge the switch to lld as /usr/bin/ld to
> stable/12 now and iterate on fixing the remaining ports fallout, but
> would like re/portmgr's assent.
> 

-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
> On Thu, 28 Feb 2019 at 09:33, Rodney W. Grimes
>  wrote:
> >
> > LD?=ld.lld in the right place(s)?
> 
> Perhaps, I seem to recall some issue with that, but not the specifics.

Any idea on what that issue was?

> > And is this still an issue for stable/12 i386?
> > or has ld been changed to ld.lld?
> 
> stable/12 i386 still has GNU ld as /usr/bin/ld and there are a small
> number of ports (particularly Free Pascal ones) which fail to build
> with lld.
> 
> They're tracked as children of PR 214864:
> https://bugs.freebsd.org/bugzilla/showdependencytree.cgi?id=214864&hide_resolved=1
> The Lazarus / Free Pascal issue is in PR 233413.

Thank you, I am now cc: on PR214864

> In my opinion we should merge the switch to lld as /usr/bin/ld to
> stable/12 now and iterate on fixing the remaining ports fallout, but
> would like re/portmgr's assent.

I'll defer to gjb@ on that, but this seems reasonable from my perspective.
Adding re@ to cc: list

-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Ed Maste
On Thu, 28 Feb 2019 at 09:33, Rodney W. Grimes
 wrote:
>
> LD?=ld.lld in the right place(s)?

Perhaps, I seem to recall some issue with that, but not the specifics.

> And is this still an issue for stable/12 i386?
> or has ld been changed to ld.lld?

stable/12 i386 still has GNU ld as /usr/bin/ld and there are a small
number of ports (particularly Free Pascal ones) which fail to build
with lld.

They're tracked as children of PR 214864:
https://bugs.freebsd.org/bugzilla/showdependencytree.cgi?id=214864&hide_resolved=1
The Lazarus / Free Pascal issue is in PR 233413.

In my opinion we should merge the switch to lld as /usr/bin/ld to
stable/12 now and iterate on fixing the remaining ports fallout, but
would like re/portmgr's assent.
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
[ Charset UTF-8 unsupported, converting... ]
> On Thu, 28 Feb 2019 at 08:26, Rodney W. Grimes
>  wrote:
> >
> > Are you really rally expecting a user to rebuild the world that
> > he just installed that should be exactly the same world he gets
> > build (reproduceable builds and all??).
> 
> I'm expecting that a user will either follow the directions in the
> handbook (or use the LD=ld.lld override). A user that rebuilds the
> world they just installed will indeed get the same world.
> 
> > But in your other mail you said the proper toolchain is included,
> > so this is not really true?
> 
> > Yes I remeber the issue but we shipped a release with the issue in it?
> > An issue that was hit 7 months before the release?
> > Really?
> 
> Yes, unfortunately re and portmgr asked me not to change this for the release.
> 
> > Isn't this just a mater of fixing the toplevel make at
> > /usr/src for target buildkernel to include the LD=ld.lld or
> > fixing the kernel Makefile likewise?
> 
> Possibly, but we don't want to break things if the user provides their
> own setting for LD=. I had a brief look at it when this issue existed
> on amd64 but there was no trivial fix.

LD?=ld.lld in the right place(s)?

And is this still an issue for stable/12 i386?
or has ld been changed to ld.lld?

-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Ed Maste
On Thu, 28 Feb 2019 at 08:26, Rodney W. Grimes
 wrote:
>
> Are you really rally expecting a user to rebuild the world that
> he just installed that should be exactly the same world he gets
> build (reproduceable builds and all??).

I'm expecting that a user will either follow the directions in the
handbook (or use the LD=ld.lld override). A user that rebuilds the
world they just installed will indeed get the same world.

> But in your other mail you said the proper toolchain is included,
> so this is not really true?

> Yes I remeber the issue but we shipped a release with the issue in it?
> An issue that was hit 7 months before the release?
> Really?

Yes, unfortunately re and portmgr asked me not to change this for the release.

> Isn't this just a mater of fixing the toplevel make at
> /usr/src for target buildkernel to include the LD=ld.lld or
> fixing the kernel Makefile likewise?

Possibly, but we don't want to break things if the user provides their
own setting for LD=. I had a brief look at it when this issue existed
on amd64 but there was no trivial fix.
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
> > > > Let me guess.  You use 'make' in sys/i386/build/YOUR_KERNEL ?
> > > > Then you need to use 'LD=ld.ldd make'.  The proper way of
> > > > 'make buildkernel' from top-level src handles it automatically.
> > > >
> > > If you back up in the thread you would also see the output
> > > is the same for cd /usr/src; make buildkernel conf=CUSTOM
> > 
> > "make buildworld" or "make kernel-toolchain" needs to be run first.
> 
> Are you really rally expecting a user to rebuild the world that
> he just installed that should be exactly the same world he gets
> build (reproduceable builds and all??).
> 
> But in your other mail you said the proper toolchain is included,
> so this is not really true?
> 
> > Also, there's a typo in kib's command - it should be LD=ld.lld (two
> > 'l's, not two 'd's).
> > 
> > There's more information about this issue (when it applied to amd64)
> > at https://lists.freebsd.org/pipermail/freebsd-arch/2018-May/018967.html.
> 
> Yes I remeber the issue but we shipped a release with the issue in it?
> An issue that was hit 7 months before the release?
> Really?
> 
> Isn't this just a mater of fixing the toplevel make at
> /usr/src for target buildkernel to include the LD=ld.lld or
> fixing the kernel Makefile likewise?

I have confirmed that
cd /usr/src; LD=ld.lld make buildkernel config=GENERIC
does resolve this issue, so can we add LD=ld.lld to
the buildkernel target and fix the kernel Makefile
on i386 to have this set?  (On RELENG/12.0 branch).
 
> Rod Grimes rgri...@freebsd.org
-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
> > > Let me guess.  You use 'make' in sys/i386/build/YOUR_KERNEL ?
> > > Then you need to use 'LD=ld.ldd make'.  The proper way of
> > > 'make buildkernel' from top-level src handles it automatically.
> > >
> > If you back up in the thread you would also see the output
> > is the same for cd /usr/src; make buildkernel conf=CUSTOM
> 
> "make buildworld" or "make kernel-toolchain" needs to be run first.

Are you really rally expecting a user to rebuild the world that
he just installed that should be exactly the same world he gets
build (reproduceable builds and all??).

But in your other mail you said the proper toolchain is included,
so this is not really true?

> Also, there's a typo in kib's command - it should be LD=ld.lld (two
> 'l's, not two 'd's).
> 
> There's more information about this issue (when it applied to amd64)
> at https://lists.freebsd.org/pipermail/freebsd-arch/2018-May/018967.html.

Yes I remeber the issue but we shipped a release with the issue in it?
An issue that was hit 7 months before the release?
Really?

Isn't this just a mater of fixing the toplevel make at
/usr/src for target buildkernel to include the LD=ld.lld or
fixing the kernel Makefile likewise?

-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Ed Maste
> > Let me guess.  You use 'make' in sys/i386/build/YOUR_KERNEL ?
> > Then you need to use 'LD=ld.ldd make'.  The proper way of
> > 'make buildkernel' from top-level src handles it automatically.
> >
> If you back up in the thread you would also see the output
> is the same for cd /usr/src; make buildkernel conf=CUSTOM

"make buildworld" or "make kernel-toolchain" needs to be run first.
Also, there's a typo in kib's command - it should be LD=ld.lld (two
'l's, not two 'd's).

There's more information about this issue (when it applied to amd64)
at https://lists.freebsd.org/pipermail/freebsd-arch/2018-May/018967.html.
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
[ Charset UTF-8 unsupported, converting... ]
> On Thu, 28 Feb 2019 at 03:50, Rodney W. Grimes
>  wrote:
> >
> > Now the begging question, why isnt the toolchain as shipped
> > already properly built?
> 
> The required toolchain is included in 12.0-RELEASE i386 - the linker
> is /usr/bin/ld.lld. It just needs to be specified explicitly if build
> via a method other than make buildworld or kernel-toolchain followed
> by buildkernel.

Why is this not included in the /usr/src; make buildkernel target?

> 
> I wanted to ship 12.0 i386 with lld as /usr/bin/ld, but held off on re
> and portmgr's advice due to ports fallout.

Is there a release note item describing that kernel building now
requires specical procedures to build a kernel?

This is a POLA issue.

-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Ed Maste
On Thu, 28 Feb 2019 at 03:50, Rodney W. Grimes
 wrote:
>
> Now the begging question, why isnt the toolchain as shipped
> already properly built?

The required toolchain is included in 12.0-RELEASE i386 - the linker
is /usr/bin/ld.lld. It just needs to be specified explicitly if build
via a method other than make buildworld or kernel-toolchain followed
by buildkernel.

I wanted to ship 12.0 i386 with lld as /usr/bin/ld, but held off on re
and portmgr's advice due to ports fallout.
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
> On Thu, Feb 28, 2019 at 12:49:25AM -0800, Rodney W. Grimes wrote:
> > > -- Start of PGP signed section.
> > > > On 28 Feb 2019, at 00:37, Rodney W. Grimes 
> > > >  wrote:
> > > > > 
> > > > > config CUSTOM
> > > > > Kernel build directory is ../compile/CUSTOM
> > > > > Don't forget to do ``make cleandepend && make depend''
> > > > > fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
> > > > > fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make 
> > > > > depend && make -j4 && make install) >&make.OUT
> > > > > fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
> > > > > make: "../../../conf/../../../conf/kern.pre.mk" line 127: 
> > > > > amd64/arm64/i386 kernel requires linker ifunc support
> > > > 
> > > > After ifunc support was introduced, you have to run at least
> > > > "make kernel-toolchain" before "make buildkernel", or otherwise just run
> > > > "make buildworld" first.  That will build the linker which supports the
> > > > required functionality.
> > > 
> > > This is the -RELEASE, why is the release not built with the
> > > proper toolchain in place?  This is not some upgrade or anything
> > > odd, download 12.0-RELEASE i386 iso, install it with sources,
> > > try to build a kernel.
> > > 
> > > I am running your suggested make kernel-toolchain now
> > > to see if that fixes the problem (it shouid not, or
> > > if it does we have a major issue with our release
> > > building procedures.)
> > 
> > Sadly I have confirmed that "make kernel-toolchain" does infact
> > fix the above error.
> > 
> > Now the begging question, why isnt the toolchain as shipped
> > already properly built?
> > 
> > This is a stock FreeBSD-12.0=RELEASE-i386-disc1.iso install,
> > with stock sources from the iso.  I was simply configuring
> > a custom kernel, I should not need to build a took chain
> > to build a kernel when nothing has changed from the
> > RELEASE, it should already be the correct toolchain.
> 
> Let me guess.  You use 'make' in sys/i386/build/YOUR_KERNEL ?
> Then you need to use 'LD=ld.ldd make'.  The proper way of
> 'make buildkernel' from top-level src handles it automatically.
> 
If you back up in the thread you would also see the output
is the same for cd /usr/src; make buildkernel conf=CUSTOM



-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Konstantin Belousov
On Thu, Feb 28, 2019 at 12:49:25AM -0800, Rodney W. Grimes wrote:
> > -- Start of PGP signed section.
> > > On 28 Feb 2019, at 00:37, Rodney W. Grimes 
> > >  wrote:
> > > > 
> > > > config CUSTOM
> > > > Kernel build directory is ../compile/CUSTOM
> > > > Don't forget to do ``make cleandepend && make depend''
> > > > fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
> > > > fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make depend 
> > > > && make -j4 && make install) >&make.OUT
> > > > fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
> > > > make: "../../../conf/../../../conf/kern.pre.mk" line 127: 
> > > > amd64/arm64/i386 kernel requires linker ifunc support
> > > 
> > > After ifunc support was introduced, you have to run at least
> > > "make kernel-toolchain" before "make buildkernel", or otherwise just run
> > > "make buildworld" first.  That will build the linker which supports the
> > > required functionality.
> > 
> > This is the -RELEASE, why is the release not built with the
> > proper toolchain in place?  This is not some upgrade or anything
> > odd, download 12.0-RELEASE i386 iso, install it with sources,
> > try to build a kernel.
> > 
> > I am running your suggested make kernel-toolchain now
> > to see if that fixes the problem (it shouid not, or
> > if it does we have a major issue with our release
> > building procedures.)
> 
> Sadly I have confirmed that "make kernel-toolchain" does infact
> fix the above error.
> 
> Now the begging question, why isnt the toolchain as shipped
> already properly built?
> 
> This is a stock FreeBSD-12.0=RELEASE-i386-disc1.iso install,
> with stock sources from the iso.  I was simply configuring
> a custom kernel, I should not need to build a took chain
> to build a kernel when nothing has changed from the
> RELEASE, it should already be the correct toolchain.

Let me guess.  You use 'make' in sys/i386/build/YOUR_KERNEL ?
Then you need to use 'LD=ld.ldd make'.  The proper way of
'make buildkernel' from top-level src handles it automatically.
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-28 Thread Rodney W. Grimes
> -- Start of PGP signed section.
> > On 28 Feb 2019, at 00:37, Rodney W. Grimes  
> > wrote:
> > > 
> > > config CUSTOM
> > > Kernel build directory is ../compile/CUSTOM
> > > Don't forget to do ``make cleandepend && make depend''
> > > fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
> > > fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make depend 
> > > && make -j4 && make install) >&make.OUT
> > > fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
> > > make: "../../../conf/../../../conf/kern.pre.mk" line 127: 
> > > amd64/arm64/i386 kernel requires linker ifunc support
> > 
> > After ifunc support was introduced, you have to run at least
> > "make kernel-toolchain" before "make buildkernel", or otherwise just run
> > "make buildworld" first.  That will build the linker which supports the
> > required functionality.
> 
> This is the -RELEASE, why is the release not built with the
> proper toolchain in place?  This is not some upgrade or anything
> odd, download 12.0-RELEASE i386 iso, install it with sources,
> try to build a kernel.
> 
> I am running your suggested make kernel-toolchain now
> to see if that fixes the problem (it shouid not, or
> if it does we have a major issue with our release
> building procedures.)

Sadly I have confirmed that "make kernel-toolchain" does infact
fix the above error.

Now the begging question, why isnt the toolchain as shipped
already properly built?

This is a stock FreeBSD-12.0=RELEASE-i386-disc1.iso install,
with stock sources from the iso.  I was simply configuring
a custom kernel, I should not need to build a took chain
to build a kernel when nothing has changed from the
RELEASE, it should already be the correct toolchain.

> > -Dimitry
> -- 
> Rod Grimes rgri...@freebsd.org
-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-27 Thread Rodney W. Grimes
-- Start of PGP signed section.
> On 28 Feb 2019, at 00:37, Rodney W. Grimes  
> wrote:
> > 
> > config CUSTOM
> > Kernel build directory is ../compile/CUSTOM
> > Don't forget to do ``make cleandepend && make depend''
> > fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
> > fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make depend && 
> > make -j4 && make install) >&make.OUT
> > fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
> > make: "../../../conf/../../../conf/kern.pre.mk" line 127: amd64/arm64/i386 
> > kernel requires linker ifunc support
> 
> After ifunc support was introduced, you have to run at least
> "make kernel-toolchain" before "make buildkernel", or otherwise just run
> "make buildworld" first.  That will build the linker which supports the
> required functionality.

This is the -RELEASE, why is the release not built with the
proper toolchain in place?  This is not some upgrade or anything
odd, download 12.0-RELEASE i386 iso, install it with sources,
try to build a kernel.

I am running your suggested make kernel-toolchain now
to see if that fixes the problem (it shouid not, or
if it does we have a major issue with our release
building procedures.)

> -Dimitry
-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-27 Thread Dimitry Andric
On 28 Feb 2019, at 00:37, Rodney W. Grimes  
wrote:
> 
> config CUSTOM
> Kernel build directory is ../compile/CUSTOM
> Don't forget to do ``make cleandepend && make depend''
> fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
> fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make depend && 
> make -j4 && make install) >&make.OUT
> fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
> make: "../../../conf/../../../conf/kern.pre.mk" line 127: amd64/arm64/i386 
> kernel requires linker ifunc support

After ifunc support was introduced, you have to run at least
"make kernel-toolchain" before "make buildkernel", or otherwise just run
"make buildworld" first.  That will build the linker which supports the
required functionality.

-Dimitry



signature.asc
Description: Message signed with OpenPGP


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-27 Thread Rodney W. Grimes
[ Charset ISO-8859-1 unsupported, converting... ]
> Rodney W. Grimes wrote:
> >config CUSTOM
> >Kernel build directory is ../compile/CUSTOM
> >Don't forget to do ``make cleandepend && make depend''
> >fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
> >fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make depend && 
> >>make -j4 && make install) >&make.OUT
> >fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
> >make: "../../../conf/../../../conf/kern.pre.mk" line 127: amd64/arm64/i386 
> >kernel >requires linker ifunc support
> I typically build kernels without doing "make buildkernel" and I've found I 
> need
> LD=lld SRCTOP= on the make commands.
> (or something close to that. I haven't done this since December.)
> I haven't tried, but I assumed "make buildkernel" takes care of this "behind 
> the
> curtains".
--
>>> stage 2.1: cleaning up the object tree
--
cd /usr/obj/usr/src/i386.i386/sys/GENERIC; MACHINE_ARCH=i386 MACHINE=i386 
CPUTYPE= CC="cc -target i386-unknown-freebsd12.0 
--sysroot=/usr/obj/usr/src/i386.i386/tmp 
-B/usr/obj/usr/src/i386.i386/tmp/usr/bin" CXX="c++  -target 
i386-unknown-freebsd12.0 --sysroot=/usr/obj/usr/src/i386.i386/tmp 
-B/usr/obj/usr/src/i386.i386/tmp/usr/bin" CPP="cpp -target 
i386-unknown-freebsd12.0 --sysroot=/usr/obj/usr/src/i386.i386/tmp 
-B/usr/obj/usr/src/i386.i386/tmp/usr/bin" AS="as" AR="ar" LD="ld" LLVM_LINK="" 
NM=nm OBJCOPY="objcopy" RANLIB=ranlib STRINGS= SIZE="size" INSTALL="sh 
/usr/src/tools/install.sh" 
PATH=/usr/obj/usr/src/i386.i386/tmp/legacy/usr/sbin:/usr/obj/usr/src/i386.i386/tmp/legacy/usr/bin:/usr/obj/usr/src/i386.i386/tmp/legacy/bin:/usr/obj/usr/src/i386.i386/tmp/usr/sbin:/usr/obj/usr/src/i386.i386/tmp/usr/bin:/sbin:/bin:/usr/sbin:/usr/bin
 make  -m /usr/src/share/mk  KERNEL=kernel cleandir
make[2]: "/usr/src/sys/conf/kern.pre.mk" line 127: amd64/arm64/i386 kernel 
requires linker ifunc support
*** Error code 1

Stop.
make[1]: stopped in /usr/src
*** Error code 1

Stop.
make: stopped in /usr/src


> rick

-- 
Rod Grimes rgri...@freebsd.org
___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"


Re: FreeBSD 12.0 RELEASE i386 can not build a kernel?

2019-02-27 Thread Rick Macklem
Rodney W. Grimes wrote:
>config CUSTOM
>Kernel build directory is ../compile/CUSTOM
>Don't forget to do ``make cleandepend && make depend''
>fb-bld-120-i386.dnsmgr.net:root {200}# cd ../compile/CUSTOM
>fb-bld-120-i386.dnsmgr.net:root {201}# (make cleandepend && make depend && 
>>make -j4 && make install) >&make.OUT
>fb-bld-120-i386.dnsmgr.net:root {202}# more make.OUT
>make: "../../../conf/../../../conf/kern.pre.mk" line 127: amd64/arm64/i386 
>kernel >requires linker ifunc support
I typically build kernels without doing "make buildkernel" and I've found I need
LD=lld SRCTOP= on the make commands.
(or something close to that. I haven't done this since December.)
I haven't tried, but I assumed "make buildkernel" takes care of this "behind the
curtains".

rick

___
freebsd-stable@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"