# 'clean' 8.1 kernel compilation error



## Ajax (Oct 3, 2010)

Hello everyone,

After installed FreeBSD 8.1 on i386 machine copied /sys/i386/conf/GENERIC to /sys/i386/conf/PAC adding next lines at the end:

```
options		IPFIREWALL
options		IPFIREWALL_FORWARD
options		IPFIREWALL_VERBOSE
options		IPFIREWALL_VERBOSE_LIMIT=5
options		IPDIVERT
options		DUMMYNET
device		pf
device		pflog
device		pfsync
options		ALTQ
options		ALTQ_CBQ
options		ALTQ_RED
options		ALTQ_RIO 
options		ALTQ_HFSC
options		ALTQ_PRIQ
options		ALTQ_NOPCC
```
and after `make buildkernel=PAC` from /usr/src/ and few hours of building stable getting next error:

```
(cd /usr/src/rescue/rescue/../../usr.bin/id &&  make -DRESCUE CRUNCH_CFLAGS=-DRESCUE DIRPRFX=rescue/rescue/id/ depend && make -DRESCUE 
CRUNCH_CFLAGS=-DRESCUE DIRPRFX=rescue/rescue/id/ id.o)
`id.o' is up to date.
(cd /usr/src/rescue/rescue/../../usr.sbin/chroot &&  make -DRESCUE CRUNCH_CFLAGS=-DRESCUE DIRPRFX=rescue/rescue/chroot/ depend && make -DRESCUE 
CRUNCH_CFLAGS=-DRESCUE DIRPRFX=rescue/rescue/chroot/ chroot.o)
`chroot.o' is up to date.
(cd /usr/src/rescue/rescue/../../usr.sbin/chown &&  make -DRESCUE CRUNCH_CFLAGS=-DRESCUE DIRPRFX=rescue/rescue/chown/ depend && make -DRESCUE 
CRUNCH_CFLAGS=-DRESCUE DIRPRFX=rescue/rescue/chown/ chown.o)
`chown.o' is up to date.
cc -static -o rescue rescue.o cat.lo chflags.lo chio.lo chmod.lo cp.lo date.lo dd.lo df.lo echo.lo ed.lo expr.lo getfacl.lo hostname.lo kenv.lo 
kill.lo ln.lo ls.lo mkdir.lo mv.lo pkill.lo ps.lo pwd.lo realpath.lo rm.lo rmdir.lo setfacl.lo sh.lo stty.lo sync.lo test.lo rcp.lo csh.lo 
atacontrol.lo badsect.lo camcontrol.lo ccdconfig.lo clri.lo devfs.lo dmesg.lo dump.lo dumpfs.lo dumpon.lo fsck.lo fsck_ffs.lo fsck_msdosfs.lo 
fsdb.lo fsirand.lo gbde.lo geom.lo ifconfig.lo init.lo kldconfig.lo kldload.lo kldstat.lo kldunload.lo ldconfig.lo md5.lo mdconfig.lo mdmfs.lo 
mknod.lo mount.lo mount_cd9660.lo mount_msdosfs.lo mount_nfs.lo mount_ntfs.lo mount_nullfs.lo mount_udf.lo mount_unionfs.lo newfs.lo 
newfs_msdos.lo nos-tun.lo ping.lo reboot.lo restore.lo rcorder.lo route.lo routed.lo rtquery.lo rtsol.lo savecore.lo spppcontrol.lo swapon.lo 
sysctl.lo tunefs.lo umount.lo atmconfig.lo ping6.lo ipf.lo zfs.lo zpool.lo bsdlabel.lo sconfig.lo fdisk.lo dhclient.lo head.lo mt.lo sed.lo 
tail.lo tee.lo gzip.lo bzip2.lo xz.lo tar.lo vi.lo id.lo chroot.lo chown.lo /usr/src/rescue/rescue/../librescue/exec.o 
/usr/src/rescue/rescue/../librescue/getusershell.o /usr/src/rescue/rescue/../librescue/login_class.o 
/usr/src/rescue/rescue/../librescue/popen.o /usr/src/rescue/rescue/../librescue/rcmdsh.o /usr/src/rescue/rescue/../librescue/sysctl.o 
/usr/src/rescue/rescue/../librescue/system.o -lcrypt -ledit -lkvm -ll -ltermcap -lutil -lalias -lcam -lcurses -ldevstat -lipsec -lipx -lzfs -
lnvpair -luutil -lavl -lgeom -lbsdxml -ljail -lkiconv -lmd -lreadline -lsbuf -lufs -lz -lbz2 -llzma -larchive -lcrypto -lm
csh.lo(.text+0xdba6): In function `nlsclose':
: undefined reference to `dl_iconv_close'
csh.lo(.text+0xdd21): In function `nlsinit':
: undefined reference to `dl_iconv_open'
csh.lo(.text+0xde1c): In function `iconv_catgets':
: undefined reference to `dl_iconv'
*** Error code 1

Stop in /usr/src/rescue/rescue.
*** Error code 1

Stop in /usr/src/rescue/rescue.
*** Error code 1

Stop in /usr/src/rescue.
*** Error code 1

Stop in /usr/src.
*** Error code 1

Stop in /usr/src.
```
Any ideas what that could be?


----------



## SirDice (Oct 3, 2010)

Not related to the error you have but why are you adding both IPFilter _and_ PF?
Use one or the other, not both.


----------



## Ajax (Oct 3, 2010)

I know  But _ipfw_ is 'main' firewall when _pf_ I added just to try it. However even removing pf-related section doesn't help


----------



## kpa (Oct 3, 2010)

Is that just a typo or the actual command you're running:
`# make buildkernel=PAC` ?

It should be:

`# make buildkernel KERNCONF=PAC`


----------



## Ajax (Oct 4, 2010)

Ashes on my head! Would not compile kernels 1AM anymore  Thanks, *kpa*


----------

