[libvirt] Works: libvirt client on OS X 10.5.6
Schley Andrew Kutz
sakutz at gmail.com
Wed May 20 13:07:37 UTC 2009
I didn't see your earlier response on those. As for WEXITSTATUS I have
no idea why it broke, but as it always compared it to Zero anyway, I
just short circuited the evaluation. The MACOSX_DEPLOYMENT_TARGET is a
different kind of issue. The libraries that libvirt links to, gnutls
and its dependencies, are apparently hard-wired to use OS X 10.4,
which doesn't define the symbol UNX2003. When I compile libvirt
manually, it is linking to 10.5, and because of this, it expects
itself and its dependencies to know about UNX2003 -- which they don't.
So I built libvirt at a 10.4 level instead of 10.5 rather than build
all of its dependencies by hand (MacPorts is sort of like apt-get or
yum -- except it allows OS X devs to easily install Unix tools on
their Macs).
--
-a
"Ideally, a code library must be immediately usable by naive
developers, easily customized by more sophisticated developers, and
readily extensible by experts." -- L. Stein
On May 20, 2009, at 7:55 AM, Daniel Veillard wrote:
> On Wed, May 20, 2009 at 07:40:43AM -0500, Schley Andrew Kutz wrote:
>> I will create a specific sub-dir and let you know.
>>
>
> okay thanks, any feedback on the two other issues ?
>
>>>>> On Thu, May 07, 2009 at 11:50:25PM -0500, Schley Andrew Kutz
>>>>> wrote:
>>>>>> - Set environment variables:
>>>>>>
>>>>>> export LDFLAGS="-L/opt/local/lib"
>>>>>> export CPPFLAGS="-I/opt/local/include"
>>>>>> export MACOSX_DEPLOYMENT_TARGET=10.4
>>>>>> src/virsh.c:5665
> [...]
>>>>>>
>>>>>> if (command_ret != 0 /* WEXITSTATUS (0) */) {
>>>
>>> That's bizarre ...
>>>
>>> WEXITSTATUS is defined in virsh.c:
>>>
>>> #ifndef WEXITSTATUS
>>> # define WEXITSTATUS(x) ((x) & 0xff)
>>> #endif
>>>
>>> it's used only once at the place you pointed out:
>>>
>>> if (command_ret != WEXITSTATUS (0)) {
>>>
>>> I think it was used for cygwin portability, but in that
>>> case I would have expected
>>>
>>> if (WEXITSTATUS(command_ret) != 0) {
>>>
>>> Why did this break on OS-X ?
>
> Any idea about this ?
>
>>>>> That's great - we can easily fix these 2 bugs.
>>>>>
>>>>>> - Compile
>>>>>>
>>>>>> The MACOSX_DEPLOYMENT_TARGET variable is very important,
>>>>>> otherwise
>>>>>> you
>>>>>> will get symbol errors when linking.
>>>
>>> What about detecting MACOSX_DEPLOYMENT_TARGET, because I assume it
>>> will change from one environment to another, do this in configure.in
>>> and
>>> export is in all Makefiles.am ? There must be a way to export the
>>> env
>>> variable from the generated Makefiles surely...
>
> and this ?
>
> Daniel
>
> --
> Daniel Veillard | libxml Gnome XML XSLT toolkit http://xmlsoft.org/
> daniel at veillard.com | Rpmfind RPM search engine http://rpmfind.net/
> http://veillard.com/ | virtualization library http://libvirt.org/
More information about the libvir-list
mailing list