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

Re: [libvirt] The last two remaining "out of the box" build failures for OS X



On Wed, Sep 29, 2010 at 8:04 AM, Justin Clift <jclift redhat com> wrote:
> Hi all,
>
> On the home straight getting libvirt to work "out of the box" on MacOS X.
>  (ideal scenario: it's "good enough" today. :>)

I applaud all your efforts that you've been doing for sure!
<snip>

>
>  + Leaving off --without-storage-fs gives
>
> ***********************************************************************
>
>  gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../gnulib/lib -I../gnulib/lib
> -I../include -I../src/util -I../include -I/usr/include/libxml2
> -DLIBDIR=\"/opt/libvirt/lib\" -DBINDIR=\"/opt/libvirt/libexec\"
> -DSBINDIR=\"/opt/libvirt/sbin\" -DSYSCONF_DIR=\"/opt/libvirt/etc\"
> -DLOCALEBASEDIR=\"/opt/libvirt/share/locale\"
> -DPKGDATADIR=\"/opt/libvirt/share/libvirt\"
> -DLOCAL_STATE_DIR=\"/opt/libvirt/var\" -DGETTEXT_PACKAGE=\"libvirt\" -Wall
> -Wformat -Wformat-security -Wmissing-prototypes -Wnested-externs
> -Wpointer-arith -Wextra -Wshadow -Wcast-align -Wwrite-strings
> -Waggregate-return -Wstrict-prototypes -Winline -Wredundant-decls
> -Wno-sign-compare -Wp,-D_FORTIFY_SOURCE=2 -fexceptions
> -fasynchronous-unwind-tables -fdiagnostics-show-option -DIN_LIBVIRT
> -I../src/conf -g -O2 -MT libvirt_driver_storage_la-storage_backend_fs.lo -MD
> -MP -MF .deps/libvirt_driver_storage_la-storage_backend_fs.Tpo -c
> storage/storage_backend_fs.c  -fno-common -DPIC -o
> .libs/libvirt_driver_storage_la-storage_backend_fs.o
> storage/storage_backend_fs.c:145:21: error: mntent.h: No such file or
> directory
> storage/storage_backend_fs.c: In function
> 'virStorageBackendFileSystemIsMounted':
> storage/storage_backend_fs.c:274: error: storage size of 'ent' isn't known
> storage/storage_backend_fs.c:277: error: '_PATH_MOUNTED' undeclared (first
> use in this function)
> storage/storage_backend_fs.c:277: error: (Each undeclared identifier is
> reported only once
> storage/storage_backend_fs.c:277: error: for each function it appears in.)
> storage/storage_backend_fs.c:284: warning: implicit declaration of function
> 'getmntent_r'
> storage/storage_backend_fs.c:284: warning: nested extern declaration of
> 'getmntent_r' [-Wnested-externs]
> storage/storage_backend_fs.c:284: warning: comparison between pointer and
> integer
> storage/storage_backend_fs.c:274: warning: unused variable 'ent'
> [-Wunused-variable]
> make[3]: *** [libvirt_driver_storage_la-storage_backend_fs.lo] Error 1
> make[3]: *** Waiting for unfinished jobs....
> make[2]: *** [all] Error 2
> make[1]: *** [all-recursive] Error 1
> make: *** [all] Error 2
> $
>

I know mntent.h functions are SunOS and glibc only. Specifically
getmntent_r() is purely a glibc only function. The BSDs (and Mac OS X
by extension) use getfsstat() and getmntinfo(). The latter I believe
gives data closer to what you're looking for I believe. I don't have
my Mac with me right now but if you want prod me off list and maybe we
can work up a work around that will handle this case properly and that
will support the BSDs as well as Mac OS X.

-- 
Doug Goldstein


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