Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Sep 2008 12:58:05 +0200
From:      =?UTF-8?Q?Nikola_Kne=C5=BEevi=C4=87?= <laladelausanne@gmail.com>
To:        freebsd-hackers@freebsd.org
Subject:   kldload: unexpected relocation type 10
Message-ID:  <0F17887A-AC71-49F0-B25D-8F2DC8BB5465@gmail.com>

next in thread | raw e-mail | index | archive | help
Hi guys,

I'm trying to do something unusual - to build my own module, mixed  
with the Click (Modular Router). In order to do so, I had to write a  
Makefile which borrows a lot from Click's Makefile. Like all other  
kernel modules, I include <bsd.kmod.ko>, but I'm modifying CFLAGS  
(with +=), and CXXFLAGS. I also have -DHAVE_INT64_IS_LONG there. For  
CXXFLAGS I use -fpermissive -fno-exceptions -fno-rtti.

I had to do all this creaziness because I had to build CLick first  
(its .cc files), and then link all them with my code.

Now I'm getting this:
"kldload: unexpected relocation type 10"

and:
"link_elf_obj: symbol M_TEMP undefined"

I cannot find where this M_TEMP comes from, because I'm including <sys/ 
malloc.h>. for the relocation, I don't know what to do. I'm not using - 
g, as described on some web forum.

Any hints?

Cheers,
Nikola
  



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?0F17887A-AC71-49F0-B25D-8F2DC8BB5465>