<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hi,<br>
    <br>
    05.02.2012 16:55, Chaitanya kumar CH пишет:
    <blockquote
cite="mid:CAMKgpOafS3iP53jEfy34AuCd4xQa+eEJpQZ7qNfWTDsL_Jak6A@mail.gmail.com"
      type="cite">Dmitry,<br>
      <br>
      I not sure about KML and GeoJSON, but the GML driver need not be
      enabled for the exportToGML method to work. Even for the other
      two, the code associated with exporting the OGRGeometry to those
      formats seems to stand apart from the driver code.<br>
    </blockquote>
    I want to build GDAL without GML, KML and GEOJSON and I cannot do it
    because dependencies. I don't need exportToGML, exportToKML,
    exportToJson working in this library (as I don't check this drivers
    to build). The adding of ifdef will solve this.<br>
    <blockquote
cite="mid:CAMKgpOafS3iP53jEfy34AuCd4xQa+eEJpQZ7qNfWTDsL_Jak6A@mail.gmail.com"
      type="cite">
      <br>
      Also, these functions are occasionally used irrespective of the
      drivers.<br>
      <br>
      Check if there are any problems when the KML and GeoJSON drivers
      are disabled. If there are any, it's better to add your patch.<br>
      <br>
      <div class="gmail_quote">On Sat, Feb 4, 2012 at 10:45 PM, Dmitry
        Baryshnikov <span dir="ltr">&lt;<a moz-do-not-send="true"
            href="mailto:polimax@mail.ru">polimax@mail.ru</a>&gt;</span>
        wrote:<br>
        <blockquote class="gmail_quote" style="margin:0 0 0
          .8ex;border-left:1px #ccc solid;padding-left:1ex">
          <div bgcolor="#FFFFFF" text="#000000"> Hi all,<br>
            <br>
            OGRGeometry have such methods as exportToGML, exportToKML,
            exportToJson which always requires KML (not LIBKM), GML and
            GEOJSON code. <br>
            I think in exportToGML, exportToKML, exportToJson should be
            #ifdef KML_ENABLED GML_ENABLED, GEOJSON_ENABLED.<br>
            For example:
            <blockquote>char *OGRGeometry::exportToKML() const<br>
            </blockquote>
            <blockquote>{<br>
              #ifndef _WIN32_WCE<br>
              #if defined OGR_ENABLED &amp;&amp; defined KML_ENABLED<br>
                  return OGR_G_ExportToKML( (OGRGeometryH) this, NULL );<br>
              #else<br>
                  CPLError( CE_Failure, CPLE_AppDefined,<br>
                            "OGRGeometry::exportToKML() not supported in
              builds without OGR drivers." );<br>
                  return NULL;<br>
              #endif<br>
              #else<br>
                  CPLError( CE_Failure, CPLE_AppDefined,<br>
                            "OGRGeometry::exportToKML() not supported in
              the WinCE build." );<br>
                  return NULL;<br>
              #endif<br>
              }<br>
            </blockquote>
            Can I add such code?<br>
            <br>
            Best regards,<br>
                Dmitry<br>
          </div>
          <br>
          _______________________________________________<br>
          gdal-dev mailing list<br>
          <a moz-do-not-send="true"
            href="mailto:gdal-dev@lists.osgeo.org">gdal-dev@lists.osgeo.org</a><br>
          <a moz-do-not-send="true"
            href="http://lists.osgeo.org/mailman/listinfo/gdal-dev"
            target="_blank">http://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br>
        </blockquote>
      </div>
      <br>
      <br clear="all">
      <br>
      -- <br>
      Best regards,<br>
      Chaitanya kumar CH.<br>
      <br>
      +91-9494447584<br>
      17.2416N 80.1426E<br>
    </blockquote>
    Best regards,<br>
        Dmitry<br>
  </body>
</html>