Re: [mapserver-users] Cannot compile mapserver 7 with postgis
Hi Jonas, now it works with PostGis support. I suppose that the problems was in the -DCMAKE_PREFIX_PATH="/usr/lib64;/usr/pgsql-11;/usr/lib64/oracle/12.1/client64/sdk/include" \ I was using : without double quotes around the full string and you use double quotes and semicolons to split the paths. Thanks. Sebastiano Laini Web Developer Buchanan Computing From: Jonas Lund Nielsen [mailto:jo...@sdfe.dk] Sent: 19 June 2019 10:11 To: Sebastiano Laini ; 'mapserver-users@lists.osgeo.org' Subject: SV: [mapserver-users] Cannot compile mapserver 7 with postgis I have had success compiling MapServer 7.4 on RHEL7 as noted below. I guess it should be somewhat similar to CentOS. Just remove whatever Oracle-specific and other options you might not need. I don't think MapServer has PostGIS as a direct build-dependency. It is unclear to me from your post, whether you have a previous build working with an earlier version, and the problem just occurred with an update to proj 6? So please bear in mind that this build was relying on proj 5.2 and gdal 2.4. I have installed "postgresql11.x86_64", "postgresql11-devel.x86_64" and "postgresql11-libs.x86_64" from the postgres yum repository: https://download.postgresql.org/pub/repos/yum/11/redhat/rhel-7-x86_64/pgdg-redhat11-11-2.noarch.rpm yum install pgdg-redhat11-11-2.noarch.rpm (installs the repository, not the above three packages) cmake3 -DINSTALL_LIB_DIR:PATH=/usr/lib64 \ -DCMAKE_PREFIX_PATH="/usr/lib64;/usr/pgsql-11;/usr/lib64/oracle/12.1/client64/sdk/include" \ -DWITH_WMS=ON \ -DWITH_WFS=ON \ -DWITH_WCS=ON \ -DWITH_SOS=ON \ -DWITH_KML=ON \ -DWITH_CLIENT_WFS=ON \ -DWITH_CLIENT_WMS=ON \ -DWITH_CURL=ON \ -DWITH_PROJ=ON \ -DWITH_GEOS=ON \ -DWITH_ICONV=ON \ -DWITH_LIBXML2=ON \ -DWITH_OGR=ON \ -DWITH_GDAL=ON \ -DWITH_GIF=ON \ -DWITH_CAIRO=OFF \ -DWITH_RSVG=OFF\ -DWITH_POSTGIS=ON \ -DWITH_ORACLESPATIAL=ON \ -DWITH_FCGI=ON \ -DWITH_THREAD_SAFETY=OFF \ -DWITH_PYTHON=OFF \ -DWITH_PERL=OFF \ -DWITH_JAVA=OFF \ -DWITH_PHP=OFF \ -DWITH_APACHE_MODULE=OFF \ -DWITH_FRIBIDI=OFF \ -DWITH_HARFBUZZ=OFF \ -DWITH_PROTOBUFC=ON .. Best regards /Jonas Fra: mapserver-users mailto:mapserver-users-boun...@lists.osgeo.org>> På vegne af Sebastiano Laini Sendt: 18. juni 2019 15:24 Til: 'mapserver-users@lists.osgeo.org' mailto:mapserver-users@lists.osgeo.org>> Emne: [mapserver-users] Cannot compile mapserver 7 with postgis For the version that I use I need Proj6 I don't really understand why I can compile other software correctly and MapServer no, I don't even understand what should I put https://github.com/Kitware/CMake/blob/master/Modules/FindPostgreSQL.cmake this is the first error that appear, Cmake Warning at cmake/FindPostgreSQL.cmake:21 (message) Pg_config not found, will try some defaults Call stacks (most recent call first): cMakeLists.txt:755 (find_package) and the second one is: cMake error at CmakeLists.txt:73 (messages) POSTGIS library/components/dependency could not be found. HINTS: -disable postgis... - add cmake_prefix_path... Call stack (most recent call firsts) CMakeLists.txt:590 (report_optional_not_found) Sebastiano Laini Web Developer Buchanan Computing ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Cannot compile mapserver 7 with postgis
For the version that I use I need Proj6 I don't really understand why I can compile other software correctly and MapServer no, I don't even understand what should I put https://github.com/Kitware/CMake/blob/master/Modules/FindPostgreSQL.cmake this is the first error that appear, Cmake Warning at cmake/FindPostgreSQL.cmake:21 (message) Pg_config not found, will try some defaults Call stacks (most recent call first): cMakeLists.txt:755 (find_package) and the second one is: cMake error at CmakeLists.txt:73 (messages) POSTGIS library/components/dependency could not be found. HINTS: -disable postgis... - add cmake_prefix_path... Call stack (most recent call firsts) CMakeLists.txt:590 (report_optional_not_found) Sebastiano Laini Web Developer Buchanan Computing ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Cannot compile mapserver 7 with postgis
To be honest I'm sticking with PROJ 5.2.0 in all of my distributions and deployments, until things catch up; so you're treading into water that I haven't been into ;) -jeff -- Jeff McKenna MapServer Consulting and Training Services https://gatewaygeomatics.com/ On 2019-06-18 9:05 AM, Sebastiano Laini wrote: Hi all, I’m trying to compile MapServer 7 with: Proj 6 Geos 3.7 Gdal 3.0 PostGis 2.5 Postgres 10 But for some reason it complaining about pg_config not found, I usually use /usr/pgsql-10/bin/pg_config to compile software that need the same file but with MapServer 7 I can’t Here my cmake : cmake -DCMAKE_INSTALL_PREFIX=/opt \ -DCMAKE_PREFIX_PATH=/usr/pgsql-10/bin:/usr/local/src/postgis-2.5.2:/usr/local:/opt:/usr/local/src \ -DWITH_CLIENT_WFS=ON \ -DWITH_CLIENT_WMS=ON \ -DWITH_CURL=ON \ -DWITH_SOS=ON \ -DWITH_FCGI=0 \ -DWITH_PERL=0 \ -DWITH_RUBY=0 \ -DWITH_JAVA=0 \ -DWITH_CSHARP=0 \ -DWITH_PYTHON=0 \ -DWITH_SVGCAIRO=0 \ -DWITH_FRIBIDI=0 \ -DWITH_PROTOBUFC=0 \ -DWITH_CAIRO=0 \ -DWITH_HARFBUZZ=0 \ -DWITH_ORACLESPATIAL=0 \ -DWITH_MSSQL2008=0 \ ../ >../configure.out.txt How can I compile it with PostGis support? Sebastiano Laini Web Developer Buchanan Computing ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Cannot compile mapserver 7 with postgis
And yes I have PostgreSQL 10 / PostgreSQL 10 server and PostgreSQL 10 devel installed, there is no such PostgreSQL 10 server devel for centos 7 Those comes directly from the PostgreSQL download page: postgresql-client libraries and client binaries postgresql-server core database server postgresql-contribadditional supplied modules postgresql-devel libraries and headers for C language development Sebastiano Laini Web Developer Buchanan Computing ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
Re: [mapserver-users] Cannot compile mapserver 7 with postgis
I've added the 2 lines in the cmake but nothing to do, my file is in /usr/pgsql-10/lib/libpq.so maybe because I'm on centos 7 cmake -DCMAKE_INSTALL_PREFIX=/opt \ -DCMAKE_PREFIX_PATH=/usr/pgsql-10:/usr/local/src/postgis-2.5.2:/usr/local:/opt:/usr/local/src \ -DWITH_CLIENT_WFS=ON \ -DWITH_CLIENT_WMS=ON \ -DPOSTGRESQL_LIBRARY=/usr/pgsql-10/lib/libpq.so \ -DWITH_POSTGIS=ON \ -DWITH_CURL=ON \ -DWITH_SOS=ON \ -DWITH_FCGI=0 \ -DWITH_PERL=0 \ -DWITH_RUBY=0 \ -DWITH_JAVA=0 \ -DWITH_CSHARP=0 \ -DWITH_PYTHON=0 \ -DWITH_SVGCAIRO=0 \ -DWITH_FRIBIDI=0 \ -DWITH_PROTOBUFC=0 \ -DWITH_CAIRO=0 \ -DWITH_HARFBUZZ=0 \ -DWITH_ORACLESPATIAL=0 \ -DWITH_MSSQL2008=0 \ ../ >../configure.out.txt Sebastiano Laini Web Developer Buchanan Computing ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users
[mapserver-users] Cannot compile mapserver 7 with postgis
Hi all, I'm trying to compile MapServer 7 with: Proj 6 Geos 3.7 Gdal 3.0 PostGis 2.5 Postgres 10 But for some reason it complaining about pg_config not found, I usually use /usr/pgsql-10/bin/pg_config to compile software that need the same file but with MapServer 7 I can't Here my cmake : cmake -DCMAKE_INSTALL_PREFIX=/opt \ -DCMAKE_PREFIX_PATH=/usr/pgsql-10/bin:/usr/local/src/postgis-2.5.2:/usr/local:/opt:/usr/local/src \ -DWITH_CLIENT_WFS=ON \ -DWITH_CLIENT_WMS=ON \ -DWITH_CURL=ON \ -DWITH_SOS=ON \ -DWITH_FCGI=0 \ -DWITH_PERL=0 \ -DWITH_RUBY=0 \ -DWITH_JAVA=0 \ -DWITH_CSHARP=0 \ -DWITH_PYTHON=0 \ -DWITH_SVGCAIRO=0 \ -DWITH_FRIBIDI=0 \ -DWITH_PROTOBUFC=0 \ -DWITH_CAIRO=0 \ -DWITH_HARFBUZZ=0 \ -DWITH_ORACLESPATIAL=0 \ -DWITH_MSSQL2008=0 \ ../ >../configure.out.txt How can I compile it with PostGis support? Sebastiano Laini Web Developer Buchanan Computing ___ mapserver-users mailing list mapserver-users@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/mapserver-users