On Tue, Nov 29, 2011 at 4:35 AM, T. Valent <tmp...@4ss.de> wrote:
> Hi!
>
> I'm trying to build a new kernel. However, while compiling I get
> complaints about undefined references like this:
>
> ld -Ttext 0xD0200120 -e start -N --warn-common -S -x -o bsd
> ${SYSTEM_HEAD} vers.o ${OBJS}
> machdep.o(.text+0x2791): In function `sys_sigreturn':
> : undefined reference to `fpu_mxcsr_mask'

andres@pote:~ $ grep -rw fpu_mxcsr_mask /sys/arch/i386
...
/sys/arch/i386/include/npx.h:extern uint32_t    fpu_mxcsr_mask;
/sys/arch/i386/isa/npx.c:uint32_t       fpu_mxcsr_mask;
...
andres@pote:~ $ grep -rw npx /sys/arch/i386/conf/files.i386
/sys/arch/i386/conf/files.i386:device   npx
/sys/arch/i386/conf/files.i386:attach   npx at isa
/sys/arch/i386/conf/files.i386:file     arch/i386/isa/npx.c
 npx needs-flag

>
> The above line is just an example. I have poked around with more or less
> guessing what could be missing, but after 2 days I'm quite sure I need a
> general solution to finding the dependencies instead of guessing.
>
> I have no skills in kernel coding. I wonder if there's a good way to
> find out which part I am missing in the config file(s).

note how the grep commands required no kernel coding skills

>
> This is what I do:
> edit /usr/src/sys/conf/GENERIC
> I'm fine with this so far.
>
> Now to edit
>
> /usr/src/sys/arch/i386/conf/GENERIC
>
> I do
>
> dmassage -t

i might be wrong, but is this really aggressive auto spelling
corrector for "dmesg"?

>
> and make sure all the hardware I need is included in my config file. I'm
> quite sure I've included everything I need, I get the above mentioned
> problems, which I understand as dependencies. However, I just don't know
> how to find out which line of the config file I have to include to solve
> this.
>
> I know I am recommended to use the generic kernel. I need the kernel for
> an embedded device where the hardware is well known in detail, it is
> always the same, will not change and memory is very limited. So I need
> to get rid of the unnecessary stuff in the kernel.
>
> Thanks in advance!
>
> T.

Reply via email to