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

Re: [Xen-users] Mini-OS library linking



On Fri, 2012-08-10 at 19:19 +0100, Adrian Shaw wrote:
> Hi all,
> 
> I'm trying to cross compile a library so it can be used in a Mini-OS
> C-stubdomain.

The mini-os/stubdom build system is a bit of a black art. It might help
if you were to publish your patches so we can see/understand what you
are doing.

> 
> I have added the necessary rules to the stubdom Makefile to compile my
> library.
> The resulting static library file (.a file) I've placed with the other
> static libraries like libm.a, libc.a, libz.a, libnosys.a etc (they are
> all in a directory called
> stubdom/cross-root-x86_64/x86_64(something)/lib/
> I have also copied my library header file into the Mini-OS include
> directory in extras/mini-os/include.
> 
> However, I am finding it very hard to find where to specify the
> linking to my static library.
> In my main.c file in stubdom/c I keep getting undefined reference
> errors.
> 
> Please tell me if I'm going about this the wrong way. 
> I was just going by how the other libraries seem to have been compiled
> in.
> What are the few things I need to have in place for me to use
> functions in main.c?
> 
> I'm aware that this might be a daft question, but the makefile isn't
> clear to me.
> 
> Regards,
> 
> Adrian
> 
> PS: I also tried to add my .a static library into the APP_OBJS in the
> c-stubdom rule, but it didn't work (complaining about no rule for that
> target - why should I need one?)
> 



_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users


 


Rackspace

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