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

Re: [Xen-devel] proper way to build out-of-tree module



>>> "Cihula, Joseph" <joseph.cihula@xxxxxxxxx> 25.10.07 08:47 >>>
>I'm trying to build a kernel module for dom0 where the source code for
>the module resides in a directory other than the linux src tree (it is
>is $(XEN_ROOT)/tboot/txt-test).
>
>I though that what I needed to do was to first build the .o in the local
>dir then do:
>       $(MAKE) -C $(XEN_ROOT)/build-linux-2.6.18-xen_x86_64 M=$(CURDIR) modules
>
>And for the .o build, I set the include path to be
>-I$(XEN_ROOT)/linux-2.6.18-xen.hg/include.
>
>However, when the source file tries to #include <linux/delay.h> it
>returns an error:
>       In file included from txt-test.c:39:
>       
> /xen/xen-txt.hg/tboot/txt-test/../../linux-2.6.18-xen.hg/include/linux/delay.h:12:23:
>  error: asm/delay.h: No such file or directory
>since there is no 'asm' link to 'asm-x86_64' in the linux src tree.

It's really not the source tree you need to point to, but the object tree
(which can be the same, but don't have to, but even if they are it
implies that a certain level of building must have happened in that tree,
namely iirc up to 'make prepare'). I am actually about to send a patch
to correct the respective instructions in unmodified_drivers/.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.