[gdal-dev] compiling gdal with esri file gdb

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
15 messages Options
Reply | Threaded
Open this post in threaded view
|

[gdal-dev] compiling gdal with esri file gdb

rgreenwood
I have an ESRI file gdb with curves that I need to import so I'm trying to build gdal 2.2 with filegdb. I'm on Ubuntu 16.04 with gcc 5.4. I checked out the the svn gdal and built it with any problems. 

Next I got the ESRI FileGDB_API_1_5_64 and copied the contents of the lib and include directories from the FileGDB_API/  into /usr/local/lib/ and /usr/local/include/ and did a ldconfig.
 Then:
   ./configure --with-fgdb=/usr/local/ --prefix=/opt/gdal-dev
   make
and I get numerous like:
   undefined reference to FileGDBAPI::Row
   undefined reference to FileGDBAPI::Guid
   etc.

I had also tried --with-fgdb=/path/to/FileGDB_API but got the same errors as when the lib and include files were copied to /usr/local/

Obviously I don't know what I'm doing. If anyone could give me any suggestions I would appreciate it.

Thanks,
Rich

--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Even Rouault-2

On mercredi 8 mars 2017 13:31:01 CET Richard Greenwood wrote:

> I have an ESRI file gdb with curves that I need to import so I'm trying to

> build gdal 2.2 with filegdb. I'm on Ubuntu 16.04 with gcc 5.4. I checked

> out the the svn gdal and built it with any problems.

>

> Next I got the ESRI FileGDB_API_1_5_64 and copied the contents of the lib

> and include directories from the FileGDB_API/ into /usr/local/lib/ and

> /usr/local/include/ and did a ldconfig.

 

I would have answered : see

 

https://trac.osgeo.org/gdal/wiki/FileGDB#HowtodealwithGCC5.1C11ABIonLinux

 

but I see you mention v1.5, which seems to be new.

 

I found

https://github.com/Esri/file-geodatabase-api/tree/master/FileGDB_API_1.5

 

Did you grab the FileGDB_API_1_5_64gcc51.tar.gz archive which must have been compiled with the C++11 ABI, and thus be compatible with GCC 5.4 ?

 

They mention in their README

" If you are using gcc 5.x and above you will need to use the FileGDB API version for GCC5 "

 

OK, I've just tried it myself on my Ubuntu 16.04 and it works. The test suite passes fine.

 

 

@Jürgen I see they now have a build for VS2015:

https://github.com/Esri/file-geodatabase-api/blob/master/FileGDB_API_1.5/FileGDB_API_1_5_VS2015.zip

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

jmckenna
Administrator
On 2017-03-08 4:49 PM, Even Rouault wrote:

>
>
>
> @Jürgen I see they now have a build for VS2015:
>
> https://github.com/Esri/file-geodatabase-api/blob/master/FileGDB_API_1.5/FileGDB_API_1_5_VS2015.zip
>
>


Wow very new indeed!  I've updated the download links on the wiki
(https://trac.osgeo.org/gdal/wiki/FileGDB) and I'll make this available
for the MS4W community.  Good find!

-jeff



--
Jeff McKenna
MapServer Consulting and Training Services
http://www.gatewaygeomatics.com/






_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Even Rouault-2

On jeudi 9 mars 2017 09:23:01 CET Jeff McKenna wrote:

> On 2017-03-08 4:49 PM, Even Rouault wrote:

> > @Jürgen I see they now have a build for VS2015:

> >

> > https://github.com/Esri/file-geodatabase-api/blob/master/FileGDB_API_1.5/F

> > ileGDB_API_1_5_VS2015.zip

> Wow very new indeed! I've updated the download links on the wiki

> (https://trac.osgeo.org/gdal/wiki/FileGDB) and I'll make this available

> for the MS4W community. Good find!

 

For those, at least on Linux, and which use GDAL compiled *without* --with-static-proj, you may get strange projection related failures at runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4 (without symbol hidding or renaming !!!), which conflicts with the proj.4 that GDAL will load dlopen(). Typical error emitted is about "unknown ellipsoid".

 

Even

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Robert Coup
Hi Even,


On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

 

For those, at least on Linux, and which use GDAL compiled *without* --with-static-proj, you may get strange projection related failures at runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4 (without symbol hidding or renaming !!!), which conflicts with the proj.4 that GDAL will load dlopen(). Typical error emitted is about "unknown ellipsoid".


I presume there's no workaround apart from --with-static-proj that doesn't require ESRI to change their build process?

Cheers,

Rob :)

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Even Rouault-2

On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> Hi Even,

>

> On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

> > For those, at least on Linux, and which use GDAL compiled *without*

> > --with-static-proj, you may get strange projection related failures at

> > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> > (without symbol hidding or renaming !!!), which conflicts with the proj.4

> > that GDAL will load dlopen(). Typical error emitted is about "unknown

> > ellipsoid".

>

> I presume there's no workaround apart from --with-static-proj that doesn't

> require ESRI to change their build process?

 

Hi Rob,

 

Yeah, I'm not even sure if --with-static-proj (which contrary to what its name my suggst will link against libproj.so if found) is completely safe, but it did work for me.

 

Strangely, even without --with-static-proj, it worked for me at first, but then failed when I probably reordered paths in my LD_LIBRARY_PATH. But I'm not so surprised: clashing symbols issues tend to be not predictable.

 

In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4 symbols. The functions are missing. But 5 or 6 global array structures, like the list of datums (pj_datums) are exposed in the data read-only section. The issue is that pj_datums doesn't seem to have the same structure: 2 columns per record in the ESRI version whereas official proj.4 expects 4 columns

 

$ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep pj_

00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

rgreenwood
If any of you can share any pointers on how to even get it to compile I'd appreciate it. I just need to access a esri file geodatabase that has curves and see if I can get them into postgis. If I have to have a separate build of gdal just for that I don't care. But I'm not too good with compiling gdal with 3rd party libraries.

Thanks,
Rich


On Fri, Mar 10, 2017 at 10:16 AM, Even Rouault <[hidden email]> wrote:

On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> Hi Even,

>

> On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

> > For those, at least on Linux, and which use GDAL compiled *without*

> > --with-static-proj, you may get strange projection related failures at

> > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> > (without symbol hidding or renaming !!!), which conflicts with the proj.4

> > that GDAL will load dlopen(). Typical error emitted is about "unknown

> > ellipsoid".

>

> I presume there's no workaround apart from --with-static-proj that doesn't

> require ESRI to change their build process?

 

Hi Rob,

 

Yeah, I'm not even sure if --with-static-proj (which contrary to what its name my suggst will link against libproj.so if found) is completely safe, but it did work for me.

 

Strangely, even without --with-static-proj, it worked for me at first, but then failed when I probably reordered paths in my LD_LIBRARY_PATH. But I'm not so surprised: clashing symbols issues tend to be not predictable.

 

In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4 symbols. The functions are missing. But 5 or 6 global array structures, like the list of datums (pj_datums) are exposed in the data read-only section. The issue is that pj_datums doesn't seem to have the same structure: 2 columns per record in the ESRI version whereas official proj.4 expects 4 columns

 

$ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep pj_

00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev



--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Damian Dixon
Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve geometries).


We have switched to OpenFileGDB because ESRI don't have their library available on Windows built against VS2015. Which also means we did not bother with the ESRI libraries on Linux either.

The other option is to use GDAL on Windows to convert the file. The way shared libraries work on Windows means that the proj4 issue you are seeing on Linux should not occur.

I don't know where you would get a Windows build of GDAL with FileGDB enabled. Someone on the list probably does.



On 11 March 2017 at 00:05, Richard Greenwood <[hidden email]> wrote:
If any of you can share any pointers on how to even get it to compile I'd appreciate it. I just need to access a esri file geodatabase that has curves and see if I can get them into postgis. If I have to have a separate build of gdal just for that I don't care. But I'm not too good with compiling gdal with 3rd party libraries.

Thanks,
Rich


On Fri, Mar 10, 2017 at 10:16 AM, Even Rouault <[hidden email]> wrote:

On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> Hi Even,

>

> On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

> > For those, at least on Linux, and which use GDAL compiled *without*

> > --with-static-proj, you may get strange projection related failures at

> > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> > (without symbol hidding or renaming !!!), which conflicts with the proj.4

> > that GDAL will load dlopen(). Typical error emitted is about "unknown

> > ellipsoid".

>

> I presume there's no workaround apart from --with-static-proj that doesn't

> require ESRI to change their build process?

 

Hi Rob,

 

Yeah, I'm not even sure if --with-static-proj (which contrary to what its name my suggst will link against libproj.so if found) is completely safe, but it did work for me.

 

Strangely, even without --with-static-proj, it worked for me at first, but then failed when I probably reordered paths in my LD_LIBRARY_PATH. But I'm not so surprised: clashing symbols issues tend to be not predictable.

 

In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4 symbols. The functions are missing. But 5 or 6 global array structures, like the list of datums (pj_datums) are exposed in the data read-only section. The issue is that pj_datums doesn't seem to have the same structure: 2 columns per record in the ESRI version whereas official proj.4 expects 4 columns

 

$ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep pj_

00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev



--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

fuadjsh@gmail.com
gisinternals.org has Gdal for Windows with file geodatabase support

It works fine
Fuad


-------- Original Message --------
Subject: Re: [gdal-dev] compiling gdal with esri file gdb
From: Damian Dixon
To: Richard Greenwood
CC: GDAL List


Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve geometries).


We have switched to OpenFileGDB because ESRI don't have their library available on Windows built against VS2015. Which also means we did not bother with the ESRI libraries on Linux either.

The other option is to use GDAL on Windows to convert the file. The way shared libraries work on Windows means that the proj4 issue you are seeing on Linux should not occur.

I don't know where you would get a Windows build of GDAL with FileGDB enabled. Someone on the list probably does.



On 11 March 2017 at 00:05, Richard Greenwood <[hidden email]> wrote:
If any of you can share any pointers on how to even get it to compile I'd appreciate it. I just need to access a esri file geodatabase that has curves and see if I can get them into postgis. If I have to have a separate build of gdal just for that I don't care. But I'm not too good with compiling gdal with 3rd party libraries.

Thanks,
Rich


On Fri, Mar 10, 2017 at 10:16 AM, Even Rouault <[hidden email]> wrote:

On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> Hi Even,

>

> On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

> > For those, at least on Linux, and which use GDAL compiled *without*

> > --with-static-proj, you may get strange projection related failures at

> > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> > (without symbol hidding or renaming !!!), which conflicts with the proj.4

> > that GDAL will load dlopen(). Typical error emitted is about "unknown

> > ellipsoid".

>

> I presume there's no workaround apart from --with-static-proj that doesn't

> require ESRI to change their build process?

 

Hi Rob,

 

Yeah, I'm not even sure if --with-static-proj (which contrary to what its name my suggst will link against libproj.so if found) is completely safe, but it did work for me.

 

Strangely, even without --with-static-proj, it worked for me at first, but then failed when I probably reordered paths in my LD_LIBRARY_PATH. But I'm not so surprised: clashing symbols issues tend to be not predictable.

 

In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4 symbols. The functions are missing. But 5 or 6 global array structures, like the list of datums (pj_datums) are exposed in the data read-only section. The issue is that pj_datums doesn't seem to have the same structure: 2 columns per record in the ESRI version whereas official proj.4 expects 4 columns

 

$ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep pj_

00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev



--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

rgreenwood
In reply to this post by Damian Dixon
On Sat, Mar 11, 2017 at 1:34 AM, Damian Dixon <[hidden email]> wrote:
Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve geometries).

I would prefer OpenFileGDB but how do I enable it? configure --help says:
   --with-fgdb=ARG  Include ESRI File Geodatabase support (ARG=FGDP API Path, yes or no)
so i tried 
  --with-fgdb=yes
and got error:
  configure: error: FileGDBAPI not found
so I got the ESRI SDK and configured with
  --with-fgdb=/mnt/e/src/FileGDB_API-64/
but when I make I get many "undefined reference to FileGDBAPI..." errors.

Thanks,
Rich
 


We have switched to OpenFileGDB because ESRI don't have their library available on Windows built against VS2015. Which also means we did not bother with the ESRI libraries on Linux either.

The other option is to use GDAL on Windows to convert the file. The way shared libraries work on Windows means that the proj4 issue you are seeing on Linux should not occur.

I don't know where you would get a Windows build of GDAL with FileGDB enabled. Someone on the list probably does.



On 11 March 2017 at 00:05, Richard Greenwood <[hidden email]> wrote:
If any of you can share any pointers on how to even get it to compile I'd appreciate it. I just need to access a esri file geodatabase that has curves and see if I can get them into postgis. If I have to have a separate build of gdal just for that I don't care. But I'm not too good with compiling gdal with 3rd party libraries.

Thanks,
Rich


On Fri, Mar 10, 2017 at 10:16 AM, Even Rouault <[hidden email]> wrote:

On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> Hi Even,

>

> On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

> > For those, at least on Linux, and which use GDAL compiled *without*

> > --with-static-proj, you may get strange projection related failures at

> > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> > (without symbol hidding or renaming !!!), which conflicts with the proj.4

> > that GDAL will load dlopen(). Typical error emitted is about "unknown

> > ellipsoid".

>

> I presume there's no workaround apart from --with-static-proj that doesn't

> require ESRI to change their build process?

 

Hi Rob,

 

Yeah, I'm not even sure if --with-static-proj (which contrary to what its name my suggst will link against libproj.so if found) is completely safe, but it did work for me.

 

Strangely, even without --with-static-proj, it worked for me at first, but then failed when I probably reordered paths in my LD_LIBRARY_PATH. But I'm not so surprised: clashing symbols issues tend to be not predictable.

 

In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4 symbols. The functions are missing. But 5 or 6 global array structures, like the list of datums (pj_datums) are exposed in the data read-only section. The issue is that pj_datums doesn't seem to have the same structure: 2 columns per record in the ESRI version whereas official proj.4 expects 4 columns

 

$ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep pj_

00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev



--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev




--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

rgreenwood
In reply to this post by fuadjsh@gmail.com
On Sat, Mar 11, 2017 at 3:49 AM, [hidden email] <[hidden email]> wrote:
gisinternals.org has Gdal for Windows with file geodatabase support

I don't see gdal 2.2 on gisinternals and I believe I need 2.2+ for curves in ESRI file geodatabases. Are you able to extract curves?

Thanks,
Rich


 
It works fine
Fuad


-------- Original Message --------
Subject: Re: [gdal-dev] compiling gdal with esri file gdb
From: Damian Dixon
To: Richard Greenwood
CC: GDAL List


Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve geometries).


We have switched to OpenFileGDB because ESRI don't have their library available on Windows built against VS2015. Which also means we did not bother with the ESRI libraries on Linux either.

The other option is to use GDAL on Windows to convert the file. The way shared libraries work on Windows means that the proj4 issue you are seeing on Linux should not occur.

I don't know where you would get a Windows build of GDAL with FileGDB enabled. Someone on the list probably does.



On 11 March 2017 at 00:05, Richard Greenwood <[hidden email]> wrote:
If any of you can share any pointers on how to even get it to compile I'd appreciate it. I just need to access a esri file geodatabase that has curves and see if I can get them into postgis. If I have to have a separate build of gdal just for that I don't care. But I'm not too good with compiling gdal with 3rd party libraries.

Thanks,
Rich


On Fri, Mar 10, 2017 at 10:16 AM, Even Rouault <[hidden email]> wrote:

On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> Hi Even,

>

> On 9 March 2017 at 23:03, Even Rouault <[hidden email]> wrote:

> > For those, at least on Linux, and which use GDAL compiled *without*

> > --with-static-proj, you may get strange projection related failures at

> > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> > (without symbol hidding or renaming !!!), which conflicts with the proj.4

> > that GDAL will load dlopen(). Typical error emitted is about "unknown

> > ellipsoid".

>

> I presume there's no workaround apart from --with-static-proj that doesn't

> require ESRI to change their build process?

 

Hi Rob,

 

Yeah, I'm not even sure if --with-static-proj (which contrary to what its name my suggst will link against libproj.so if found) is completely safe, but it did work for me.

 

Strangely, even without --with-static-proj, it worked for me at first, but then failed when I probably reordered paths in my LD_LIBRARY_PATH. But I'm not so surprised: clashing symbols issues tend to be not predictable.

 

In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4 symbols. The functions are missing. But 5 or 6 global array structures, like the list of datums (pj_datums) are exposed in the data read-only section. The issue is that pj_datums doesn't seem to have the same structure: 2 columns per record in the ESRI version whereas official proj.4 expects 4 columns

 

$ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep pj_

00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

 

Even

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev



--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev




--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Even Rouault-2
In reply to this post by rgreenwood

On samedi 11 mars 2017 07:15:27 CET Richard Greenwood wrote:

> On Sat, Mar 11, 2017 at 1:34 AM, Damian Dixon <[hidden email]>

>

> wrote:

> > Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve

> > geometries).

>

> I would prefer OpenFileGDB but how do I enable it?

 

It is a built-in driver. No option.

 

--with-fgdb is when you want to enable the FileGDB driver that relies on the ESRI SDK

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

Even Rouault-2
In reply to this post by rgreenwood

On samedi 11 mars 2017 07:18:47 CET Richard Greenwood wrote:

> On Sat, Mar 11, 2017 at 3:49 AM, [hidden email] <[hidden email]>

>

> wrote:

> > gisinternals.org has Gdal for Windows with file geodatabase support

>

> I don't see gdal 2.2 on gisinternals and I believe I need 2.2+ for curves

> in ESRI file geodatabases. Are you able to extract curves?

 

Here : http://gisinternals.com/development.php

 

2.2 is not yet released, so you need to fetch the development version (2.2.0dev)

 

>

> Thanks,

> Rich

>

> > It works fine

> > Fuad

> >

> >

> > -------- Original Message --------

> > Subject: Re: [gdal-dev] compiling gdal with esri file gdb

> > From: Damian Dixon

> > To: Richard Greenwood

> > CC: GDAL List

> >

> >

> > Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve

> > geometries).

> >

> > See: http://www.gdal.org/drv_openfilegdb.html

> >

> > We have switched to OpenFileGDB because ESRI don't have their library

> > available on Windows built against VS2015. Which also means we did not

> > bother with the ESRI libraries on Linux either.

> >

> > The other option is to use GDAL on Windows to convert the file. The way

> > shared libraries work on Windows means that the proj4 issue you are seeing

> > on Linux should not occur.

> >

> > I don't know where you would get a Windows build of GDAL with FileGDB

> > enabled. Someone on the list probably does.

> >

> >

> >

> > On 11 March 2017 at 00:05, Richard Greenwood <[hidden email]>

> >

> > wrote:

> >> If any of you can share any pointers on how to even get it to compile I'd

> >> appreciate it. I just need to access a esri file geodatabase that has

> >> curves and see if I can get them into postgis. If I have to have a

> >> separate

> >> build of gdal just for that I don't care. But I'm not too good with

> >> compiling gdal with 3rd party libraries.

> >>

> >> Thanks,

> >> Rich

> >>

> >>

> >> On Fri, Mar 10, 2017 at 10:16 AM, Even Rouault <

> >>

> >> [hidden email]> wrote:

> >>> On vendredi 10 mars 2017 12:57:05 CET Robert Coup wrote:

> >>> > Hi Even,

> >>> >

> >>> >

> >>> >

> >>> > On 9 March 2017 at 23:03, Even Rouault <[hidden email]>

> >>>

> >>> wrote:

> >>> > > For those, at least on Linux, and which use GDAL compiled *without*

> >>> > >

> >>> > > --with-static-proj, you may get strange projection related failures

> >>>

> >>> at

> >>>

> >>> > > runtime. This is due to libFileGDBAPI.so embedding a copy of proj.4

> >>> > >

> >>> > > (without symbol hidding or renaming !!!), which conflicts with the

> >>>

> >>> proj.4

> >>>

> >>> > > that GDAL will load dlopen(). Typical error emitted is about

> >>> > > "unknown

> >>> > >

> >>> > > ellipsoid".

> >>> >

> >>> > I presume there's no workaround apart from --with-static-proj that

> >>>

> >>> doesn't

> >>>

> >>> > require ESRI to change their build process?

> >>>

> >>> Hi Rob,

> >>>

> >>>

> >>>

> >>> Yeah, I'm not even sure if --with-static-proj (which contrary to what

> >>> its name my suggst will link against libproj.so if found) is completely

> >>> safe, but it did work for me.

> >>>

> >>>

> >>>

> >>> Strangely, even without --with-static-proj, it worked for me at first,

> >>> but then failed when I probably reordered paths in my LD_LIBRARY_PATH.

> >>> But

> >>> I'm not so surprised: clashing symbols issues tend to be not

> >>> predictable.

> >>>

> >>>

> >>>

> >>> In fact, libFileGDBAPI.so doesn't seem to embed all public proj.4

> >>> symbols. The functions are missing. But 5 or 6 global array structures,

> >>> like the list of datums (pj_datums) are exposed in the data read-only

> >>> section. The issue is that pj_datums doesn't seem to have the same

> >>> structure: 2 columns per record in the ESRI version whereas official

> >>> proj.4

> >>> expects 4 columns

> >>>

> >>>

> >>>

> >>> $ objdump -T /home/even/FileGDB_API-64gcc51/lib/libFileGDBAPI.so | grep

> >>> pj_

> >>>

> >>> 00000000010dc880 g DO .data.rel.ro 00000000000000b0 Base pj_datums

> >>>

> >>> 0000000001294080 g DO .data.rel.ro 0000000000000570 Base pj_projections

> >>>

> >>> 00000000010dbd20 g DO .data.rel.ro 0000000000000500 Base pj_pids

> >>>

> >>> 00000000010dc7a0 g DO .data.rel.ro 00000000000000e0 Base pj_primems

> >>>

> >>> 00000000010dc380 g DO .data.rel.ro 0000000000000420 Base pj_ellipses

> >>>

> >>> 00000000010dc220 g DO .data.rel.ro 0000000000000160 Base pj_linunits

> >>>

> >>>

> >>>

> >>> Even

> >>>

> >>>

> >>>

> >>>

> >>>

> >>> --

> >>>

> >>> Spatialys - Geospatial professional services

> >>>

> >>> http://www.spatialys.com

> >>>

> >>> _______________________________________________

> >>> gdal-dev mailing list

> >>> [hidden email]

> >>> https://lists.osgeo.org/mailman/listinfo/gdal-dev

> >>

> >> --

> >> Richard W. Greenwood, PLS

> >> www.greenwoodmap.com

> >>

> >> _______________________________________________

> >> gdal-dev mailing list

> >> [hidden email]

> >> https://lists.osgeo.org/mailman/listinfo/gdal-dev

 

 

--

Spatialys - Geospatial professional services

http://www.spatialys.com


_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

rgreenwood
In reply to this post by Even Rouault-2


On Sat, Mar 11, 2017 at 7:20 AM, Even Rouault <[hidden email]> wrote:

On samedi 11 mars 2017 07:15:27 CET Richard Greenwood wrote:

> On Sat, Mar 11, 2017 at 1:34 AM, Damian Dixon <[hidden email]>

>

> wrote:

> > Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve

> > geometries).

>

> I would prefer OpenFileGDB but how do I enable it?

 

It is a built-in driver. No option.

 

--with-fgdb is when you want to enable the FileGDB driver that relies on the ESRI SDK


Thanks! When I did ./configure and saw "FGDB support: no"  I thought that I had to set --with-fgdb.


--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: compiling gdal with esri file gdb

rgreenwood
Many thanks for your help and patience. Using ogr2ogr 2.2 with the OpenFileGDB driver reads ESRI file GDBs that contain curves. When converting to a shapefile curves are converted to a series of short tangents. When converting to postgis the curves appear to be preserved as curves. Very nice!

Rich


On Sat, Mar 11, 2017 at 8:21 AM, Richard Greenwood <[hidden email]> wrote:


On Sat, Mar 11, 2017 at 7:20 AM, Even Rouault <[hidden email]> wrote:

On samedi 11 mars 2017 07:15:27 CET Richard Greenwood wrote:

> On Sat, Mar 11, 2017 at 1:34 AM, Damian Dixon <[hidden email]>

>

> wrote:

> > Have you tried OpenFileGDB? (you will need GDAL 2.2 or newer for curve

> > geometries).

>

> I would prefer OpenFileGDB but how do I enable it?

 

It is a built-in driver. No option.

 

--with-fgdb is when you want to enable the FileGDB driver that relies on the ESRI SDK


Thanks! When I did ./configure and saw "FGDB support: no"  I thought that I had to set --with-fgdb.


--
Richard W. Greenwood, PLS
www.greenwoodmap.com



--
Richard W. Greenwood, PLS
www.greenwoodmap.com

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev