Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 May 2003 14:07:38 -0400
From:      Dave Dolson <ddolson@sandvine.com>
To:        "'stable@freebsd.org'" <stable@freebsd.org>
Subject:   kernel conf not applied to modules?
Message-ID:  <FE045D4D9F7AED4CBFF1B3B813C8533701918BFE@mail.sandvine.com>

next in thread | raw e-mail | index | archive | help
On FreeBSD 4.7
I noticed that when compiling kernel modules, the kernel options are not
available to the modules.
For example, my if_em.ko is not being compiled with the DEVICE_POLLING
configuration

It looks like "-include opt_global.h" is not being applied when compiling
the module.

Kernel compilation of if_em.c:
cc -c -O2 -pipe -malign-loops=4 -malign-jumps=4 -malign-functions=4
-mcpu=i686 -march=i686 -fno-gcse -DBOOT_COMCONSOLE_SPEED=115200  -Wall
-Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes
-Wpointer-arith -Winline -Wcast-qual  -fformat-extensions -ansi -g -nostdinc
-I- -I. -I/d2/ddolson/src/sys -I/d2/ddolson/src/sys/../include
-I/d2/ddolson/src/sys/contrib/ipfilter  -D_KERNEL -include opt_global.h -elf
-mpreferred-stack-boundary=2  /d2/ddolson/src/sys/dev/em/if_em.c

Module compilation of if_em.c:
cc -O2 -pipe -malign-loops=4 -malign-jumps=4 -malign-functions=4 -mcpu=i686
-march=i686 -fno-gcse -DBOOT_COMCONSOLE_SPEED=115200   -D_KERNEL -Wall
-Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes
-Wpointer-arith -Winline -Wcast-qual  -fformat-extensions -ansi -DKLD_MODULE
-nostdinc -I-  -I. -I@ -I@/../include -g -mpreferred-stack-boundary=2 -Wall
-Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes
-Wpointer-arith -Winline -Wcast-qual  -fformat-extensions -ansi -c
/d2/ddolson/src/sys/modules/em/../../dev/em/if_em.c

Is this a bug/feature, or is it something I've got wrong at our site?


Thanks,

David Dolson (ddolson@sandvine.com, www.sandvine.com)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?FE045D4D9F7AED4CBFF1B3B813C8533701918BFE>