<div dir="ltr">Hi Lonni,<div><br></div><div>Do you happen to have an HDF5 distribution on your default include path? I ran into this issue when I installed HDF5 through Homebrew on my Mac. I switched to using system HDF5 and NetCDF to avoid these errors. The problem is that VTK include certain include paths where external libraries reside, such as /usr/local/include, before it includes the internal HDF5 include path. So the HDF5 files in VTK end up being compiled with include files from the system.</div><div><br></div><div>Best,</div><div>-berk</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 10, 2016 at 11:19 AM, Lonni Besançon <span dir="ltr"><<a href="mailto:lonni.besancon@gmail.com" target="_blank">lonni.besancon@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello everyone,<br>
<br>
I used to be able to build my android examples just fine. But since I<br>
rebuilt vtk I seem to have a problem.<br>
I get the following errors:<br>
<br>
/In file included from<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:46:0:<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c: In<br>
function 'print_header':<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:191:30:<br>
error: 'struct passwd' has no member named 'pw_gecos'<br>
      if((comma = HDstrchr(pwd->pw_gecos, ','))) {<br>
                              ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5private.h:1224:37: note: in<br>
definition of macro 'HDstrchr'<br>
     #define HDstrchr(S,C)    strchr(S,C)<br>
                                     ^<br>
In file included from<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:46:0:<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:192:56:<br>
error: 'struct passwd' has no member named 'pw_gecos'<br>
   n = MIN(sizeof(real_name) - 1, (unsigned)(comma - pwd->pw_gecos));<br>
                                                        ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5private.h:331:28: note: in<br>
definition of macro 'MIN'<br>
 #define MIN(a,b)    (((a)<(b)) ? (a) : (b))<br>
                            ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:192:56:<br>
error: 'struct passwd' has no member named 'pw_gecos'<br>
   n = MIN(sizeof(real_name) - 1, (unsigned)(comma - pwd->pw_gecos));<br>
                                                        ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5private.h:331:41: note: in<br>
definition of macro 'MIN'<br>
 #define MIN(a,b)    (((a)<(b)) ? (a) : (b))<br>
                                         ^<br>
In file included from<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:46:0:<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:193:27:<br>
error: 'struct passwd' has no member named 'pw_gecos'<br>
   HDstrncpy(real_name, pwd->pw_gecos, n);<br>
                           ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5private.h:1257:41: note: in<br>
definition of macro 'HDstrncpy'<br>
     #define HDstrncpy(X,Y,Z)  strncpy(X,Y,Z)<br>
                                         ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5make_libsettings.c:197:27:<br>
error: 'struct passwd' has no member named 'pw_gecos'<br>
   HDstrncpy(real_name, pwd->pw_gecos, sizeof(real_name));<br>
                           ^<br>
/Users/user/VTK/ThirdParty/hdf5/vtkhdf5/src/H5private.h:1257:41: note: in<br>
definition of macro 'HDstrncpy'<br>
     #define HDstrncpy(X,Y,Z)  strncpy(X,Y,Z)<br>
                                         ^<br>
make[3]: ***<br>
[ThirdParty/hdf5/vtkhdf5/src/CMakeFiles/H5make_libsettings.dir/H5make_libsettings.c.o]<br>
Error 1<br>
make[2]: ***<br>
[ThirdParty/hdf5/vtkhdf5/src/CMakeFiles/H5make_libsettings.dir/all] Error 2<br>
make[1]: ***<br>
[Examples/Android/VolumeRender/CMakeFiles/VolumeRender-apk-debug.dir/rule]<br>
Error 2<br>
make: ***<br>
[Examples/Android/VolumeRender/CMakeFiles/VolumeRender-apk-debug.dir/rule]<br>
Error 2<br>
/<br>
<br>
I guess I'm not the only one to whom it's happening since I saw this post as<br>
well:  <a href="http://www.vtk.org/pipermail/vtk-developers/2013-August/014195.html" rel="noreferrer" target="_blank">http://www.vtk.org/pipermail/vtk-developers/2013-August/014195.html</a><br>
<<a href="http://www.vtk.org/pipermail/vtk-developers/2013-August/014195.html" rel="noreferrer" target="_blank">http://www.vtk.org/pipermail/vtk-developers/2013-August/014195.html</a>><br>
However, no solution is provided in this post.<br>
<br>
Would you happen to know what's responsible for that error and how I can fix<br>
it (or at the very least bypass it)?<br>
<br>
Thanks in advance<br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://vtk.1045678.n5.nabble.com/Compilation-error-hdf5-tp5736481.html" rel="noreferrer" target="_blank">http://vtk.1045678.n5.nabble.com/Compilation-error-hdf5-tp5736481.html</a><br>
Sent from the VTK - Dev mailing list archive at Nabble.com.<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtk-developers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtk-developers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtk-developers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtk-developers</a><br>
<br>
</blockquote></div><br></div>