[Libvir] libvirt on OS X Leopard 10.5.1

Daniel P. Berrange berrange at redhat.com
Mon Jan 21 23:54:32 UTC 2008


On Mon, Jan 21, 2008 at 04:50:29PM -0600, Schley Andrew Kutz wrote:
> 5. Edit '/usr/include/net/if.h' and add the following include:
> 
>   #include <net/if_var.h>
>   #include <sys/types.h>
> 
>   //
>   // EDIT: akutz
>   //
>   #include <sys/socket.h>

This is curious - I'm puzzelled why libvirt source uses 'net/if.h' 
at all. This is for getting information about network interfaces
and not something that libvirt should need to use AFAICT. Perhaps
we should just remove 'net/if.h' from our code

> 6. Create a symlink for 'malloc.h' so the libvirt source can find it:
> 
> sudo ln -s /usr/include/malloc/malloc.h /usr/include/malloc.h

Again I'm puzzelled why libvirt includes malloc.h at all - the
definition  of malloc comes from stdlib.h. Historical accident
probably.

> 7. Add a header to "src/remote_internal.c":
> 
>   //
>   // EDIT: akutz
>   //
>   #include <sys/un.h>

Yep, this is a clear bug in our remote_internal.c file.

> 8. The version-script parameter of ld is not portable to OS X. Edit  
> 'src/Makefile':
> 
>   #
>   # EDIT: akutz
>   #
>   #libvirt_la_LDFLAGS = -Wl,--version-script=$(srcdir)/ 
> libvirt_sym.version \
>   #                     -version-info 4:0:4 \
>   #                    $(COVERAGE_CFLAGS:-f%=-Wc,-f%) \

Ok, we should be able to fix the makefile to only use libvirt_sym.version
when running on a suitable OS to avoid you needing to make this change.

So I reckon all 4 of these issues are easily fixable in libvirt source...

Regards,
Dan.
-- 
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 




More information about the libvir-list mailing list