linux-mod eclass builds each module in MODULE_NAMES separately and thus loose Module.symvers information. This problem causes Unresolved symbols if CONFIG_MODVERSIONS enabled and CONFIG_MODULE_FORCE_LOAD disabled. (See madwifi-ng bug 232099). Take a look at "7.3 Symbols from another external module" section of Documentation/kbuild/modules.txt. madwifi-ng uses top-level Makefile and thus single Module.symvers in default build is created. Because linux-mod eclass builds each module separately, Module.symvers file is created only for first modules: for others modpost fails due to missed symbols and creats empty Module.symvers. During such build you'll see the following warnings: WARNING: "ieee80211_rate_register" [/var/tmp/portage/net-wireless/madwifi-ng-0.9.4/work/madwifi-0.9.4/ath_rate/onoe/ath_rate_onoe.ko] undefined! So linux-mod.eclass should somehow preserve symbol version information, but I'm unsure of best solution. One possible solution is to create toplevel Module.symvers and then create symlink on this file in each module directory, like this patch does: =============================================================================== --- linux-mod.eclass 2008-04-03 20:37:30.000000000 +0400 +++ linux-mod.eclass 2008-09-14 14:50:34.000000000 +0400 @@ -497,6 +497,7 @@ BUILD_TARGETS=${BUILD_TARGETS:-clean module} strip_modulenames; cd "${S}" + touch Module.symvers for i in ${MODULE_NAMES} do unset libdir srcdir objdir @@ -511,6 +512,7 @@ if [ ! -f "${srcdir}/.built" ]; then cd ${srcdir} + ln -s "${S}"/Module.symvers Module.symvers einfo "Preparing ${modulename} module" if [[ -n ${ECONF_PARAMS} ]] then =============================================================================== But I'm not sure: in case one package build independent modules what single Module.symvers file can cause? It's possible that nothing but it's better to check. I just don't know how to do that. *shrug*
I'm not sure, but this issue became very annoying with 2.6.26 kernel. Thus setting blocker for bug 232070.
(In reply to comment #0) Just FYI, the patch for the linux-mod.eclass helped me to build the shared folders kernel module of virtualbox-guest-additions against kernels > 2.6.26 (bug236151)
thanks, committed. hope it doesn't break anything!