Bug#780582: pcl FTBFS on mips/mipsel - virtual memory exhausted

Dejan Latinovic Dejan.Latinovic at imgtec.com
Mon Mar 16 10:37:43 UTC 2015

Package: pcl
Version: 1.7.2-7
Tags: sid patch
Severity: important
Justification: FTBFS
User: debian-mips at lists.debian.org
Usertags: mips-patch

While trying to build pcl on mips/mipsel architecture,
build fails with an error:

> [ 54%] Building CXX object recognition/CMakeFiles/pcl_recognition.dir/src/cg/geometric_consistency.cpp.o
> cd /«PKGBUILDDIR»/build/recognition && /usr/bin/c++   -DEIGEN_USE_NEW_STDVECTOR -DEIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET -DPCLAPI_EXPORTS -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NO_DEBUG -Dqh_QHpointer -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -D_FORTIFY_SOURCE=2  -pthread -fopenmp -fPIC -isystem /usr/include/eigen3 -I/«PKGBUILDDIR»/recognition/include/pcl/recognition/3rdparty -isystem /usr/include/qt4 -isystem /usr/include/qt4/QtGui -isystem /usr/include/qt4/QtCore -I/«PKGBUILDDIR»/build/include -I/«PKGBUILDDIR»/common/include -I/«PKGBUILDDIR»/io/include -I/«PKGBUILDDIR»/search/include -I/«PKGBUILDDIR»/kdtree/include -I/«PKGBUILDDIR»/octree/include -I/«PKGBUILDDIR»/features/include -I/«PKGBUILDDIR»/filters/include -I/«PKGBUILDDIR»/registration/include -I/«PKGBUILDDIR»/sample_consensus/include -I/«PKGBUILDDIR»/recognition/include    -o CMakeFiles/pcl_recognition.dir/src/cg/geometric_consistency.cpp.o -c /«PKGBUILDDIR»/recognition/src/cg/geometric_consistency.cpp
> virtual memory exhausted: Cannot allocate memory
> make[3]: *** [recognition/CMakeFiles/pcl_recognition.dir/src/cg/geometric_consistency.cpp.o] Error 1

I was able to avoid this error adding
--param ggc-min-expand=20 to CXXFLAGS for mips and mipsel.

With this change I was able to build pcl for mipsel,
but for mips on cavium boards build failed with TERM signal
on documentation creation.

> cd /«PKGBUILDDIR»/build/doc/doxygen && /usr/bin/doxygen /build/pcl-IE8AwS/pcl-1.7.2/build/doc/doxygen/doxyfile
> make[3]: *** [doc/doxygen/CMakeFiles/doc] Terminated
> doc/doxygen/CMakeFiles/doc.dir/build.make:52: recipe for target 'doc/doxygen/CMakeFiles/doc' failed
> make: *** [build] Terminated
> debian/rules:97: recipe for target 'build' failed
> CMakeFiles/Makefile2:6961: recipe for target 'doc/doxygen/CMakeFiles/doc.dir/all' failed
> make[2]: *** [doc/doxygen/CMakeFiles/doc.dir/all] Terminated
> make[1]: *** [all] Terminated
> Makefile:150: recipe for target 'all' failed
> E: Caught signal Terminated: terminating immediately
> Build killed with signal TERM after 150 minutes of inactivity

If run this command manually,
it finish successfully, but it takes a lot of time.
> real    607m28.120s
> user    109m50.490s
> sys    496m40.580s

As on debian buildds build is run for architecture dependent
part of packages only ("build-arch"), I think that creation of documentation for
every architecture is not necessary.
Instead, we could disable documentation creation if
build is run with "build-arch" and use -DWITH_DOCS=ON only when
build is run with "build".
Also, there is no need to install doxygen if
not using it.

I attached the patch that contains all mentioned changes.
After applying this patch,
I was able to build pcl successfully for mips and mipsel on a few local boards.
The patch is attached.

Could you please consider including this patch?

Best Regards,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ggc-min-expand+disable-WITH_DOCS.diff
Type: text/x-patch
Size: 1751 bytes
Desc: ggc-min-expand+disable-WITH_DOCS.diff
URL: <http://lists.alioth.debian.org/pipermail/debian-science-maintainers/attachments/20150316/e126cbf3/attachment-0001.bin>

More information about the debian-science-maintainers mailing list