tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: MACHINE_ARCH on NetBSD/evbearmv6hf-el current

> As described in
> and
> .
> pkg_add on NetBSD/evbearm*hf fails with, for example,
> pkg_add: NetBSD/earmv6hf 6.99.23 (pkg) vs. NetBSD/earm 6.99.23 (this host)
> error.
> What is solution?
> This problem discourages my pkgsrc development on Raspberry Pi.

It was broken by matt@ and no response for a month in recent discussion:

The essencial problem is:

"How to determine whether current environment is hardfloat or softfloat?"

By static MACHINE_ARCH, or dynamic sysctl(3)?
If dynamic sysctl(3) is prefered, which node?

MACHINE_ARCH=earmhf was initially introduced into and bsd.*.mk:
but there was no changes against MACHINE_ARCH values in <machine/param.h>.

This initially caused the problem mentioned in PR/48193
(i.e. inconsistent MACHINE_ARCH between uname(1) and

PR/48193 pointed out no hf definitions in MACHINE_ARCH in param.h:

After that, exec_elf.h was changed to have machine_arch info in the
ELF note:

And sysctl(9) for machine_arch was introduced to return the value
dynamically instead of static MACHINE_ARCH in <machine/param.h>:

But there was a report the above sysctl change didn't help the problem:  
Then make(1) was changed to use the sysctl machine_arch instead of
MACHINE_ARCH from <machine/param.h>:

But pkg_add(1) has the same problem as make(1) (i.e. it uses
MACHINE_ARCH from <machine/param.h>):

matt claimed it was a separate issue and PR/48215 was filed:

Then matt also claimed pkg_add(1) problem was a tools issue:

I asked about the strategy how to determine sf or hf:

Then matt claimed his changes solved the PR/48193 and further discussion
should go in tech-* lists instead of gnats: 
After that removal of MACHINE_ARCH was proposed in tech-userlevel: 

I replied that it could cause inconsistency (emips is MACHINE_ARCH=mipseb
but softfloat) and it might also require many changes to third party
applications like pkg_add(1):

Then everything stalls.

All these MACHINE_ARCH=earmhf* changes were committed without discussion,
and it looks all changes were introduced without proper considerations.
(though I don't know if changes by core members need prior approvals or not)

Izumi Tsutsui

Home | Main Index | Thread Index | Old Index