# failed when linking kernel.debug



## rocky (Mar 20, 2009)

Hello, 

I build my kernel and get the error as below. My kernel configuration (icy_kernel.txt) is attached to this post.

What's wrong to my kernel?

Thank you for replies.

Cheers,

-- rocky


```
linking kernel.debug
if_re.o(.text+0xb9f): In function `re_ifmedia_sts':
/usr/src/sys/dev/re/if_re.c:2678: undefined reference to `mii_pollstat'
if_re.o(.text+0xc66): In function `re_ifmedia_upd':
/usr/src/sys/dev/re/if_re.c:2659: undefined reference to `mii_mediachg'
if_re.o(.text+0x2271): In function `re_init_locked':
/usr/src/sys/dev/re/if_re.c:2635: undefined reference to `mii_mediachg'
if_re.o(.text+0x3503): In function `re_tick':
/usr/src/sys/dev/re/if_re.c:2024: undefined reference to `mii_tick'
if_re.o(.text+0x47af): In function `re_attach':
/usr/src/sys/dev/re/if_re.c:1317: undefined reference to `mii_phy_probe'
if_re.o(.data+0x478): In function `re_rxeof':
/usr/src/sys/dev/re/if_re.c:1581: undefined reference to `miibus_driver'
if_re.o(.data+0x480):/usr/src/sys/dev/re/if_re.c:1582: undefined reference to `miibus_devclass'
if_re.o(.data+0x5e0):/usr/src/sys/dev/re/if_re.c:1929: undefined reference to `miibus_readreg_desc'
if_re.o(.data+0x5f0):/usr/src/sys/dev/re/if_re.c:1929: undefined reference to `miibus_writereg_desc'
if_re.o(.data+0x600):/usr/src/sys/dev/re/if_re.c:1832: undefined reference to `miibus_statchg_desc'
*** Error code 1
```


----------



## rocky (Mar 20, 2009)

PS: Sorry, I forgot to say that I am using FreeBSD-7.1-RELEASE


----------



## ale (Mar 20, 2009)

Look at line 211-212:
	
	



```
# PCI Ethernet NICs that use the common MII bus controller code.
# NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
```


----------



## rocky (Mar 20, 2009)

Thank you very much. My kernel has been built successfully


----------

