mingw-cross-env-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Mingw-cross-env-list] CGAL example build fails + fix


From: William
Subject: Re: [Mingw-cross-env-list] CGAL example build fails + fix
Date: Wed, 18 Jul 2012 00:01:53 +0200
User-agent: Mozilla/5.0 (X11; Linux i686; rv:13.0) Gecko/20120615 Thunderbird/13.0.1


Hello,
Here is the methodology to modify a patch :

there are files src/cgal.mk and src/cgal-1-fixes.patch, the second being the patch file.

import the patched directory in gits/ :
# tools/patch-tool-mxe import cgal

then edit the files, you can use git add, git commit, ...

then make a patch from that :
# tools/patch-tool-mxe export cgal

now try to compile :
# make cgal

now you can submit the updated patch!

William

On 07/15/2012 03:35 PM, Don Bright wrote:
On mxe downloaded 7/15/2012 'make cgal' fails with the following error:


[build]    cgal

Failed to build package cgal!
------------------------------------------------------------
make[3]: *** [CMakeFiles/AABB_custom_example.dir/all] Error 2
make[3]: Leaving directory `/home/donb/mxe/tmp-cgal/CGAL-4.0/examples/AABB_tree'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/donb/mxe/tmp-cgal/CGAL-4.0/examples/AABB_tree'
make[1]: *** [build-only-cgal] Error 2
make[1]: Leaving directory `/home/donb/mxe'
real    0m38.712s
user    1m3.408s
sys     0m4.988s
------------------------------------------------------------
[log]      /home/donb/mxe/log/cgal

make: *** [/home/donb/mxe/usr/installed/cgal] Error 1


looking in the log shows this:


make[4]: Entering directory
`/home/donb/mxe/tmp-cgal/CGAL-4.0/examples/AABB_tree'
[ 80%] Building CXX object
CMakeFiles/AABB_polyhedron_edge_example.dir/AABB_polyhedron_edge_example.cpp.obj
Linking CXX executable AABB_custom_triangle_soup_example.exe
Linking CXX executable AABB_polyhedron_facet_distance_example.exe
Linking CXX executable AABB_custom_indexed_triangle_set_array_example.exe
Linking CXX executable AABB_insertion_example.exe
Linking CXX executable AABB_custom_indexed_triangle_set_example.exe
Linking CXX executable AABB_custom_example.exe
Linking CXX executable AABB_polyhedron_edge_example.exe
Linking CXX executable AABB_polyhedron_facet_intersection_example.exe
CMakeFiles/AABB_custom_indexed_triangle_set_example.dir/AABB_custom_indexed_triangle_set_example.cpp.obj:AABB_custom_inde
xed_triangle_set_example.cpp:(.text$_ZN5boost10lock_errorC1EiPKc[__ZN5boost10lock_errorC1EiPKc]+0x16):
undefined referenc
e to `boost::system::system_category()'
CMakeFiles/AABB_custom_indexed_triangle_set_example.dir/AABB_custom_indexed_triangle_set_example.cpp.obj:AABB_custom_indexed_triangle_set_example.cpp:(.text$_ZN5boost21thread_resource_errorC1Ev[__ZN5boost21thread_resource_errorC1Ev]+0x16):
undefined reference to `boost::system::system_category()'
CMakeFiles/AABB_custom_indexed_triangle_set_example.dir/AABB_custom_indexed_triangle_set_example.cpp.obj:AABB_custom_indexed_triangle_set_example.cpp:(.text.startup+0x70a):
undefined reference to `boost::system::generic_category()'
CMakeFiles/AABB_custom_indexed_triangle_set_example.dir/AABB_custom_indexed_triangle_set_example.cpp.obj:AABB_custom_indexed_triangle_set_example.cpp:(.text.startup+0x714):
undefined reference to `boost::system::generic_category()'
CMakeFiles/AABB_custom_indexed_triangle_set_example.dir/AABB_custom_indexed_triangle_set_example.cpp.obj:AABB_custom_indexed_triangle_set_example.cpp:(.text.startup+0x71e):
undefined reference to `boost::system::system_category()'
/home/donb/mxe/tmp-cgal/CGAL-4.0/lib/libCGAL.a(all_files.cpp.obj):all_files.cpp:(.text.startup+0x1a):
undefined reference to `boost::system::generic_category()'


etc etc etc (several pages of undefined references to boost::system stuff)


/home/donb/mxe/tmp-cgal/CGAL-4.0/lib/libCGAL.a(all_files.cpp.obj):all_files.cpp:(.text.startup+0x1a):
undefined reference to `boost::system::generic_category()'
/home/donb/mxe/tmp-cgal/CGAL-4.0/lib/libCGAL.a(all_files.cpp.obj):all_files.cpp:(.text.startup+0x24):
undefined reference to `boost::system::generic_category()'
/home/donb/mxe/tmp-cgal/CGAL-4.0/lib/libCGAL.a(all_files.cpp.obj):all_files.cpp:(.text.startup+0x2e):
undefined reference to `boost::system::system_category()'
/home/donb/mxe/usr/lib/gcc/i686-pc-mingw32/4.7.1/../../../../i686-pc-mingw32/lib/libboost_thread_win32-mt.a(thread.o):thread.cpp:(.text+0x3ffa):
undefined reference to `boost::chrono::system_clock::now()'
/home/donb/mxe/usr/lib/gcc/i686-pc-mingw32/4.7.1/../../../../i686-pc-mingw32/lib/libboost_thread_win32-mt.a(thread.o):thread.cpp:(.text$_ZN5boost21thread_resource_errorC1EiPKc[__ZN5boost21thread_resource_errorC1EiPKc]+0x16):
undefined reference to `boost::system::system_category()'
collect2: error: ld returned 1 exit status
make[4]: *** [AABB_custom_example.exe] Error 1
make[4]: Leaving directory `/home/donb/mxe/tmp-cgal/CGAL-4.0/examples/AABB_tree'
make[3]: *** [CMakeFiles/AABB_custom_example.dir/all] Error 2
make[3]: Leaving directory `/home/donb/mxe/tmp-cgal/CGAL-4.0/examples/AABB_tree'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/donb/mxe/tmp-cgal/CGAL-4.0/examples/AABB_tree'
make[1]: *** [build-only-cgal] Error 2
make[1]: Leaving directory `/home/donb/mxe'




This may be related to mxe using boost 1.50 which on win32 cross
builds apparently needs 'boost_chrono' linked.



Solution:



In

CGAL-4.0/cmake/modules/CGAL_SetupBoost.cmake

change

   find_package( Boost 1.33.1 REQUIRED thread )

to this:

   find_package( Boost 1.33.1 REQUIRED thread system chrono )


Unfortunately I don't know how to make a patch for mxe

-DB





reply via email to

[Prev in Thread] Current Thread [Next in Thread]