Minor compile failure on OSX for libvirt 2.0.0

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

 



Hi all,

There's a minor compile failure on OSX with libvirt 2.0.0:

    CC       util/libvirt_util_la-virtime.lo
    CC       util/libvirt_util_la-virtpm.lo
  util/virsystemd.c:524:26: error: use of undeclared identifier 'MSG_NOSIGNAL'
      if (sendmsg(fd, &mh, MSG_NOSIGNAL) < 0)
                           ^
  1 error generated.
  make[3]: *** [util/libvirt_util_la-virsystemd.lo] Error 1
  make[3]: *** Waiting for unfinished jobs....

Seems solvable by adding a stub declaration for MSG_NOSIGNAL on
systems that don't implement it.

An initial patch with the declaration, developed by Tomasz Pajor
(CC'd), is below:

  --- src/util/virsystemd.h.orig	2016-07-03 21:40:12.000000000 +0200
  +++ src/util/virsystemd.h	2016-07-03 21:37:53.000000000 +0200
  @@ -57,3 +57,7 @@
   char *virSystemdGetMachineNameByPID(pid_t pid);
 
   #endif /* __VIR_SYSTEMD_H__ */
  +
  +#ifndef MSG_NOSIGNAL
  +#define MSG_NOSIGNAL 0x0 //Don't request NOSIGNAL on systems where this is not implemented.
  +#endif

It's outside the #endif for __VIR_SYSTEMD_H___ though, so I'm kind of
thinking it would need to be move inside the guard (which also compiles
ok), or is there a better place/file for it instead? :)

Regards and best wishes,

Justin Clift

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
- Indira Gandhi


--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]