tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

modload under netbsd-5 appears not to export symbols from loaded modules for use by subsequent modules

        Hello.  I'm working on bringing  some modules forward from NetBSD-3 to
NetBSD-5.  I've got all compiled and ready to test.  But, I have a problem.
I have two modules are loaded in order and where the second module uses
functions from the first.  These are the old zaptel modules from the
zaptel-netbsd package.  When I load the ztdummy module,  which uses functions
from the zaptel module, I get the following output:

#/etc/rc.d/lkm3 start

mod_zaptel.o: Module loaded as ID 0
mod_ztdummy.o: /usr/pkg/lkm/mod_ztdummy.o: In function `ztdummy_timer':
 undefined reference to `zt_receive'
 undefined reference to `zt_transmit'
/usr/pkg/lkm/mod_ztdummy.o: In function `cleanup_module':
 undefined reference to `zt_unregister'
/usr/pkg/lkm/mod_ztdummy.o: In function `ztdummy_initialize':
 undefined reference to `zt_register'
modload: can't prelink `/usr/pkg/lkm/mod_ztdummy.o' creating 

        Is there a reason why the linker can't see the symbols from the first
module when loading the second module?  Is it easily worked around?

Home | Main Index | Thread Index | Old Index