Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Runtime error with only CImage3 included

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Runtime error with only CImage3 included


Chronological Thread 
  • From: Jean-Christophe Souplet <>
  • To:
  • Cc: "Laurent Rineau (GeometryFactory)" <>
  • Subject: Re: [cgal-discuss] Runtime error with only CImage3 included
  • Date: Fri, 06 Aug 2010 14:59:07 +0200
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=JsZ/MHaKdz0sYA2pWceafkX2eRwgCii7HtRE+DGZn68kco3aXsMGq+DuOacb/yosvr iyoZJMzm4niu9K+Pr0Npp/jlx0sb541p5b6RZK02xI/+9RtUXgfj4UI/d6cnlye2UdCm fKK+6+qS+XA08XnkysP/H9knwU3PUVGAFKPYU=

Thank you for your replies,

I think, I did a mistake at the linkage step.
The software works fine in release (with_static_lib configuration).
The problem is only in the debug mode (with dynamic library configuration)

Here are the parts of my cmakefile about CGAL

#--------------
# CGAL
#--------------

find_package(CGAL COMPONENTS ImageIO)
IF(CGAL_FOUND)
INCLUDE(${CGAL_USE_VTK} ${CGAL_USE_FILE})

find_package(Boost)
IF ( Boost_FOUND AND Boost_VERSION GREATER 103400 )
include( CGAL_CreateSingleSourceCGALProgram )

ENDIF()
ELSE(CGAL_FOUND)
MESSAGE(FATAL_ERROR "CGAL not found. Please set CGAL_DIR.")
ENDIF(CGAL_FOUND)




TARGET_LINK_LIBRARIES(MicINSERMLib
vtkRenderingAddOn
vtkVolumeRendering
vtkVisuManagement
vtkDataManagement
vtkHybrid
vtkWidgets
vtkWidgetsAddOn
qvtk
${ITK_LIBRARIES}
${QT_LIBRARIES}
${CGAL_LIBRARIES}
)

TARGET_LINK_LIBRARIES(MicINSERM
MicINSERMLib
)


If I remove the ${CGAL_LIBRARIES}, I still can build the software. I do not understand why there is no linkage error.
Finally, in debug mode (with dynamic library configuration), if I open an image before closing the software, there is no runtime error.

The software depending on ITK, VTK, VTKINRIA3D, it is difficult to give you a full example for the moment but I will do it asap.
Thank you for your help,

Jean-Christophe Souplet
Post-Doctorant INSERM U658
IPROS - INSERM U658
CHR Orleans - Hopital Porte Madeleine
1 rue Porte Madeleine
BP2439 45032 Orleans Cedex 1
Tel : (+33)2-38-74-47-33
Fax : (+33)2-38-74-40-24


On 8/6/2010 11:08 AM, Laurent Rineau (GeometryFactory) wrote:
On Friday 06 August 2010 09:48:00 jcsouplet wrote:
Good-morning,

I tried to use CGAL with a cmake project with qt-creator to generate mesh.
I performed this task but when I am closing my program I have the runtime
error message.
I removed all cgal code and include. The runtime error was removed.
I add #include<CGAL/Image_3.h> and the runtime error came back.

Do you have any suggestion to remove this error ?
Link with libCGAL_ImageIO.

If you want further help, please post a small .cpp program than one can
compile, and explain how you compile your program. That way, everybody on this
list will be able to try reproducing your error and find a fix.




Archive powered by MHonArc 2.6.16.

Top of Page