experimental qemu-devel port update, please test!

Scot Hetzel swhetzel at gmail.com
Fri Jul 13 08:27:53 UTC 2007

On 7/12/07, Craig Boston <craig at yekse.gank.org> wrote:
> Aha!  The problem isn't that curproc is garbage, but rather that it's
> being interpreted wrong.
> struct proc has some extra fields when KSE is #defined.  KSE recently
> became a kernel option and was put in the DEFAULTS file, so everyone's
> kernel has it defined.  But kqemu is being compiled without it.
> I compiled with -DKSE and now kqemu works!
> This seems like it would be a common problem for modules compiled
> outside the kernel tree.  Is there an established way to get the
> standard configuration options?
> I'm thinking also about other options like SMP, that for instance
> changes the way mutexes work.

Add the following option to the kernel configuration file:

# This allows you to actually store this configuration file into
# the kernel binary itself, where it may be later read by saying:
#    strings -n 3 /boot/kernel/kernel | sed -n 's/^___//p' > MYKERNEL
options         INCLUDE_CONFIG_FILE     # Include this file in kernel

Then add the following to the kernel module port:

BOOTFILE!= sysctl -n kern.bootfile
.if !defined(KOPTION_KSE)
. if ${OSVERSION} > 700040
#KOPTION_KSE!= if ${SYSCTL} -b kern.conftxt | grep KSE ; then echo "yes" ; fi 
KOPTION_KSE!= if config -x ${BOOTFILE} | grep KSE ; then echo "yes" ; fi 
. else
KOPTION_KSE!= if strings -n 3 ${BOOTFILE} | grep KSE ; then echo "yes" ; fi
. endif

.if ${KOPTION_KSE} == yes

No electrons were mamed while sending this message. Only slightly bruised.

More information about the freebsd-ports mailing list