Error while compiling my Kernel for ipfw

I'm trying to install ipfw on FreeBSD 7.1. I've been following instructions from this website: http://www.cyberciti.biz/faq/howto-setup-freebsd-ipfw-firewall/

During the make build instruction, I get the following error message:


Code:
cc -shared -nostdlib hack.c -o hack.So
rm -f hack.c
MAKE=make sh /usr/src/sys/conf/newvers.sh GENERIC
cc -c -O -pipe  -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-
qual  -Wundef -Wno-pointer-sign -fformat-extensions -nostdinc  -I. -I/usr/src/sys -I/usr/src/sys/contrib/altq -D_KERNEL -
DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=8000 --param inline-unit-growth=100 --param large-function-
growth=1000  -mno-align-long-strings -mpreferred-stack-boundary=2  -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestanding -Werror  
vers.c
linking kernel.debug
isp_pci.o(.text+0x3a60): In function `isp_pci_attach':
/usr/src/sys/dev/isp/isp_pci.c:1044: undefined reference to `firmware_get'
isp_pci.o(.text+0x3a9c):/usr/src/sys/dev/isp/isp_pci.c:1048: undefined reference to `firmware_get'
if_ural.o(.text+0xeb0): In function `ural_attach':
/usr/src/sys/dev/usb/if_ural.c:515: undefined reference to `ieee80211_amrr_init'
if_ural.o(.text+0x2b79): In function `ural_amrr_update':
/usr/src/sys/dev/usb/if_ural.c:2508: undefined reference to `ieee80211_amrr_choose'
if_ural.o(.text+0x32ac): In function `ural_task':
/usr/src/sys/dev/usb/if_ural.c:2450: undefined reference to `ieee80211_amrr_node_init'
bios.o(.text+0xc7a): In function `pnpbios_identify':
/usr/src/sys/i386/i386/bios.c:677: undefined reference to `pnp_eisaformat'
bios.o(.text+0xc9d):/usr/src/sys/i386/i386/bios.c:679: undefined reference to `pnp_eisaformat'
bios.o(.text+0xea6):/usr/src/sys/i386/i386/bios.c:703: undefined reference to `pnp_parse_resources'
bios.o(.text+0xebd):/usr/src/sys/i386/i386/bios.c:706: undefined reference to `pnp_eisaformat'
bios.o(.text+0xf60):/usr/src/sys/i386/i386/bios.c:737: undefined reference to `pnp_eisaformat'
bios.o(.text+0xf8a):/usr/src/sys/i386/i386/bios.c:740: undefined reference to `pnp_eisaformat'
*** Error code 1

Stop in /usr/obj/usr/src/sys/IPFWKERNEL.
*** Error code 1

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

Stop in /usr/src.


I've tried to do a make -k build which worked, then a make -k install; that did not work... I have installed FreeBSD on a Dell PowerEdge 2650. Does anyone have any suggestions on how I can fix this problem?
 
"Installing" IPFW on FreeBSD (any version) is as simple as: # kldload ipfw If you need divert sockets, then # kldload ipdivert Logging options are configured via /etc/sysctl.conf using the net.inet.ip.fw sysctls. See the output of $ sysctl -d net.inet.ip.fw for details.

I've tried to do a make -k build which worked, then a make -k install; that did not work

"make -k build" is not the way to build a kernel, and is not listed anywhere in that how-to. Same for "make -k install". See the handbook for the correct way to build a kernel.
 
Hi Phoenix,

Thanks for the assistance on how to install ipfw. The make commands I listed above were just abbreviations. The real command I used are [cmd=]make buildkernel KERNCONF=IPFWKERNEL[/cmd] and [cmd=]make installkernel KERNCONF=IPFWKERNEL[/cmd]

The [cmd=]make installkernel[/cmd] command produced the error I pasted above. After spending an entire day of searching the internet for answers, I found the -k switch option from the man doc file. Using the -k switch allowed the kernel to be rebuilt; but it did not work for the install.

Do you have any suggestions to how I can resolve this error message? By the way in order to attempt a to rebuild the kernel, I had to comment out the "rr232x" and the "lnc" devices in the GENERIC kernel file. Once I ran the [cmd=]make buildkernel KERNCONF=IPFWKERNEL[/cmd] command, I get the above error message. Do you or anyone have any suggestions on how to resolve this error problem?
 
Rebuilding the kernel has to be done carefully, some devices and options are needed for other devices and options to work. Your first post indicates a buildkernel problem AFAIK. Why not use a generic kernel and the kldload ipfw commands above, get ipfw working, then *carefully* rebuild a kernel following some guide that includes isntallkernel and maybe buildworld etc (the longer the better, even here in the forum howto section maybe). (Hopefully answering most the problems, if not questions, so far. Or, restate them to clarify.)
 
Back
Top