Open cvvergara opened 9 years ago
Above issue seems to be same as #59 . @aj07mm comment: https://github.com/pgRouting/osm2pgrouting/issues/59#issuecomment-105255976
I fixed it already, so I think that using develop
branch will solve the problem.
My comment: https://github.com/pgRouting/osm2pgrouting/issues/59#issuecomment-105715588
My pull request: https://github.com/pgRouting/osm2pgrouting/pull/61
The just used master and it didn't generate me the problem, but using develop it did.
Oh, okay. (Sorry for unchecking the following link.) http://gis.stackexchange.com/questions/149426/error-while-installing-osm2pgrouting-ubuntu14-04
Then, my fix may be the issue's cause... I will check it also on my Ubuntu VirtualBox environment.
in master
mapas@cvergara:~/osm2pgrouting/osm2pgrouting_repo/build$ git status
On branch master
Your branch is up-to-date with 'origin/master'.
mapas@cvergara:~/osm2pgrouting/osm2pgrouting_repo/build$ make
Scanning dependencies of target osm2pgrouting
[ 7%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/XMLParser.cpp.o
[ 14%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/OSMDocumentParserCallback.cpp.o
[ 21%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Type.cpp.o
[ 28%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/osm2pgrouting.cpp.o
[ 35%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Node.cpp.o
[ 42%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Way.cpp.o
[ 50%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Relation.cpp.o
[ 57%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/math_functions.cpp.o
[ 64%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Class.cpp.o
[ 71%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/utils.cpp.o
[ 78%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/OSMDocument.cpp.o
[ 85%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/ConfigurationParserCallback.cpp.o
[ 92%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.o
[100%] Building CXX object CMakeFiles/osm2pgrouting.dir/src/Configuration.cpp.o
Linking CXX executable osm2pgrouting
[100%] Built target osm2pgrouting
mapas@cvergara:~/osm2pgrouting/osm2pgrouting_repo/build$ sudo make install
[sudo] password for mapas:
Sorry, try again.
[sudo] password for mapas:
[100%] Built target osm2pgrouting
Install the project...
-- Install configuration: ""
-- Installing: /usr/share/bin/osm2pgrouting
-- Up-to-date: /usr/share/osm2pgrouting/COPYING
-- Installing: /usr/share/osm2pgrouting/Readme.md
-- Up-to-date: /usr/share/osm2pgrouting/mapconfig.xml
-- Up-to-date: /usr/share/osm2pgrouting/mapconfig_for_cars.xml
wierd things happen, I didnt get it now in develop.
Okay, thanks for information.
But I here is part of my history:
mapas@cvergara:~/osm2pgrouting/osm2pgrouting_repo$
-- Boost version: 1.55.0
-- Boost version: 1.55.0
-- Found the following Boost libraries:
-- program_options
-- Configuring done
-- Generating done
-- Build files have been written to: /home/mapas/osm2pgrouting/osm2pgrouting_repo/build
Linking CXX executable osm2pgrouting
CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.o: In function `Export2DB::~Export2DB()':
Export2DB.cpp:(.text+0x31d): undefined reference to `PQfinish'
CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.o: In function `Export2DB::connect()':
Export2DB.cpp:(.text+0x386): undefined reference to `PQconnectdb'
Export2DB.cpp:(.text+0x39f): undefined reference to `PQstatus'
CMakeFiles/osm2pgrouting.dir/src/Export2DB.cpp.o: In function `Export2DB::createTables()':
@sanak Lets do something, @sarthak-0415 is working on osm2pgrouting, so I will make sure it works for linux first, and then we move to mac.
@cvvergara
Hmm...
On my Ubuntu 14.04 VirtualBox environment, there was no error on both of master
and develop
branch. (The following is develop
branch result.)
By the way, I couldn't understand why vagvaf did the following.
I also have changed the #include "libpq-fe.h" to #include postgresql/libpq-fe.h" in the src/Export2DB.h.
In my understanding, above changing include path is not necessary.
Now that I think about it, and wnet carefully on my history I think vagvaf might be @sarthak-0415.
Okay.
I had this error as well, and posted the following response on GIS.SE:
I had this error on a Linux machine that did not have postgresql installed.
The solution was to simply install libpq-dev
via the following command:
sudo apt-get install libpq-dev
The /user/include/postgresql/
directory and libpq-fe.h
were created just fine, and when I did the make / make install, there were no issues.
Here's the thread I found the solution on: http://stackoverflow.com/questions/6040583/cant-find-the-libpq-fe-h-header-when-trying-to-install-pg-gem
@sanak
Can you please verify and suggest so I can put a comment on the
dependencies installation page
@cvvergara Okay, I will check it again at this weekend.
my os is centos6.6, (Note that the parameter is '/usr/pgsql-9.3/lib/libpq.so ' instead of '/usr/pgsql-9.3/lib' ) :
cmake -DPOSTGRESQL_INCLUDE_DIR:PATH=/usr/pgsql-9.3/include -DPOSTGRESQL_LIBRARIES:PATH=/usr/pgsql-9.3/lib/libpq.so -H. -Bbuild
Joseph post