Opened 6 years ago

Last modified 5 years ago

#56430 closed defect

libpcl fails to build — at Version 7

Reported by: dershow Owned by: luminans@…
Priority: Normal Milestone:
Component: ports Version:
Keywords: haspatch Cc: Veence (Vincent), tiktaktok (Mathieu Clement)
Port: libpcl

Description (last modified by ryandesign (Ryan Carsten Schmidt))

I've been trying to install the libpcl port, but not having any luck. First I ran into the this problem: #49418 as vtk5 is a dependent. I followed the workaround listed and got vtk5 to install, and tried libpcl again. This time I got this error:

--->  Configuring libpcl
Error: Failed to configure libpcl: vtk5 must be installed with +qt4_mac.

So, it seems that libpcl doesn't list the correct variant of vtk5. I installed that variant of vtk5 (I didn't have to redo the work around, I was just able to install it).

Then, I again tried to install libpcl. This time, I got a build error part way through.

$ sudo port  install libpcl
--->  Computing dependencies for libpcl
--->  Configuring libpcl
--->  Building libpcl
Error: Failed to build libpcl: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/main.log for details.
Error: Follow https://guide.macports.org/#project.tickets to report a bug.
Error: Processing of port libpcl failed

I've attached the build log file of this build attempt.

Change History (9)

Changed 6 years ago by dershow

Attachment: main.log added

comment:1 Changed 6 years ago by ctreleaven (Craig Treleaven)

Resolution: invalid
Status: newclosed

This is intended behaviour. The portfile for libpcl checks that you have vtk5 installed with the (non-default) +qt4_mac variant. It spits out the message above telling the user what must be done to successfully install libpcl. This is the best we can do since MacPorts does not have the facility to automatically install specific variants of a particular port.

comment:2 Changed 6 years ago by dershow

Resolution: invalid
Status: closedreopened

The response was not to the main problem. But, only to the one leading up to it. I included that info, so that anyone trying to reproduce the build will understand how to get things going. Further down in the initial post, I explained that once I installed the correct variant, it still doesn't build. That is the big problem, not the multiple steps required to get to that point.

comment:3 Changed 6 years ago by raimue (Rainer Müller)

The actual error appears to be this one:

:info:build [ 53%] Building CXX object features/CMakeFiles/pcl_features.dir/src/crh.cpp.o
:info:build cd /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features && /usr/bin/clang++  -DEIGEN_USE_NEW_STDVECTOR -DEIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET -DPCLAPI_EXPORTS -DQT_CONCURRENT_LIB -DQT_CORE_LIB -DQT_GUI_LIB -DQT_OPENGL_LIB -DQT_WIDGETS_LIB -Dqh_QHpointer -isystem /opt/local/include -isystem /opt/local/include/eigen3 -isystem /opt/local/include/ni -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/recognition/include/pcl/recognition/3rdparty -F/opt/local/libexec/qt5/lib -I/opt/local/libexec/qt5/lib/QtCore.framework/Headers -I/opt/local/libexec/qt5/./mkspecs/macx-clang -I/opt/local/libexec/qt5/lib/QtGui.framework/Headers -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/opt/local/libexec/qt5/lib/QtWidgets.framework/Headers -I/opt/local/libexec/qt5/lib/QtConcurrent.framework/Headers -I/opt/local/libexec/qt5/lib/QtOpenGL.framework/Headers -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/common/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/search/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/kdtree/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/octree/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/filters/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/include  -pipe -Os -stdlib=libc++      -DNDEBUG -arch x86_64 -mmacosx-version-min=10.13 -fPIC   -DBOOST_DISABLE_ASSERTS -DEIGEN_NO_DEBUG -o CMakeFiles/pcl_features.dir/src/crh.cpp.o -c /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/src/crh.cpp
:info:build In file included from /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/src/cppf.cpp:40:
:info:build In file included from /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/include/pcl/features/impl/cppf.hpp:44:
:info:build In file included from /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/include/pcl/features/cppf.h:43:
:info:build In file included from /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/include/pcl/features/feature.h:48:
:info:build In file included from /opt/local/include/boost/function.hpp:30:
:info:build In file included from /opt/local/include/boost/function/detail/prologue.hpp:17:
:info:build In file included from /opt/local/include/boost/function/function_base.hpp:21:
:info:build In file included from /opt/local/include/boost/type_index.hpp:29:
:info:build In file included from /opt/local/include/boost/type_index/stl_type_index.hpp:46:
:info:build In file included from /opt/local/include/boost/functional/hash.hpp:6:
:info:build In file included from /opt/local/include/boost/functional/hash/hash.hpp:594:
:info:build In file included from /opt/local/include/boost/functional/hash/extensions.hpp:22:
:info:build In file included from /opt/local/include/boost/detail/container_fwd.hpp:94:
:info:build /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/map:818:5: error: static_assert failed "Allocator::value_type must be same type as value_type"
:info:build     static_assert((is_same<typename allocator_type::value_type, value_type>::value),
:info:build     ^             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
:info:build /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__config:783:36: note: expanded from macro 'static_assert'
:info:build #   define static_assert(__b, __m) _Static_assert(__b, __m)
:info:build                                    ^              ~~~
:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_gis_libpcl/libpcl/work/pcl-1.7.2/features/include/pcl/features/pfh.h:211:131: note: in instantiation of template class 'std::__1::map<std::__1::pair<int, int>, Eigen::Matrix<float, 4, 1, 0, 4, 1>, std::__1::less<std::__1::pair<int, int> >, Eigen::aligned_allocator<Eigen::Matrix<float, 4, 1, 0, 4, 1> > >' requested here
:info:build       std::map<std::pair<int, int>, Eigen::Vector4f, std::less<std::pair<int, int> >, Eigen::aligned_allocator<Eigen::Vector4f> > feature_map_;
:info:build                                                                                                                                   ^

comment:4 Changed 6 years ago by mf2k (Frank Schima)

Cc: luminans@… removed
Owner: set to luminans@…
Status: reopenedassigned

comment:5 Changed 6 years ago by ctreleaven (Craig Treleaven)

See attached patch. Updates libpcl to 1.8.1, now depends on vtk rather than elderly vtk5, adds default variant to build with clang-5.0 to enable OpenMP. Also enables unit tests although not all test pass on my system. Note that tests have to be run 'sudo port test libpcl +test'.

Should solved all other remaining libpcl tickets:

Also addresses #56422 by moving to cmake 1.1 portgroup.

Beware, takes a LONG time to build.

@Veence, let me know if you approve and I can commit this.

Last edited 6 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

Changed 6 years ago by ctreleaven (Craig Treleaven)

Attachment: libpcl_1.8.1_update.diff added

update to portfile

comment:6 Changed 6 years ago by pmetzger (Perry E. Metzger)

ctreleaven: you might want to do these changes as GitHub pull requests.

comment:7 Changed 6 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: tiktaktok added
Description: modified (diff)
Keywords: haspatch added

I'll mark the earlier #55022 as a duplicate of this one, since this one has the patch.

Note: See TracTickets for help on using tickets.