Forum Replies Created
-
AuthorPosts
-
adrienBlocked
Hello @hugo,
Thanks for your answer. The complete error is:
########## SIG 11 - SIGSEGV: segfault ########## -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaHelper.so.17.12.01(sofa::helper::BackTrace::dump()+0x20) [0x7f794cb58970] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaHelper.so.17.12.01(sofa::helper::BackTrace::sig(int)+0x358) [0x7f794cb58ee8] -> /lib64/libc.so.6(+0x36fb0) [0x7f7948ed8fb0] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaBaseLinearSolver.so.17.12.01(sofa::component::linearsolver::MatrixLinearSolver<sofa::component::linearsolver::GraphScatteredMatrix, sofa::component::linearsolver::GraphScatteredVector, sofa::component::linearsolver::NoThreadManager>::setSystemLHVector(sofa::core::TMultiVecId<(sofa::core::VecType)2, (sofa::core::VecAccess)1>)+0x154) [0x7f7955044d14] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaConstraint.so.17.12.01(sofa::component::constraintset::LinearSolverConstraintCorrection<sofa::defaulttype::StdVectorTypes<sofa::defaulttype::Vec<3, double>, sofa::defaulttype::Vec<3, double>, double> >::addComplianceInConstraintSpace(sofa::core::ConstraintParams const*, sofa::defaulttype::BaseMatrix*)+0xef) [0x7f7959539e2f] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaConstraint.so.17.12.01(sofa::component::constraintset::GenericConstraintSolver::buildSystem(sofa::core::ConstraintParams const*, sofa::core::TMultiVecId<(sofa::core::VecType)0, (sofa::core::VecAccess)1>, sofa::core::TMultiVecId<(sofa::core::VecType)0, (sofa::core::VecAccess)1>)+0x115e) [0x7f79594fea7e] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaCore.so.17.12.01(sofa::core::behavior::ConstraintSolver::solveConstraint(sofa::core::ConstraintParams const*, sofa::core::TMultiVecId<(sofa::core::VecType)0, (sofa::core::VecAccess)1>, sofa::core::TMultiVecId<(sofa::core::VecType)0, (sofa::core::VecAccess)1>)+0x3ae) [0x7f794e4dd64e] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaConstraint.so.17.12.01(sofa::component::animationloop::FreeMotionAnimationLoop::step(sofa::core::ExecParams const*, double)+0x2b11) [0x7f79594a2271] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaSimulationCore.so(sofa::simulation::Simulation::animate(sofa::simulation::Node*, double)+0x55) [0x7f794f0d8eb5] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaGuiQt.so.17.12.01(sofa::gui::qt::RealGUI::step()+0xdb) [0x7f7960fe863b] -> /lib64/libQt5Core.so.5(QMetaObject::activate(QObject*, int, int, void**)+0x64e) [0x7f7949aa1cbe] -> /lib64/libQt5Core.so.5(QTimer::timeout(QTimer::QPrivateSignal)+0x3b) [0x7f7949aade1b] -> /lib64/libQt5Core.so.5(QObject::event(QEvent*)+0xab) [0x7f7949aa29db] -> /lib64/libQt5Widgets.so.5(QApplicationPrivate::notify_helper(QObject*, QEvent*)+0x85) [0x7f794a83be95] -> /lib64/libQt5Widgets.so.5(QApplication::notify(QObject*, QEvent*)+0x21a) [0x7f794a84383a] -> /lib64/libQt5Core.so.5(QCoreApplication::notifyInternal2(QObject*, QEvent*)+0x86) [0x7f7949a79376] -> /lib64/libQt5Core.so.5(QTimerInfoList::activateTimers()+0x3f9) [0x7f7949ac8f19] -> /lib64/libQt5Core.so.5(+0x2be7bc) [0x7f7949ac97bc] -> /lib64/libglib-2.0.so.0(g_main_context_dispatch+0x15d) [0x7f7944d788ad] -> /lib64/libglib-2.0.so.0(+0x4cc78) [0x7f7944d78c78] -> /lib64/libglib-2.0.so.0(g_main_context_iteration+0x30) [0x7f7944d78d10] -> /lib64/libQt5Core.so.5(QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>)+0x63) [0x7f7949ac9c13] -> /lib64/libQt5XcbQpa.so.5(+0xd3065) [0x7f790fedd065] -> /lib64/libQt5Core.so.5(QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>)+0x13b) [0x7f7949a7812b] -> /lib64/libQt5Core.so.5(QCoreApplication::exec()+0x96) [0x7f7949a805b6] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaGuiQt.so.17.12.01(sofa::gui::qt::RealGUI::mainLoop()+0x182) [0x7f7960fdfc42] -> /home/stage/Documents/Adrien/sofa/build/build-v17.12/lib/libSofaGuiCommon.so.17.12.01(sofa::gui::GUIManager::MainLoop(boost::intrusive_ptr<sofa::simulation::Node>, char const*)+0x64) [0x7f7960aed064] -> ./bin/runSofa(main+0x3e3c) [0x41400c] -> /lib64/libc.so.6(__libc_start_main+0xeb) [0x7f7948ec518b] -> ./bin/runSofa(_start+0x2a) [0x40f8ea] Segmentation fault (core dumped)
And yes I have a simple scene:
import Sofa import SofaPython.Tools import os path_lo = os.path.dirname(os.path.abspath(__file__))+'/mesh/' def createScene(rootNode): rootNode.createObject('RequiredPlugin', name='SofaPython') rootNode.createObject('VisualStyle', displayFlags="showVisualModels showBehaviorModels hideCollisionModels hideBoundingCollisionModels showForceFields hideInteractionForceFields hideWireframe") rootNode.createObject('FreeMotionAnimationLoop', name='aniloop') rootNode.createObject('GenericConstraintSolver',name='genconsol', maxIterations='1000', tolerance = '1e-3',computeGraphs=True) rootNode.createObject('BackgroundSetting', color='0 0.168627 0.211765') rootNode.findData('gravity').value="0 0 -9.81" rootNode.findData('dt').value=0.01 tube = rootNode.createChild('tube') tube.createObject('RungeKutta4', name="odeExplicitSolver") tube.createObject('CGLinearSolver', iterations="800000", tolerance="1e-5", threshold="1e-5") tube.createObject('MeshVTKLoader', name='loader', filename=path_lo+'tubetronc_010-200.vtu', rotation="0 0 0") tube.createObject('TetrahedronSetTopologyContainer', src='@loader', name='container') tube.createObject('MechanicalObject', name='tubeMecha', template='Vec3d', showIndices='false', showIndicesScale='4e-5', rx='0', dz='0') tube.createObject('TetrahedronSetGeometryAlgorithms', template='Vec3d') tube.createObject('UniformMass', totalmass='9e-3') tube.createObject('TetrahedronFEMForceField', template='Vec3d', name='FEM', method='large', poissonRatio='0.26', youngModulus='5e9') tube.createObject('BoxROI', name='forceBox', box='-0.3 0.3 -0.3 0.3 0.9 0.3', drawBoxes='true', position="@tubeMecha.rest_position", tetrahedra="@container.tetrahedra") tube.createObject('BoxROI', name='fixedBox', box='-0.3 -0.01 -0.3 0.3 -0.45 0.3', drawBoxes='true', position="@tubeMecha.rest_position", tetrahedra="@container.tetrahedra") tube.createObject('RestShapeSpringsForceField', points='@fixedBox.indices', stiffness='1e12') tube.createObject('ConstantForceField', name='forceField',totalForce='0.0 -600.0 0.0', indices='@forceBox.indices', arrowSizeCoef=".01") tube.createObject('FixedConstraint', indices='@fixedBox.indices') tube.createObject('LinearSolverConstraintCorrection') tubeVisu = tube.createChild('visu') tubeVisu.createObject('OglModel', filename=path_lo+"tubetronc20.stl", color="0.4 0.4 0.4 0.5") tubeVisu.createObject('BarycentricMapping')
Thanks in advance for your help.
adrienBlockedI used clang and it worked.
Thank you for your help and for your availability.
adrienBlockedHow do you know that I used GCC for the compilation because I did not find any references to GCC? It’s just to understand how it works.
adrienBlockedI used your command line
$ sudo dnf install -y gcc-c++ clang cmake cmake-gui git qt5-devel boost-devel python2-devel libpng-devel libjpeg-turbo-devel libtiff-devel zlib-devel glew-devel
it installed the package qt5-devel ( I already installed qt thanks to the link that is given in SOFA documentation) then the cmake configuration worked.Thanks that helped me.
However, there is still an error when I tried to compile with ninja or make (after generation of Makefile) :
/home/stage/Documents/Adrien/sofa/src/SofaGeneral/../modules/SofaBoundaryCondition/FixedPlaneConstraint.inl:173:31: requis par « void sofa::component::projectiveconstraintset::FixedPlaneConstraint<DataTypes>::projectResponse(const sofa::core::MechanicalParams*, sofa::component::projectiveconstraintset::FixedPlaneConstraint<DataTypes>::DataVecDeriv&) [avec DataTypes = sofa::defaulttype::StdRigidTypes<3, double>; sofa::component::projectiveconstraintset::FixedPlaneConstraint<DataTypes>::DataVecDeriv = sofa::core::objectmodel::Data<sofa::helper::vector<sofa::defaulttype::RigidDeriv<3, double>, sofa::helper::CPUMemoryManager<sofa::defaulttype::RigidDeriv<3, double> > > >; typename DataTypes::VecDeriv = sofa::helper::vector<sofa::defaulttype::RigidDeriv<3, double>, sofa::helper::CPUMemoryManager<sofa::defaulttype::RigidDeriv<3, double> > >] » /home/stage/Documents/Adrien/sofa/src/modules/SofaBoundaryCondition/FixedPlaneConstraint.cpp:58:44: requis depuis ici /home/stage/Documents/Adrien/sofa/src/modules/SofaBoundaryCondition/FixedPlaneConstraint.cpp:74:100: erreur interne du compilateur: dans type_dependent_expression_p, à cp/pt.c:25100 for (helper::vector< unsigned int > ::const_iterator it = this->indices.getValue().begin(); it != this->indices.getValue().end(); ++it) ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Veuillez soumettre un rapport d’anomalies complet, avec la sortie du préprocesseur si nécessaire. Voir <http://bugzilla.redhat.com/bugzilla> pour les instructions. La source convertie par le préprocesseur a été stockée dans le fichier /tmp/ccVMjYoh.out, veuillez l'attacher à votre rapport d'anomalie. make[2]: *** [SofaGeneral/SofaBoundaryCondition/CMakeFiles/SofaBoundaryCondition.dir/build.make:167: SofaGeneral/SofaBoundaryCondition/CMakeFiles/SofaBoundaryCondition.dir/FixedPlaneConstraint.cpp.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:3112: SofaGeneral/SofaBoundaryCondition/CMakeFiles/SofaBoundaryCondition.dir/all] Error 2 make: *** [Makefile:163: all] Error 2
I don’t understand what it means precisely. Do you have an idea about it ?
adrienBlockedI tried the compilation with an empty build directory and with any options for cmake and it seems that nothing has changed.
Determining if the function pthread_create exists in the pthreads failed with the following output: Change Dir: /home/stage/Documents/Adrien/sofa/build/build-v17.12/CMakeFiles/CMakeTmp Run Build Command:"/usr/bin/gmake" "cmTC_2accb/fast" /usr/bin/gmake -f CMakeFiles/cmTC_2accb.dir/build.make CMakeFiles/cmTC_2accb.dir/build gmake[1] : on entre dans le répertoire « /home/stage/Documents/Adrien/sofa/build/build-v17.12/CMakeFiles/CMakeTmp » Building C object CMakeFiles/cmTC_2accb.dir/CheckFunctionExists.c.o /usr/bin/clang -DCHECK_FUNCTION_EXISTS=pthread_create -o CMakeFiles/cmTC_2accb.dir/CheckFunctionExists.c.o -c /usr/share/cmake/Modules/CheckFunctionExists.c Linking C executable cmTC_2accb /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_2accb.dir/link.txt --verbose=1 /usr/bin/clang -DCHECK_FUNCTION_EXISTS=pthread_create -rdynamic CMakeFiles/cmTC_2accb.dir/CheckFunctionExists.c.o -o cmTC_2accb -lpthreads /usr/bin/ld : ne peut trouver -lpthreads clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation) gmake[1]: *** [CMakeFiles/cmTC_2accb.dir/build.make:87: cmTC_2accb] Error 1 gmake[1] : on quitte le répertoire « /home/stage/Documents/Adrien/sofa/build/build-v17.12/CMakeFiles/CMakeTmp » gmake: *** [Makefile:126: cmTC_2accb/fast] Error 2
adrienBlockedI installed
glibc-static
package andglibc-devel
package was already installed
1. `[stage@port_poire ~]$ rpm -qf /usr/lib64/libpthread-stubs.so.0
libpthread-stubs-0.2-5.2.x86_64`2. `[stage@port_poire ~]$ rpm -qf /usr/lib64/libpthread.a
glibc-static-2.27-15.fc28.x86_64`3. `[stage@port_poire ~]$ cat /usr/lib64/libpthread.so
/* GNU ld script
Use the shared library, but some functions are only in
the static library, so try that secondarily. */
OUTPUT_FORMAT(elf64-x86-64)
GROUP ( /lib64/libpthread.so.0 /usr/lib64/libpthread_nonshared.a )`adrienBlocked[stage@port_poire ~]$ ll /usr/lib64 | grep -i pthread lrwxrwxrwx. 1 root root 30 15 févr. 17:28 libevent_pthreads-2.1.so.6 -> libevent_pthreads-2.1.so.6.0.2 -rwxr-xr-x. 1 root root 11416 15 févr. 17:28 libevent_pthreads-2.1.so.6.0.2 lrwxrwxrwx. 1 root root 27 8 févr. 03:53 libgpgme++-pthread.so.2 -> libgpgme++-pthread.so.2.8.0 -rwxr-xr-x. 1 root root 354104 8 févr. 03:54 libgpgme++-pthread.so.2.8.0 lrwxrwxrwx. 1 root root 37 8 févr. 11:00 liblttng-ust-pthread-wrapper.so.0 -> liblttng-ust-pthread-wrapper.so.0.0.0 -rwxr-xr-x. 1 root root 24824 8 févr. 11:00 liblttng-ust-pthread-wrapper.so.0.0.0 -rwxr-xr-x. 1 root root 154128 24 mai 17:38 libpthread-2.27.so -rw-r--r--. 1 root root 164048 24 mai 17:38 libpthread.a -rw-r--r--. 1 root root 1724 24 mai 17:38 libpthread_nonshared.a -rw-r--r--. 1 root root 222 24 mai 17:36 libpthread.so lrwxrwxrwx. 1 root root 18 24 mai 17:36 libpthread.so.0 -> libpthread-2.27.so lrwxrwxrwx. 1 root root 25 10 mars 2017 libpthread-stubs.so.0 -> libpthread-stubs.so.0.0.0 -rwxr-xr-x. 1 root root 6768 10 mars 2017 libpthread-stubs.so.0.0.0
adrienBlockedyes, of course:
[stage@port_poire ~]$ /usr/bin/clang --version clang version 6.0.0 (tags/RELEASE_600/final) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /usr/bin
[stage@port_poire ~]$ /usr/bin/ld --verbose | grep SEARCH SEARCH_DIR("=/usr/x86_64-redhat-linux/lib64"); SEARCH_DIR("=/usr/lib64"); SEARCH_DIR("=/usr/local/lib64"); SEARCH_DIR("=/lib64"); SEARCH_DIR("=/usr/x86_64-redhat-linux/lib"); SEARCH_DIR("=/usr/local/lib"); SEARCH_DIR("=/lib"); SEARCH_DIR("=/usr/lib");
[stage@port_poire ~]$ CURDIR=$PWD; cd /tmp && cp /usr/share/cmake/Modules/CheckFunctionExists.c . && /usr/bin/clang -DCHECK_FUNCTION_EXISTS=pthread_create -o CheckFunctionExists.c.o -c CheckFunctionExists.c && /usr/bin/clang -DCHECK_FUNCTION_EXISTS=pthread_create -rdynamic CheckFunctionExists.c.o -o CheckFunctionExists -lpthread -v; rm CheckFunctionExists*; cd $CURDIR clang version 6.0.0 (tags/RELEASE_600/final) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /usr/bin Found candidate GCC installation: /usr/bin/../lib/gcc/x86_64-redhat-linux/8 Found candidate GCC installation: /usr/lib/gcc/x86_64-redhat-linux/8 Selected GCC installation: /usr/bin/../lib/gcc/x86_64-redhat-linux/8 Candidate multilib: .;@m64 Candidate multilib: 32;@m32 Selected multilib: .;@m64 "/usr/bin/ld" -export-dynamic --hash-style=gnu --no-add-needed --build-id --eh-frame-hdr -m elf_x86_64 -export-dynamic -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o CheckFunctionExists /usr/bin/../lib/gcc/x86_64-redhat-linux/8/../../../../lib64/crt1.o /usr/bin/../lib/gcc/x86_64-redhat-linux/8/../../../../lib64/crti.o /usr/bin/../lib/gcc/x86_64-redhat-linux/8/crtbegin.o -L/usr/bin/../lib/gcc/x86_64-redhat-linux/8 -L/usr/bin/../lib/gcc/x86_64-redhat-linux/8/../../../../lib64 -L/usr/bin/../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -L/usr/bin/../lib/gcc/x86_64-redhat-linux/8/../../.. -L/usr/bin/../lib -L/lib -L/usr/lib CheckFunctionExists.c.o -lpthread -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /usr/bin/../lib/gcc/x86_64-redhat-linux/8/crtend.o /usr/bin/../lib/gcc/x86_64-redhat-linux/8/../../../../lib64/crtn.o
adrienBlockedHello Jean-Nicolas,
I reinstalled the glib package as you adviced me and now I found:
[stage@port_poire ~]$ nm /lib64/libpthread.so.0 | grep "pthread_create" 0000000000007870 t __pthread_create_2_1 0000000000005bee t __pthread_create_2_1.cold.12 0000000000007870 T pthread_create@@GLIBC_2.2.5
Nevertheless I have again the same configuration error (CMakeError.log):
Determining if the function pthread_create exists in the pthreads failed with the following output: Change Dir: /home/stage/Documents/Adrien/sofa/build/build-v17.12/CMakeFiles/CMakeTmp Run Build Command:"/usr/bin/gmake" "cmTC_22e98/fast" /usr/bin/gmake -f CMakeFiles/cmTC_22e98.dir/build.make CMakeFiles/cmTC_22e98.dir/build gmake[1] : on entre dans le répertoire « /home/stage/Documents/Adrien/sofa/build/build-v17.12/CMakeFiles/CMakeTmp » Building C object CMakeFiles/cmTC_22e98.dir/CheckFunctionExists.c.o /usr/bin/clang -DCHECK_FUNCTION_EXISTS=pthread_create -o CMakeFiles/cmTC_22e98.dir/CheckFunctionExists.c.o -c /usr/share/cmake/Modules/CheckFunctionExists.c Linking C executable cmTC_22e98 /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_22e98.dir/link.txt --verbose=1 /usr/bin/clang -DCHECK_FUNCTION_EXISTS=pthread_create -rdynamic CMakeFiles/cmTC_22e98.dir/CheckFunctionExists.c.o -o cmTC_22e98 -lpthreads /usr/bin/ld : ne peut trouver -lpthreads clang-6.0: error: linker command failed with exit code 1 (use -v to see invocation) gmake[1]: *** [CMakeFiles/cmTC_22e98.dir/build.make:87: cmTC_22e98] Error 1 gmake[1] : on quitte le répertoire « /home/stage/Documents/Adrien/sofa/build/build-v17.12/CMakeFiles/CMakeTmp » gmake: *** [Makefile:126: cmTC_22e98/fast] Error 2
Could the clang package play a role in that problem ?
Thanks for your help.
adrienBlockedI used
locate libpthread
to found the file libpthread.so.0 and when I usedfind /lib -name "*pthread*"
it found nothing.
It seems that the lib is installed in /usr/lib64/ on my system and not in /lib/ but even in the /usr/lib64/ there isn’t the function pthread-create which raised the cmake error.adrienBlockedHi Hugo,
I did it and I obtained
nm: /usr/lib64/libpthread.so.0: aucun symbole
to test if pethread_create exists and I ran the CMakeLists.txt and it gave:-- Looking for include file pthread.h -- Looking for include file pthread.h - found -- Looking for pthread_create -- Looking for pthread_create - not found -- Looking for pthread_create in pthreads -- Looking for pthread_create in pthreads - not found -- Looking for pthread_create in pthread -- Looking for pthread_create in pthread - found -- Found Threads: TRUE
Thanks for your help
adrienBlockedHello,
I tried to install older version of glibc (2.15) to change the libpthread version and when I run configure
sudo ../glibc-2.15/configure --prefix=/usr --disable-profile --enable-add-ons --enable-kernel=2.6.25 --libexecdir=/usr/lib/glibc
I obtained*** These critical programs are missing or too old: gcc make *** Check the INSTALL file for required versions.
witch version of glibc should I install?
Thanks
adrienBlockedHello Hugo,
Yes I looked at the links.
The lib libpthread is installed on my system under/usr/lib64/
.
I just tried to check if the function pthread is the file/usr/lib64/libpthread.so.0
and I obtainednm: /usr/lib64/libpthread.so.0: aucun symbole
which means that the function isn’t in the file.Could the version of the lib be the bug ?
Thanks for your help
adrienBlockedsorry here is the link:
adrienBlockedHi,
I found a post where mentioned the libpthread file:link
So I checked and found libpthread_nonshared.a which is a library for parallel execution model. It seems to be the dependency that I need to compile SOFA. Therefore, I installed glibc and I checked again the libpthread lib but I didn’t find it.Do you know if the lipthread is a known problem ? Would you have an idea to solve it ?
adrienBlockedHello Guillaume,
Thanks for your answer. I just tried what you adviced. Here is the Konsole output:
[stage@port_poire usr]$ sudo dnf install @development-tools [sudo] Mot de passe de stage : Dernière vérification de l’expiration des métadonnées effectuée il y a 2:20:41 le ven. 18 mai 2018 15:49:34 CEST. Le groupe « Outils de développement » est déjà installé. Dépendances résolues. Rien à faire. Terminé !
It seems that it is not the problem.
-
AuthorPosts