]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/commit
MF10 259465:
authornwhitehorn <nwhitehorn@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Tue, 17 Dec 2013 14:55:23 +0000 (14:55 +0000)
committernwhitehorn <nwhitehorn@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Tue, 17 Dec 2013 14:55:23 +0000 (14:55 +0000)
commita251e14c23770f32238a0af46ac32fcdddd68914
treedcc576c09ce4d2ed3e68850d1ea9438e5c4e81ae
parentf7349214b4b6cc5616c519c2f7b552d90ad7a536
MF10 259465:
Add new sysctl, kern.supported_archs, containing the list of FreeBSD
MACHINE_ARCH values whose binaries this kernel can run. This patch provides
a feature requested for implementing pkgng ABI identifiers in a robust
way.

The list is designed to indicate whether, say, an i386 package can be run on
the current system. If kern.supported_abis contains "i386", then the answer
is yes. Otherwise, the answer is no.

At the moment, this only supports MACHINE_ARCH and MACHINE_ARCH32. As we
gain support for more interesting combinations, this needs to become more
flexible, possibily through the sysent framework, along with the
hw.machine_arch emulation immediately preceding this code in kern_mib.c.

Reviewed by: imp
Approved by: re (glebius)

git-svn-id: svn://svn.freebsd.org/base/releng/10.0@259515 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/kern/kern_mib.c