I am trying to find the area of some geometries in France using [`ogr2ogr`][1]. The spread of these geometries span multiple UTM zones (see [Réunion][2], [Guyane][3]).

I have seen [`get_GeodesicArea`][4], which seems to do exactly what I need:

> Get the area of the (closed) curve, considered as a surface on the
> underlying ellipsoid of the SRS attached to the geometry.

It also says:

> Note that geometries with circular arcs will be linearized in their
> original coordinate space first, so the resulting geodesic area will
> be an approximation.

This is ok for my usecase.

I have also found [a reference][5] to `OGR2SQLITE_ST_GeodesicArea`.

**Reproducible setup**

Here is `franceTest.geojson`:

    {
    "type": "FeatureCollection",
    "name": "franceTest",
    "crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } },
    "features": [
    { "type": "Feature", "properties": { }, "geometry": { "type": "Polygon", "coordinates": [ [ [ -53.27917836, 4.34657742 ], [ -53.65825646, 3.86953154 ], [ -52.93198534, 3.29672455 ], [ -53.27917836, 4.34657742 ] ] ] } },
    { "type": "Feature", "properties": { }, "geometry": { "type": "Polygon", "coordinates": [ [ [ 55.52739964, -21.00728513 ], [ 55.44252555, -21.09369598 ], [ 55.65702552, -21.13256448 ], [ 55.52739964, -21.00728513 ] ] ] } }
    ]
    }

**Attempts**

I tried the following:

    ogr2ogr franceOut.geojson franceTest.geojson -sql "SELECT ST_GeodesicArea(geometry) as area FROM franceTest"

Output: 

    ERROR 1: Undefined function 'ST_GeodesicArea' used.

Then I tried to use [SQLite][6]:
    
    ogr2ogr franceOut.geojson franceTest.geojson -dialect SQLite -sql "SELECT ST_GeodesicArea(geometry) as area FROM franceTest"

Output:

    ERROR 1: In ExecuteSQL(): sqlite3_prepare_v2(SELECT ST_GeodesicArea(geometry) as area FROM franceTest): no such function: ST_GeodesicArea

Then I tried to use [OGR SQL dialect][7]:

    ogr2ogr franceOut.geojson franceTest.geojson -dialect OGRSQL -sql "SELECT ST_GeodesicArea(geometry) as area FROM franceTest"

Output:

    ERROR 1: Undefined function 'ST_GeodesicArea' used.

Then I tried, without having any good reason:
    
    ogr2ogr franceOut.geojson franceTest.geojson -sql "SELECT GeodesicArea(geometry) as area FROM franceTest"

Output:

    ERROR 1: Undefined function 'GeodesicArea' used.


**How can I call `get_GeodesicArea`, or equivalent function using `ogr2ogr`?**


  [1]: https://gdal.org/programs/ogr2ogr.html
  [2]: https://en.wikipedia.org/wiki/R%C3%A9union
  [3]: https://en.wikipedia.org/wiki/French_Guiana
  [4]: https://gdal.org/api/ogrgeometry_cpp.html#classOGRLineString_1a977e72600ef55436f7d9879208ee442d
  [5]: https://github.com/OSGeo/gdal/blob/2a11f6b51bdff033da25c5a178a848427262c048/ogr/ogrsf_frmts/sqlite/ogrsqlitesqlfunctions.cpp#L633
  [6]: https://gdal.org/user/sql_sqlite_dialect.html
  [7]: https://gdal.org/user/ogr_sql_dialect.html