[Gmsh] compile error: cannot find -lGmshPost

wing yongjin.liu at gmail.com
Thu Oct 2 05:57:02 CEST 2008


Michele Mocciola wrote:
> Probably you have a version of med olser than 2.3.4. If you want to compile gmsh-2.2.4 you must disable med support or you must have med-2.3.4.
>
>
>
> --- On Wed, 10/1/08, Yongjin Liu <yongjin.liu at gmail.com> wrote:
>
>   
>> From: Yongjin Liu <yongjin.liu at gmail.com>
>> Subject: [Gmsh]  compile error: cannot find -lGmshPost
>> To: gmsh at geuz.org
>> Date: Wednesday, October 1, 2008, 4:03 PM
>> Hi there,
>>
>> I tried to compile 2.2.4 with opencascade support.
>> ./configure --enable-occ --with-occ-prefix=/xxx/xxx   with
>> no problem
>> but when I 'make' it said:
>>
>> g++ -g -O2  -o bin/gmsh -Llib -lGmshFltk -lGmshCommon
>> -lGmshGeo -lGmshMesh
>> -lGmshPlugin -lGmshPost -lGmshCommon -lGmshGraphics
>> -lGmshParser
>> -lGmshNumeric -lfltk_images -lfltk_gl -lfltk -lGLU -lGL
>> -ljpeg -lpng
>> -lGmshANN -lGmshChaco -lGmshMetis -lGmshNetgen
>> -lGmshMathEval -lgsl
>> -lgslcblas -lmed -lhdf5 -lz -lm
>> /usr/bin/ld: cannot find -lGmshPost
>> collect2: ld returned 1 exit status
>> make: *** [link] error 1
>>
>> then I enter Post directory and 'make', and it
>> said:
>>
>> g++ -g -O2  -DHAVE_LIBZ -DHAVE_GSL -DHAVE_MATH_EVAL
>> -DHAVE_NETGEN -DHAVE_ANN
>> -DHAVE_LIBPNG -DHAVE_LIBJPEG -DHAVE_FLTK 
>> -I/usr/include/freetype2
>> -DHAVE_CHACO -DHAVE_METIS -DHAVE_MED -I../Common -I../Geo
>> -I../Mesh
>> -I../Post -I../Graphics -I../Numeric -I../Parser
>> -I../Plugin -I../Fltk
>> -I../contrib/MathEval -I../contrib/ANN/include  -c
>> PViewDataGModelIO.cpp
>> PViewDataGModelIO.cpp: In member function 'bool
>> PViewDataGModel::readMED(std::string, int)':
>> PViewDataGModelIO.cpp:214: error:
>> 'MED_NOEUD_MAILLE' was not declared in
>> this scope
>> PViewDataGModelIO.cpp: In member function 'virtual bool
>> PViewDataGModel::writeMED(std::string)':
>> PViewDataGModelIO.cpp:482: warning: deprecated conversion
>> from string
>> constant to 'char*'
>> make: *** [PViewDataGModelIO.o] error 1
>>
>> What's the problem?
>> _______________________________________________
>> gmsh mailing list
>> gmsh at geuz.org
>> http://www.geuz.org/mailman/listinfo/gmsh
>>     
>
>
>       
>
> _______________________________________________
> gmsh mailing list
> gmsh at geuz.org
> http://www.geuz.org/mailman/listinfo/gmsh
>
>   
Hi all,

Thanks Michele.
my MED lib is version 2.3.1. Add '--disable-med' to the configure 
command and the compilation was successful. But when I tried to import a 
.stp geometry, gmsh still says
Error : Gmsh has to be compiled with OpenCascade support to load 
'...../.../xxx.stp'.

Seems that the occ directory was no recognized. If I don't point to the 
occ directory by --with-occ-prefix=/.... , where should be the 'default' 
one?