XERCES not found

All about Linux portage
daniel
Site Admin
Posts: 7332
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: XERCES not found

Post by daniel »

Regarding the '.lib' problem, I guess the script is for Windows only...

Then if you use 'libxerces' from the Debian repo, shouldn't you also recompile libE57 with the same version of Xerces?

And last but not least, only CC_CORE_LIB can be compiled as a static library (uncheck the 'COMPILE_CC_CORE_LIB_SHARED' variable).
Daniel, CloudCompare admin
jgpallero
Posts: 44
Joined: Thu Dec 12, 2013 2:00 pm

Re: XERCES not found

Post by jgpallero »

daniel wrote:Regarding the '.lib' problem, I guess the script is for Windows only...

Then if you use 'libxerces' from the Debian repo, shouldn't you also recompile libE57 with the same version of Xerces?

And last but not least, only CC_CORE_LIB can be compiled as a static library (uncheck the 'COMPILE_CC_CORE_LIB_SHARED' variable).
I've compiled E57 with the xerces from Debian and was successful

Where is the option 'COMPILE_CC_CORE_LIB_SHARED'? I can't find it (I've checked the Advanced box in cmake-gui)
jgpallero
Posts: 44
Joined: Thu Dec 12, 2013 2:00 pm

Re: XERCES not found

Post by jgpallero »

Well, I've seen the COMPILE_CC_CORE_LIB_SHARED is only available in the git repository. I've tried to compile CC disabling the option, but I obtain this error at compile time:

Code: Select all

[ 95%] Building CXX object qCC/CMakeFiles/CloudCompare.dir/qrc_icones.cxx.o
Linking CXX executable CloudCompare
../CC/libCC_CORE_LIB.a(PointProjectionTools.cpp.o): En la función `FindNearestCandidate(unsigned int&, std::_List_iterator<CCLib::PointProjectionTools::IndexedCCVector2*> const&, std::_List_iterator<CCLib::PointProjectionTools::IndexedCCVector2*> const&, std::vector<CCLib::PointProjectionTools::IndexedCCVector2, std::allocator<CCLib::PointProjectionTools::IndexedCCVector2> > const&, std::vector<HullPointFlags, std::allocator<HullPointFlags> > const&, float, float, bool)':
PointProjectionTools.cpp:(.text+0x19ca): definiciones múltiples de `FindNearestCandidate(unsigned int&, std::_List_iterator<CCLib::PointProjectionTools::IndexedCCVector2*> const&, std::_List_iterator<CCLib::PointProjectionTools::IndexedCCVector2*> const&, std::vector<CCLib::PointProjectionTools::IndexedCCVector2, std::allocator<CCLib::PointProjectionTools::IndexedCCVector2> > const&, std::vector<HullPointFlags, std::allocator<HullPointFlags> > const&, float, float, bool)'
CMakeFiles/CloudCompare.dir/ccContourExtractor.cpp.o:ccContourExtractor.cpp:(.text+0x0): primero se definió aquí
collect2: error: ld returned 1 exit status
qCC/CMakeFiles/CloudCompare.dir/build.make:3680: recipe for target 'qCC/CloudCompare' failed
make[2]: *** [qCC/CloudCompare] Error 1
CMakeFiles/Makefile2:690: recipe for target 'qCC/CMakeFiles/CloudCompare.dir/all' failed
make[1]: *** [qCC/CMakeFiles/CloudCompare.dir/all] Error 2
Makefile:116: recipe for target 'all' failed
make: *** [all] Error 2
daniel
Site Admin
Posts: 7332
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: XERCES not found

Post by daniel »

Oh, this option was meant to be used when compiling CC_CORE_LIB alone (as this is a LGPL library, it can be used by other projects as a standalone component).

I never tried to use this option when compiling CC.
Daniel, CloudCompare admin
jgpallero
Posts: 44
Joined: Thu Dec 12, 2013 2:00 pm

Re: XERCES not found

Post by jgpallero »

Mmm, so the support dor E57 in linux it is impossible at tis point. Apparently, compilation of E57 in linux only is possible as static library, but I don't know if CC could be fixed for using it
daniel
Site Admin
Posts: 7332
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: XERCES not found

Post by daniel »

I'm not sure to see the link between libE57 being static and CC_CORE_LIB being static. You can use static lib next to dynamic ones without any problem.

You may have to fix the CMake scripts though.
Daniel, CloudCompare admin
jgpallero
Posts: 44
Joined: Thu Dec 12, 2013 2:00 pm

Re: XERCES not found

Post by jgpallero »

daniel wrote:I'm not sure to see the link between libE57 being static and CC_CORE_LIB being static. You can use static lib next to dynamic ones without any problem.

You may have to fix the CMake scripts though.
Yes, I think also there is no problem about linking static with shared libraries, but the errors in my compilation were due to the static libE57 as it can be seen in one of my previous comment: http://cloudcompare.org/forum/viewtopic ... t=10#p4973
daniel
Site Admin
Posts: 7332
Joined: Wed Oct 13, 2010 7:34 am
Location: Grenoble, France
Contact:

Re: XERCES not found

Post by daniel »

I can't read Spanish errors sorry ;)

Have you tried to add the fpic option as suggested?
Daniel, CloudCompare admin
jgpallero
Posts: 44
Joined: Thu Dec 12, 2013 2:00 pm

Re: XERCES not found

Post by jgpallero »

daniel wrote:I can't read Spanish errors sorry ;)

Have you tried to add the fpic option as suggested?
Daniel, I was finally able to compile CC with E57 support in linux. I've summarized the steps in a new thread (viewtopic.php?f=12&t=1322). It was needed the modification of an include line in a *.cpp file, that I think it should be modified also in the CC git trunk

Thanks
Post Reply