osm2pgrouting
osm2pgrouting copied to clipboard
Can't compile master anymore
When I try to compile master, it doesn't seem to be picking up my PostgreSQL inlcude path. I tried the old script I had with osm2pgrouting source I downloaded a while ago, and that still works with old code but not new code.
-- The C compiler identification is GNU 4.8.3
-- The CXX compiler identification is GNU 4.8.3
-- Check for working C compiler: c:/ming64gcc48/mingw64/bin/gcc.exe
-- Check for working C compiler: c:/ming64gcc48/mingw64/bin/gcc.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: c:/ming64gcc48/mingw64/bin/g++.exe
-- Check for working CXX compiler: c:/ming64gcc48/mingw64/bin/g++.exe -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found EXPAT: c:/ming64gcc48/projects/expat/rel-expat-2.1.0w64gcc48/bin/libexpat-1.dll (found version "2.1.0")
-- Boost version: 1.58.0
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- program_options
-- POSTGRESQL_INCLUDE_DIR:
-- EXPAT_INCLUDE_DIRS: c:/ming64gcc48/projects/expat/rel-expat-2.1.0w64gcc48/include
-- Boost_INCLUDE_DIRS: c:/ming64gcc48/projects/boost/rel-1_58_0w64gcc48/include/boost-1_58
-- Boost_INCLUDE_DIR: c:/ming64gcc48/projects/boost/rel-1_58_0w64gcc48/include/boost-1_58
-- PostgreSQL_LIBRARIES: libpq
-- Boost_LIBRARIES:
-- Configuring done
-- Generating done
-- Build files have been written to: C:/ming64gcc48/projects/osm2pgrouting/build
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -H/C/ming64gcc48/projects/osm2pgrouting/branches/2.1 -B/C/ming64gcc48/projects/osm2pgrouting/build --check-build-system CMakeFiles/Makefile.cmake 0
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_start /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles/progress.marks
make -f CMakeFiles/Makefile2 all
make[1]: Entering directory `/projects/osm2pgrouting/build'
make -f CMakeFiles/osm2pgrouting.dir/build.make CMakeFiles/osm2pgrouting.dir/depend
make[2]: Entering directory `/projects/osm2pgrouting/build'
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_depends "MSYS Makefiles" /C/ming64gcc48/projects/osm2pgrouting/branches/2.1 /C/ming64gcc48/projects/osm2pgrouting/branches/2.1 /C/ming64gcc48/projects/osm2pgrouting/build /C/ming64gcc48/projects/osm2pgrouting/build /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles/osm2pgrouting.dir/D
Scanning dependencies of target osm2pgrouting
make[2]: Leaving directory `/projects/osm2pgrouting/build'
make -f CMakeFiles/osm2pgrouting.dir/build.make CMakeFiles/osm2pgrouting.dir/build
make[2]: Entering directory `/projects/osm2pgrouting/build'
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 1
[ 6%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Class.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Class.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/Class.cpp
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 2
[ 13%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Configuration.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Configuration.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/Configuration.cpp
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 3
[ 20%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/ConfigurationParserCallback.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/ConfigurationParserCallback.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/ConfigurationParserCallback.cpp
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 4
[ 26%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/Export2DB.cpp
In file included from c:/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/Export2DB.cpp:22:0:
c:/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/Export2DB.h:24:33: fatal error: postgresql/libpq-fe.h: No such file or directory
#include "postgresql/libpq-fe.h"
^
compilation terminated.
CMakeFiles/osm2pgrouting.dir/build.make:133: recipe for target `CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.obj' failed
make[2]: *** [CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.obj] Error 1
make[2]: Leaving directory `/projects/osm2pgrouting/build'
CMakeFiles/Makefile2:66: recipe for target `CMakeFiles/osm2pgrouting.dir/all' failed
make[1]: *** [CMakeFiles/osm2pgrouting.dir/all] Error 2
make[1]: Leaving directory `/projects/osm2pgrouting/build'
Makefile:119: recipe for target `all' failed
make: *** [all] Error 2
Okay I looked at the old code I had and in Export2DB.h it had
#include "libpq-fe.h"
instead of
#include "postgresql/libpq-fe.h"
So I put the old include version back and that got me past the above error. However I now get this error
-- The C compiler identification is GNU 4.8.3
-- The CXX compiler identification is GNU 4.8.3
-- Check for working C compiler: c:/ming64gcc48/mingw64/bin/gcc.exe
-- Check for working C compiler: c:/ming64gcc48/mingw64/bin/gcc.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: c:/ming64gcc48/mingw64/bin/g++.exe
-- Check for working CXX compiler: c:/ming64gcc48/mingw64/bin/g++.exe -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found EXPAT: c:/ming64gcc48/projects/expat/rel-expat-2.1.0w64gcc48/bin/libexpat-1.dll (found version "2.1.0")
-- Boost version: 1.58.0
-- Boost version: 1.58.0
-- Found the following Boost libraries:
-- program_options
-- POSTGRESQL_INCLUDE_DIR:
-- EXPAT_INCLUDE_DIRS: c:/ming64gcc48/projects/expat/rel-expat-2.1.0w64gcc48/include
-- Boost_INCLUDE_DIRS: c:/ming64gcc48/projects/boost/rel-1_58_0w64gcc48/include/boost-1_58
-- Boost_INCLUDE_DIR: c:/ming64gcc48/projects/boost/rel-1_58_0w64gcc48/include/boost-1_58
-- PostgreSQL_LIBRARIES: libpq
-- Boost_LIBRARIES:
-- Configuring done
-- Generating done
-- Build files have been written to: C:/ming64gcc48/projects/osm2pgrouting/build
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -H/C/ming64gcc48/projects/osm2pgrouting/branches/2.1 -B/C/ming64gcc48/projects/osm2pgrouting/build --check-build-system CMakeFiles/Makefile.cmake 0
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_start /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles/progress.marks
make -f CMakeFiles/Makefile2 all
make[1]: Entering directory `/projects/osm2pgrouting/build'
make -f CMakeFiles/osm2pgrouting.dir/build.make CMakeFiles/osm2pgrouting.dir/depend
make[2]: Entering directory `/projects/osm2pgrouting/build'
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_depends "MSYS Makefiles" /C/ming64gcc48/projects/osm2pgrouting/branches/2.1 /C/ming64gcc48/projects/osm2pgrouting/branches/2.1 /C/ming64gcc48/projects/osm2pgrouting/build /C
Scanning dependencies of target osm2pgrouting
make[2]: Leaving directory `/projects/osm2pgrouting/build'
make -f CMakeFiles/osm2pgrouting.dir/build.make CMakeFiles/osm2pgrouting.dir/build
make[2]: Entering directory `/projects/osm2pgrouting/build'
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 1
[ 6%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Class.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Class.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1/src
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 2
[ 13%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Configuration.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Configuration.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 3
[ 20%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/ConfigurationParserCallback.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/ConfigurationParserCallback.cpp.obj -c /C/ming64gcc48/projects/osm2pgro
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 4
[ 26%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 5
[ 33%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/math_functions.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/math_functions.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branche
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 6
[ 40%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Node.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/Node.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 7
[ 46%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/osm2pgrouting.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/osm2pgrouting.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 8
[ 53%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/OSMDocument.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/OSMDocument.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/2
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 9
[ 60%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/OSMDocumentParserCallback.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/OSMDocumentParserCallback.cpp.obj -c /C/ming64gcc48/projects/osm2pgrout
/c/ming64gcc48/cmake-2.8.11-win32-x86/bin/cmake.exe -E cmake_progress_report /C/ming64gcc48/projects/osm2pgrouting/build/CMakeFiles 10
[ 66%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/prog_options.cpp.obj
/c/ming64gcc48/mingw64/bin/g++.exe -D_FILE_OFFSET_BITS=64 -std=c++0x -Wall @CMakeFiles/osm2pgrouting.dir/includes_CXX.rsp -o CMakeFiles/osm2pgrouting.dir/src/prog_options.cpp.obj -c /C/ming64gcc48/projects/osm2pgrouting/branches/
c:/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/prog_options.cpp: In function 'void get_option_description(boost::program_options::options_description&)':
c:/ming64gcc48/projects/osm2pgrouting/branches/2.1/src/prog_options.cpp:67:64: error: 'getlogin' was not declared in this scope
("user,u", po::value<string>()->default_value(getlogin()), "Name of the user, which have write access to the database.")
^
CMakeFiles/osm2pgrouting.dir/build.make:277: recipe for target `CMakeFiles/osm2pgrouting.dir/src/prog_options.cpp.obj' failed
make[2]: *** [CMakeFiles/osm2pgrouting.dir/src/prog_options.cpp.obj] Error 1
make[2]: Leaving directory `/projects/osm2pgrouting/build'
CMakeFiles/Makefile2:66: recipe for target `CMakeFiles/osm2pgrouting.dir/all' failed
make[1]: *** [CMakeFiles/osm2pgrouting.dir/all] Error 2
make[1]: Leaving directory `/projects/osm2pgrouting/build'
Makefile:119: recipe for target `all' failed
make: *** [all] Error 2
I should also note this compiling against PostgreSQL 9.4
@robe2 do you think it might be related to #39 ?
@dkastl @sanak I went to see https://github.com/pgRouting/osm2pgrouting/blob/master/cmake/FindPostgreSQL.cmake#L45 looks like it hs only up to 9.1
I also found this might be related: #59
Get login: http://linux.die.net/man/3/getlogin What would be the equivalent for windows?
@cvvergara From FindPostgreSQL.cmake history, you seem to revert my improvement. https://github.com/pgRouting/osm2pgrouting/commits/develop/cmake/FindPostgreSQL.cmake But, was there some problem in my modification ?
@sanak Sorry, I wasn't working on my fork :( and I messed up.
I can't figure out how to get those fixes from the history. Can you please merge it again?
Vicky
@cvvergara The operations will not be merging my old commit, but reverting the following your commits.
- https://github.com/pgRouting/osm2pgrouting/commit/f81c278ad067f4cb8d53700c88dfc5da2082243d
- https://github.com/pgRouting/osm2pgrouting/commit/0d663a5dc3cfbf7c9cdc2846666603d2588c6458
Are you okay for me to do the following ?
git checkout develop git revert f81c278 git revert 0d663a5 git push origin develop git checkout master git revert f81c278 git revert 0d663a5 git push origin master
@sanak do what you need to do. The working directories now are others different than develop and mster
@cvvergara Okay, thanks for confirmation. I will start to check it.
@cvvergara, @robe2 I just created the pull request #109. If you have a time, could you check it a bit ? By the way, I think that some more review is necessary for recent cmake setting modification. Because there seems to be other issues. (Duplicate boost package including, fixed (/usr/) installation path .etc)
And in my opinion, master
branch should be reset once to Mar 18, 2015 by executing the followings.
git checkout master git reset --hard 3e1f162 git push origin master
But how do you think about that ?
@sanak About master, I messed up with it (got confused when I was merging @sarthak-0415 branches) I think its good to keep the old version until we finish the new version. So please go ahead.
About the merge @robe2 and me, we will test and will post if the issues you mention affect us (or any other issue). for example I have boost 1.58 and 1.55 in my computer, but my local tests I do them with 1.55.
@cvvergara
Okay, thanks for confirmation.
But sorry, I become to think to resetting master
to May 29, 2015 (https://github.com/pgRouting/osm2pgrouting/commit/02ee463547bd1bc118e888746355a2bab5dc3d3d) which add "Gitter badge" may be good.
If there is no objection about that, I will do it about 24 hours later.
@sanak No objection, Regina, Sarthak and me are working in other branches. Please do when you have time.
@cvvergara Okay, thanks for confirmation. I will start to do it now.
@cvvergara
Sorry, I just noticed that I don't have direct write access to pgRouting/osm2pgrouting,
and sending pull request with "reset --hard" seems to be impossible.
I also found that resetting master
to May 29, 2015 (https://github.com/pgRouting/osm2pgrouting/commit/02ee463547bd1bc118e888746355a2bab5dc3d3d) seems to be difficult because of merging order.
So, could you do the following ?
git checkout master git reset --hard 3e1f162 git push origin master -f
I will add you to the osm2pgrouting team.
@sanak Master is now on 3e1f162 @dkastl Do we leave develop like it is now, or do we also go back in time?
@cvvergara, is it planned to merge current development tree into develop
branch soon?
I think for develop
it's just important that we don't have something there for too long, that is broken.
@dkastl Right now it has the work we've done so far, (expect the last changes I've made that include incremental topology)
Then I would leave it as it is now and won't roll back something.