[postgis-users] Problems creating postgis extension

Stephen Woodbridge woodbri at swoodbridge.com
Tue May 30 12:51:56 PDT 2017


I have the following installed:

$ apt-show-versions | grep proj
libproj-dev:amd64 4.8.0-3~precise2 newer than version in archive
libproj0:amd64 4.8.0-3~precise2 newer than version in archive
proj-bin:amd64 4.8.0-3~precise2 newer than version in archive
proj-data:amd64 4.8.0-3~precise2 newer than version in archive



On 5/30/2017 3:42 PM, Martin Moore wrote:
> ld.so.conf.d# ldd /usr/lib/postgresql/9.6/lib/postgis_topology-2.3.so
> 	linux-vdso.so.1 (0x00007ffe80def000)
> 	libgeos_c.so.1 => /usr/lib/libgeos_c.so.1 (0x00007f267ac1f000)
> 	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f267a874000)
> 	libgeos-3.4.2.so => /usr/lib/libgeos-3.4.2.so (0x00007f267a4cc000)
> 	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f267a1c1000)
> 	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f2679ec0000)
> 	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f2679ca9000)
> 	/lib64/ld-linux-x86-64.so.2 (0x000055fafb1f0000)
> 
> 
> ld.so.conf.d# ldd /usr/lib/postgresql/9.6/lib/postgis-2.3.so
> 	linux-vdso.so.1 (0x00007ffd42f59000)
> 	liblwgeom-2.3.so.0 => /usr/lib/liblwgeom-2.3.so.0 (0x00007f2991122000)
> 	libgeos_c.so.1 => /usr/lib/libgeos_c.so.1 (0x00007f2990efb000)
> 	libproj.so.0 => /usr/local/lib/libproj.so.0 (0x00007f2990cb9000)
> 	libjson-c.so.2 => /lib/x86_64-linux-gnu/libjson-c.so.2 (0x00007f2990aae000)
> 	libxml2.so.2 => /usr/lib/x86_64-linux-gnu/libxml2.so.2 (0x00007f2990747000)
> 	libSFCGAL.so.1 => /usr/lib/x86_64-linux-gnu/libSFCGAL.so.1 (0x00007f298fd08000)
> 	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f298f95d000)
> 	libgeos-3.4.2.so => /usr/lib/libgeos-3.4.2.so (0x00007f298f5b6000)
> 	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f298f2aa000)
> 	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f298efa9000)
> 	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f298ed93000)
> 	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f298eb8e000)
> 	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f298e973000)
> 	liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007f298e750000)
> 	libCGAL.so.10 => /usr/lib/libCGAL.so.10 (0x00007f298e525000)
> 	libCGAL_Core.so.10 => /usr/lib/libCGAL_Core.so.10 (0x00007f298e2ec000)
> 	libmpfr.so.4 => /usr/lib/x86_64-linux-gnu/libmpfr.so.4 (0x00007f298e089000)
> 	libgmp.so.10 => /usr/lib/x86_64-linux-gnu/libgmp.so.10 (0x00007f298de05000)
> 	libosgDB.so.100 => /usr/lib/x86_64-linux-gnu/libosgDB.so.100 (0x00007f298daec000)
> 	libosgUtil.so.100 => /usr/lib/x86_64-linux-gnu/libosgUtil.so.100 (0x00007f298d712000)
> 	libosg.so.100 => /usr/lib/x86_64-linux-gnu/libosg.so.100 (0x00007f298d210000)
> 	libOpenThreads.so.20 => /usr/lib/x86_64-linux-gnu/libOpenThreads.so.20 (0x00007f298d008000)
> 	libboost_program_options.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_program_options.so.1.55.0 (0x00007f298cd90000)
> 	libboost_chrono.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_chrono.so.1.55.0 (0x00007f298cb87000)
> 	libboost_filesystem.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_filesystem.so.1.55.0 (0x00007f298c96f000)
> 	libboost_timer.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_timer.so.1.55.0 (0x00007f298c76a000)
> 	libboost_unit_test_framework.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_unit_test_framework.so.1.55.0 (0x00007f298c4bb000)
> 	libboost_date_time.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_date_time.so.1.55.0 (0x00007f298c2a9000)
> 	libboost_thread.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_thread.so.1.55.0 (0x00007f298c08e000)
> 	libboost_system.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_system.so.1.55.0 (0x00007f298be89000)
> 	libboost_serialization.so.1.55.0 => /usr/lib/x86_64-linux-gnu/libboost_serialization.so.1.55.0 (0x00007f298bc17000)
> 	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f298b9fa000)
> 	/lib64/ld-linux-x86-64.so.2 (0x0000563ba1460000)
> 	libGL.so.1 => /usr/lib/x86_64-linux-gnu/libGL.so.1 (0x00007f298b75f000)
> 	librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f298b557000)
> 	libexpat.so.1 => /lib/x86_64-linux-gnu/libexpat.so.1 (0x00007f298b32d000)
> 	libglapi.so.0 => /usr/lib/x86_64-linux-gnu/libglapi.so.0 (0x00007f298b103000)
> 	libXext.so.6 => /usr/lib/x86_64-linux-gnu/libXext.so.6 (0x00007f298aef0000)
> 	libXdamage.so.1 => /usr/lib/x86_64-linux-gnu/libXdamage.so.1 (0x00007f298aced000)
> 	libXfixes.so.3 => /usr/lib/x86_64-linux-gnu/libXfixes.so.3 (0x00007f298aae7000)
> 	libX11-xcb.so.1 => /usr/lib/x86_64-linux-gnu/libX11-xcb.so.1 (0x00007f298a8e4000)
> 	libX11.so.6 => /usr/lib/x86_64-linux-gnu/libX11.so.6 (0x00007f298a5a1000)
> 	libxcb-glx.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-glx.so.0 (0x00007f298a388000)
> 	libxcb-dri2.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-dri2.so.0 (0x00007f298a182000)
> 	libxcb-dri3.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-dri3.so.0 (0x00007f2989f7f000)
> 	libxcb-present.so.0 => /usr/lib/x86_64-linux-gnu/libxcb-present.so.0 (0x00007f2989d7c000)
> 	libxcb-sync.so.1 => /usr/lib/x86_64-linux-gnu/libxcb-sync.so.1 (0x00007f2989b74000)
> 	libxcb.so.1 => /usr/lib/x86_64-linux-gnu/libxcb.so.1 (0x00007f2989952000)
> 	libxshmfence.so.1 => /usr/lib/x86_64-linux-gnu/libxshmfence.so.1 (0x00007f2989750000)
> 	libXxf86vm.so.1 => /usr/lib/x86_64-linux-gnu/libXxf86vm.so.1 (0x00007f2989549000)
> 	libdrm.so.2 => /usr/lib/x86_64-linux-gnu/libdrm.so.2 (0x00007f298933c000)
> 	libXau.so.6 => /usr/lib/x86_64-linux-gnu/libXau.so.6 (0x00007f2989137000)
> 	libXdmcp.so.6 => /usr/lib/x86_64-linux-gnu/libXdmcp.so.6 (0x00007f2988f32000)
> 
> 
> 
> On 30/05/2017, 20:39, "postgis-users on behalf of Stephen Woodbridge" <postgis-users-bounces at lists.osgeo.org on behalf of woodbri at swoodbridge.com> wrote:
> 
>      What does ldd say for your library. I'm on Ubuntu and had installed pg
>      9.6 yet, but for 9.5 I have this:
>      
>      $ ldd /usr/lib/postgresql/9.5/lib/postgis_topology-2.3.so
>               linux-vdso.so.1 =>  (0x00007ffdb19fb000)
>               libgeos_c.so.1 => /usr/lib/libgeos_c.so.1 (0x00007f61b6e3c000)
>               libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f61b6a74000)
>               libgeos-3.4.2.so => /usr/lib/libgeos-3.4.2.so (0x00007f61b66ef000)
>               libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6
>      (0x00007f61b63eb000)
>               libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1
>      (0x00007f61b61d5000)
>               /lib64/ld-linux-x86-64.so.2 (0x00007f61b72d7000)
>               libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f61b5ece000)
>      
>      
>      On 5/30/2017 3:34 PM, Stephen Woodbridge wrote:
>      > On 5/30/2017 3:22 PM, Martin Moore wrote:
>      >> Thanks Steve – nothing returned.
>      >>
>      >> I’m guessing that’s wrong!
>      >
>      > No it doesn't return anything. It just makes sure the library is known
>      > to the dynamic loader. Hmm, I reread your message, you are missing a
>      > symbol, so it found the library ok.
>      >
>      > This sounds like a packaging issue of some kind. You should make sure
>      > that you are getting proj4, postgresql and postgis all from the same
>      > repository and not mixing and matching.
>      >
>      > -Steve
>      >
>      >
>      >> On 30/05/2017, 20:19, "postgis-users on behalf of Stephen Woodbridge"
>      >> <postgis-users-bounces at lists.osgeo.org on behalf of
>      >> woodbri at swoodbridge.com> wrote:
>      >>
>      >>      Try:
>      >>      sudo ldconfig
>      >>      and see if the helps.
>      >>      -Steve
>      >>      On 5/30/2017 2:12 PM, Martin Moore wrote:
>      >>      > Hi,
>      >>      >
>      >>      > On Debian Jessie 64bit, postgis 2.3, postgres 9.6 (both
>      >> installed using
>      >>      > apt-get)
>      >>      >
>      >>      > I can’t create postgis extension
>      >>      >
>      >>      >   psql -d mydb -c "CREATE EXTENSION postgis;"
>      >>      >
>      >>      > ERROR:  could not load library
>      >>      > "/usr/lib/postgresql/9.6/lib/postgis-2.3.so":
>      >>      > /usr/lib/postgresql/9.6/lib/postgis-2.3.so: undefined symbol:
>      >>      > pj_get_spheroid_defn
>      >>      >
>      >>      > But it is there:
>      >>      >
>      >>      >   objdump -t -T /usr/lib/postgresql/9.6/lib/postgis-2.3.so |
>      >> grep defn
>      >>      >
>      >>      > 0000000000000000      DF *UND* 0000000000000000
>      >>      > pj_get_spheroid_defn
>      >>      >
>      >>      > It appears to have proj 4.8
>      >>      >
>      >>      > ii  libproj0                               4.8.0-5
>      >>      >          amd64        Cartographic projection library
>      >>      >
>      >>      > ii  proj-bin                               4.8.0-5
>      >>      >          amd64        Cartographic projection library (tools)
>      >>      >
>      >>      > ii  proj-data                              4.8.0-5
>      >>      >          amd64        Cartographic projection filter and
>      >> library (datum
>      >>      > package)
>      >>      >
>      >>      > I’m not a Linux guru and this has me stumped!
>      >>      >
>      >>      > What am I missing?
>      >>      >
>      >>      > Thanks,
>      >>      >
>      >>      > Martin.
>      >>      >
>      >>      >
>      >>      >
>      >>      > _______________________________________________
>      >>      > postgis-users mailing list
>      >>      > postgis-users at lists.osgeo.org
>      >>      > https://lists.osgeo.org/mailman/listinfo/postgis-users
>      >>      >
>      >>      ---
>      >>      This email has been checked for viruses by Avast antivirus software.
>      >>      https://www.avast.com/antivirus
>      >>      _______________________________________________
>      >>      postgis-users mailing list
>      >>      postgis-users at lists.osgeo.org
>      >>      https://lists.osgeo.org/mailman/listinfo/postgis-users
>      >>
>      >>
>      >> _______________________________________________
>      >> postgis-users mailing list
>      >> postgis-users at lists.osgeo.org
>      >> https://lists.osgeo.org/mailman/listinfo/postgis-users
>      >>
>      >
>      
>      _______________________________________________
>      postgis-users mailing list
>      postgis-users at lists.osgeo.org
>      https://lists.osgeo.org/mailman/listinfo/postgis-users
> 
> 
> _______________________________________________
> postgis-users mailing list
> postgis-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/postgis-users
> 



More information about the postgis-users mailing list