[pgrouting-dev] Problems linking on mingw64 between boost, cgal and threads

sanak geosanak at gmail.com
Wed Mar 13 07:44:50 PDT 2013


Hi Stephen,

I have updated the MinGW32/64 build instruction,
so, could you retry from boost build?
(Sorry, gcc PATH settings is not necessary, because msys.bat path settings
seems to be inherited by command prompt.)
https://github.com/sanak/pgrouting4w/commit/e5ae697b3cb545b002702eda62c2909382ae4521

Regards,

2013/3/13 sanak <geosanak at gmail.com>

> Hi Stephen,
>
> Oops, sorry, my boost_1_46_1/tools/build/bjam.log shows "msvc10" which I
> have installed...
>
> I will check after returning from work. (about 12 hour later)
>
> Regards,
>
> 2013/3/13 Stephen Woodbridge <woodbri at swoodbridge.com>
>
>> OK, it looks like I have solved ISSUE 2, I think this was caused because
>> I built boost with the 32 bit model in the 64 bit environment. I still can
>> not not get ISSUE 1 to resolve and I had to rebuild it using the bjam I
>> built under 1_51.
>>
>> To fix ISSUE to:
>>
>> 1. rebuilt boost_1_46_1 as 64 bit model using bjam from 1_51
>> 2. rebuild CGAL
>> 3. rebuild pgrouting
>>
>> So I have at least on cuild of pgRouting
>>
>> So making progress in small steps :)
>>
>> If you have any additional thoughts on getting boost to build they would
>> be appreciated.
>>
>> In my msys.bat shell, I have:
>>
>> PATH=/c/ming64/mingw64/bin/:/**home/woodbri/bin:.:/usr/local/**
>> bin:/mingw/bin:/bin:/c/oracle/**product/10.2.0/db_1/bin:/c/**
>> Windows/system32:/c/Windows:/**c/Windows/System32/Wbem:/c/**
>> Windows/System32/**WindowsPowerShell/v1.0/:/c/**Program Files
>> (x86)/QuickTime/QTSystem/
>>
>> Thanks,
>>   -Steve
>>
>>
>> On 3/12/2013 11:34 AM, Stephen Woodbridge wrote:
>>
>>> Hi Sanak,
>>>
>>> I'm still have an issue with this. Hopefully I followed your changes
>>> correctly:
>>>
>>> In my msys.bat shell I added the to the path: /c/ming64/mingw64/bin/, I
>>> have /c/ming64/ and /c/ming32/ trees setup so I can build on either.
>>>
>>> start cmd
>>> gcc -v               # is found and run
>>> bootstrap.bat gcc    # fails
>>> bootstrap.bat mingw  # fails
>>>
>>> exit
>>>
>>> $ cat tools/build/bjam.log
>>> ###
>>> ### Using 'msvc' toolset.
>>> ###
>>>
>>> c:\ming64\projects\boost_1_46_**1\tools\build\v2\engine\src>if exist
>>> bootstrap rd /S /Q bootstrap
>>>
>>> c:\ming64\projects\boost_1_46_**1\tools\build\v2\engine\src>md bootstrap
>>>
>>> c:\ming64\projects\boost_1_46_**1\tools\build\v2\engine\src>cl /nologo
>>> /GZ
>>> /Zi /MLd /Fobootstrap/ /Fdbootstrap/ -DNT -DYYDEBUG kernel32.lib
>>> advapi32.lib user32.lib /Febootstrap\jam0  command.c compile.c debug.c
>>> execnt.c expand.c filent.c glob.c hash.c hdrmacro.c headers.c jam.c
>>> jambase.c jamgram.c lists.c make.c make1.c newstr.c option.c output.c
>>> parse.c pathunix.c regexp.c rules.c scan.c search.c subst.c timestamp.c
>>> variable.c modules.c strings.c filesys.c builtins.c md5.c pwd.c class.c
>>> w32_getreg.c native.c modules/set.c modules/path.c modules/regex.c
>>> modules/property-set.c modules/sequence.c modules/order.c
>>>
>>> I looked at tools/build/v2/engine/src/**build.bat but I'm not very
>>> familiar with windows bat files.
>>>
>>> -Steve
>>>
>>> On 3/12/2013 9:15 AM, sanak wrote:
>>>
>>>> Hi Stephen,
>>>> I updated MinGW32/64 build instruction to my "mingw" branch,
>>>> and checked that MinGW64-bit build successed. (but not tested)
>>>> https://github.com/sanak/**pgrouting4w/commit/**
>>>> 2a660524b53bcd80005e52917af5b3**2b31749559<https://github.com/sanak/pgrouting4w/commit/2a660524b53bcd80005e52917af5b32b31749559>
>>>>
>>>> so, retry from boost build about ISSUE1. (Thanks Pieter!)
>>>> Regards,
>>>> 2013/3/12 Stephen Woodbridge <woodbri at swoodbridge.com
>>>> <mailto:woodbri at swoodbridge.**com <woodbri at swoodbridge.com>>>
>>>>
>>>>     Hi all,
>>>>
>>>>     I'm stuck at the moment trying to link the pgrouting driving
>>>>     directions module using mingw 64 bit. See the issues below. So if
>>>>     anyone has any thoughts on this it would be appreciated. I will
>>>>     check the current state of the files into my branch in the morning
>>>>     here (GMT-5) if you are setup to reproduce this. It is too late to
>>>>     do it with a clear head tonight. I'll also move it back to Linux and
>>>>     try again there as I have changed a lot of files.
>>>>
>>>>     Thanks,
>>>>        -Steve
>>>>
>>>>     I have followed Sanak's directions from:
>>>>     https://github.com/sanak/__**pgrouting4w/blob/master/BUILD.**
>>>> __mingw64<https://github.com/sanak/__pgrouting4w/blob/master/BUILD.__mingw64>
>>>>     <https://github.com/sanak/**pgrouting4w/blob/master/BUILD.**mingw64<https://github.com/sanak/pgrouting4w/blob/master/BUILD.mingw64>
>>>> >
>>>>
>>>>     ISSUE 1:
>>>>
>>>>     I first installed boost_1_51.zip but ran into problems compiling so
>>>>     installed boost_1_46_1.zip as he suggested. I was able to bootstrap
>>>>     1_51 and get a bjam.exe without a problem. But I could not get
>>>>     1_46_1 to bootstrap :(
>>>>
>>>>     Microsoft Windows [Version 6.1.7601]
>>>>     Copyright (c) 2009 Microsoft Corporation.  All rights reserved.
>>>>
>>>>     c:\ming64\projects\boost_1_46_**__1>bootstrap.bat mingw
>>>>     Building Boost.Jam build engine
>>>>     'cl' is not recognized as an internal or external command,
>>>>     operable program or batch file.
>>>>
>>>>     Failed to build Boost.Jam build engine.
>>>>     Please consult bjam.log for furter diagnostics.
>>>>
>>>>     You can try to obtain a prebuilt binary from
>>>>
>>>>
>>>> http://sf.net/project/__**showfiles.php?group_id=7586&__**
>>>> package_id=72941<http://sf.net/project/__showfiles.php?group_id=7586&__package_id=72941>
>>>>     <http://sf.net/project/**showfiles.php?group_id=7586&**
>>>> package_id=72941<http://sf.net/project/showfiles.php?group_id=7586&package_id=72941>
>>>> >
>>>>
>>>>     Also, you can file an issue at http://svn.boost.org
>>>>     Please attach bjam.log in that case.
>>>>
>>>>     c:\ming64\projects\boost_1_46_**__1>
>>>>
>>>>     So I built 1_46_1 using the bjam.exe that I built in 1_51 and it
>>>>     seems to have worked ok, but maybe that is part of the problem.
>>>>
>>>>     ISSUE 2:
>>>>
>>>>     Is the follow mess from the linker
>>>>
>>>>     Scanning dependencies of target routing_dd
>>>>     [ 80%] Building C object
>>>>     core/driving_distance/src/__**CMakeFiles/routing_dd.dir/__**
>>>> alpha.c.obj
>>>>     [ 86%] Building CXX object
>>>>
>>>> core/driving_distance/src/__**CMakeFiles/routing_dd.dir/__**
>>>> alpha_drivedist.cpp.obj
>>>>
>>>>     In file included from
>>>>
>>>> c:/ming64/projects/pgx64/pg92/**__include/postgresql/server/**
>>>> pg___config_os.h:37:0,
>>>>
>>>>                       from
>>>>     c:/ming64/projects/pgx64/pg92/**__include/postgresql/server/c.**
>>>> h:__87,
>>>>                       from
>>>>
>>>> c:/ming64/projects/pgx64/pg92/**__include/postgresql/server/__**
>>>> postgres.h:47,
>>>>
>>>>                       from
>>>>
>>>> c:/ming64/projects/pgrouting/_**_core/driving_distance/src/__**
>>>> alpha.h:27,
>>>>                       from
>>>>
>>>> c:/ming64/projects/pgrouting/_**_core/driving_distance/src/__**
>>>> alpha_drivedist.cpp:46:
>>>>
>>>>
>>>> c:\ming64\mingw64\bin\../lib/_**_gcc/x86_64-w64-mingw32/4.5.4/**
>>>> .__./../../../x86_64-w64-**mingw32/__include/winsock2.h:**13:2:
>>>>
>>>>     warning: #warning Please include winsock2.h before windows.h
>>>>     [ 93%] Building CXX object
>>>>
>>>> core/driving_distance/src/__**CMakeFiles/routing_dd.dir/__**
>>>> boost_drivedist.cpp.obj
>>>>
>>>>     [100%] Building C object
>>>>
>>>> core/driving_distance/src/__**CMakeFiles/routing_dd.dir/__**
>>>> drivedist.c.obj
>>>>     Linking CXX shared library ../../../lib/librouting_dd.dll
>>>>     Creating library file: ../../../lib/librouting_dd.__**dll.a
>>>>
>>>> c:/ming64/msys/local/lib/__**libboost_thread-mgw45-mt-1_46_**
>>>> __1.a(thread.o):
>>>>     duplicate section
>>>>
>>>> `.data$_ZTVN5boost16exception_**__detail10clone_implINS0___**
>>>> 19error_info_injectorISt9bad__**_allocEEEE[vtable
>>>>
>>>>     for
>>>>
>>>> boost::exception_detail::__**clone_impl<boost::exception___**
>>>> detail::error_info_injector<__**std::bad_alloc>
>>>>
>>>>      >]' has different size
>>>>
>>>> c:/ming64/msys/local/lib/__**libCGAL.a(all_files.cpp.obj):_**
>>>> _all_files.cpp:(.text+0xf898):
>>>>
>>>>     undefined reference to  `boost::system::generic___**category()'
>>>>
>>>> c:/ming64/msys/local/lib/__**libCGAL.a(all_files.cpp.obj):_**
>>>> _all_files.cpp:(.text+0xf8a4):
>>>>
>>>>     undefined reference to `boost::system::generic___**category()'
>>>>
>>>> c:/ming64/msys/local/lib/__**libCGAL.a(all_files.cpp.obj):_**
>>>> _all_files.cpp:(.text+0xf8b0):
>>>>
>>>>     undefined reference to `boost::system::system___**category()'
>>>>     collect2: ld returned 1 exit status
>>>>     make[2]: *** [lib/librouting_dd.dll] Error 1
>>>>     make[1]: ***
>>>>     [core/driving_distance/src/__**CMakeFiles/routing_dd.dir/all]
>>>> Error 2
>>>>     make: *** [all] Error 2
>>>>     ______________________________**___________________
>>>>     pgrouting-dev mailing list
>>>>     pgrouting-dev at lists.osgeo.org <mailto:pgrouting-dev at lists.**
>>>> osgeo.org <pgrouting-dev at lists.osgeo.org>>
>>>>     http://lists.osgeo.org/__**mailman/listinfo/pgrouting-dev<http://lists.osgeo.org/__mailman/listinfo/pgrouting-dev>
>>>>     <http://lists.osgeo.org/**mailman/listinfo/pgrouting-dev<http://lists.osgeo.org/mailman/listinfo/pgrouting-dev>
>>>> **>
>>>>
>>>>
>>>>
>>>>
>>>> ______________________________**_________________
>>>> pgrouting-dev mailing list
>>>> pgrouting-dev at lists.osgeo.org
>>>> http://lists.osgeo.org/**mailman/listinfo/pgrouting-dev<http://lists.osgeo.org/mailman/listinfo/pgrouting-dev>
>>>>
>>>>
>>> ______________________________**_________________
>>> pgrouting-dev mailing list
>>> pgrouting-dev at lists.osgeo.org
>>> http://lists.osgeo.org/**mailman/listinfo/pgrouting-dev<http://lists.osgeo.org/mailman/listinfo/pgrouting-dev>
>>>
>>
>> ______________________________**_________________
>> pgrouting-dev mailing list
>> pgrouting-dev at lists.osgeo.org
>> http://lists.osgeo.org/**mailman/listinfo/pgrouting-dev<http://lists.osgeo.org/mailman/listinfo/pgrouting-dev>
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/pgrouting-dev/attachments/20130313/62f18523/attachment-0001.html>


More information about the pgrouting-dev mailing list