Home › Forum › SOFA › Building SOFA › [SOLVED] SOFA_SceneCreat.
Tagged: 64_bits, GCC, Linux_other, SOFA_1608
- This topic has 8 replies, 3 voices, and was last updated 8 years ago by Hugo.
-
AuthorPosts
-
25 November 2016 at 11:47 #7989ewpostekBlocked
Dear Colleagues,
I build SOFA on a cluster with the cmake switches:cd build
/users/kdm/ewpostek/soffa/cmake_tmp/cmake-3.2.2-Linux-i386/bin/cmake -DSOFA_NO_OPENGL:BOOL=ON -DSOFA_OPENMP:BOOL=OFF -DSOFA_BUILD_SCENECREATOR:BOOL=OFF -DBoost_DIR:PATH=/apl/tryton/boost/gcc/1.62 -DBoost_INCLUDE_DIR:PATH=/apl/tryton/boost/gcc/1.62/include -DBoost_LIBRARY_DIR:PATH=/apl/tryton/boost/gcc/1.62/lib ../srcI use boost.1.62, CMAKE_CXX_COMPILER:FILEPATH=/apl/tryton/gcc/5.4.0/bin/c++ ,
however I arrive at the error:[ 77%] Building CXX object SceneCreator/CMakeFiles/SceneCreator.dir/SceneCreator.cpp.o
/users/kdm/ewpostek/soffa/sofa/master/src/applications/plugins/SceneCreator/SceneCreator.cpp:97:37: error: ‘sofa::component::visualmodel::OglModel’ has not been declared
using sofa::component::visualmodel::OglModel ;
^
make[2]: *** [SceneCreator/CMakeFiles/SceneCreator.dir/SceneCreator.cpp.o] Error 1
make[1]: *** [SceneCreator/CMakeFiles/SceneCreator.dir/all] Error 2
make: *** [all] Error 2
ewpostek@tryton-ap:~/soffa/sofa/master/build$ lsThe linux:
Linux version 2.6.32-504.el6.x86_64 (mockbuild@c6b9.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-11) (GCC) ) #1 SMP Wed Oct 15 04:27:16 UTC 2014Best regards, Elek
25 November 2016 at 15:51 #7993Alex BilgerBlockedHi,
with the CMake option SOFA_NO_OPENGL, your error is not supposed to happen. I cannot check it, but probably someone forgot to use this flag in this plugin. If it’s the case, you can solve it yourself by putting some #ifndef SOFA_NO_OPENGL in the code making references to OglModel, or wait for someone to fix it.Alex
25 November 2016 at 16:58 #7996ewpostekBlockedHi,
Thank you, yes, it’s good advice !
I was porting the program to a cluster in which I had no
admin permissions.
However, actually, the remaining libs (OpenGL, glu, glew)
are installed. Therefore, I can go with all libs.Another problem appeared, the echo (it is for gcc-4.9 to 5>):
Could anyone to help with it ?
best regards, ElekAnother problem appeared, the echo (it is for gcc-4.9 to 5>):
In file included from /users/kdm/ewpostek/sofa_last/sofa/v16.08/src/modules/SofaOpenglVisual/OglAttribute.cpp:22:0: /users/kdm/ewpostek/sofa_last/sofa/v16.08/src/SofaGeneral/../modules/SofaOpenglVisual/OglAttribute.inl: In member function ‘void sofa::component::visualmodel::OglAttribute<size, type, DataTypes>::enable()’: /users/kdm/ewpostek/sofa_last/sofa/v16.08/src/SofaGeneral/../modules/SofaOpenglVisual/OglAttribute.inl:192:70: error: there are no arguments to ‘glVertexAttribLPointer’ that depend on a template parameter, so a declaration of ‘glVertexAttribLPointer’ must be available [-fpermissive] glVertexAttribLPointer(_index, size, type, 0, (char*)NULL + 0); ^ /users/kdm/ewpostek/sofa_last/sofa/v16.08/src/SofaGeneral/../modules/SofaOpenglVisual/OglAttribute.inl:192:70: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated) /users/kdm/ewpostek/sofa_last/sofa/v16.08/src/SofaGeneral/../modules/SofaOpenglVisual/OglAttribute.inl: In instantiation of ‘void sofa::component::visualmodel::OglAttribute<size, type, DataTypes>::enable() [with int size = 4; unsigned int type = 5125u; DataTypes = sofa::defaulttype::Vec<4, unsigned int>]’:
29 November 2016 at 00:27 #8003HugoKeymasterHi Elek,
I never saw that, but it seems that everything is in the output ? no ?
note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)
Did you try setting this -fpermissive flag ?
Cheers,
Hugo
29 November 2016 at 10:53 #8007ewpostekBlockedHi Hugo,
Yes, I did.
I used the switch -DCMAKE_CXX_FLAGS:STRING=’-fpermissive’ and
it reflects in the CMakeCache.txt
//No help, variable specified on the command line.
CMAKE_CXX_FLAGS:STRING=-fpermissiveMight be, I should look deeper into the dependencies,
Besr regards,
Elek29 November 2016 at 11:22 #8008ewpostekBlockedHi,
just a word more,
the fpermissive is included into flags.make# CMAKE generated file: DO NOT EDIT!
# Generated by “Unix Makefiles” Generator, CMake Version 3.2# compile CXX with /apl/tryton/gcc/5.4.0/bin/c++
CXX_FLAGS = -fpermissive -Wall -W -O3 -DNDEBUG -fstack-protector –param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fPIC -I/users/kdm/ewpostek/sofa_last/sofa/v16.08/src/SofaGeneral/../modules -I/users/kdm/ewpostek/sofa_last/sofa/v16.08/build/include
…
…
etc…that is in the dir
/users/kdm/ewpostek/sofa_last/sofa/v16.08/build/SofaGeneral/SofaOpenglVisual/CMakeFiles/SofaOpenglVisual.dirbest,
Elek9 December 2016 at 15:13 #8061HugoKeymasterHi Elek,
Have you notice the post of Alex above ?
He’s right, the OglAttribute should not be compiled when the SOFA_NO_OPENGL flag is true.
I will correct it next week. You can already make the change locally on your machine.Cheers,
Hugo
10 December 2016 at 09:05 #8064ewpostekBlockedHi Hugo,
I will do attempt to
correct it as well,
cheers,
Elek21 December 2016 at 14:30 #8241HugoKeymasterHi Elek,
The commits in the pull-request #110 should fix your issue.
Let us know if you face any new issue with SOFA by creating a new topic.
Best wishes,Hugo
-
AuthorPosts
- You must be logged in to reply to this topic.