<div dir="ltr">Arg... what are those config options doing down in ogr/GNUMakefile?!?!?!?<div><br></div><div>The ifeq checks seem reasonable, everything else, not so much.</div><div><br></div><div><div>find . -name GNUmakefile | xargs grep HAVE_XERCES</div><div>./ogrsf_frmts/gmlas/GNUmakefile:CPPFLAGS :=<span class="gmail-Apple-tab-span" style="white-space:pre">   </span>-I../mem -I../geojson $(JSON_INCLUDE) -I.. -I../.. -I../pgdump -DHAVE_XERCES=1 \</div><div>./ogrsf_frmts/ili/GNUmakefile:CPPFLAGS :=<span class="gmail-Apple-tab-span" style="white-space:pre">      </span>-I.. -I../.. -DHAVE_XERCES $(XERCES_INCLUDE) $(CPPFLAGS)</div><div>./ogrsf_frmts/nas/GNUmakefile:CPPFLAGS :=<span class="gmail-Apple-tab-span" style="white-space:pre">      </span>-I../gml -I.. -I../.. -DHAVE_XERCES=1 \</div><div>./ogrsf_frmts/GNUmakefile:SUBDIRS-$(HAVE_XERCES)<span class="gmail-Apple-tab-span" style="white-space:pre">        </span>+= ili</div><div>./ogrsf_frmts/GNUmakefile:SUBDIRS-$(HAVE_XERCES)<span class="gmail-Apple-tab-span" style="white-space:pre"> </span>+= gmlas</div><div>./ogrsf_frmts/generic/GNUmakefile:ifeq ($(HAVE_XERCES),yes)</div><div>./ogrsf_frmts/generic/GNUmakefile:ifeq ($(HAVE_XERCES),yes)</div><div>./ogrsf_frmts/gml/GNUmakefile:ifeq ($(HAVE_XERCES),yes)</div><div>./ogrsf_frmts/gml/GNUmakefile:CPPFLAGS +=  -DHAVE_XERCES</div><div>./GNUmakefile:ifeq ($(HAVE_XERCES),yes)</div><div>./GNUmakefile:CPPFLAGS <span class="gmail-Apple-tab-span" style="white-space:pre">        </span>:=<span class="gmail-Apple-tab-span" style="white-space:pre">    </span>-DHAVE_XERCES $(XERCES_INCLUDE) $(CPPFLAGS)</div></div><div><br></div><div>This is so not cool:<br></div><div><br></div><div>gmlas/GNUmakefile</div><div><br></div><div># Booby trap....</div><div><div>CPPFLAGS :=<span class="gmail-Apple-tab-span" style="white-space:pre">   </span>-I../mem -I../geojson $(JSON_INCLUDE) -I.. -I../.. -I../pgdump -DHAVE_XERCES=1 \</div><div><span class="gmail-Apple-tab-span" style="white-space:pre">               </span> $(XERCES_INCLUDE) $(CPPFLAGS)</div></div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, May 19, 2017 at 1:55 PM, Even Rouault <span dir="ltr"><<a href="mailto:even.rouault@spatialys.com" target="_blank">even.rouault@spatialys.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><u></u>
<div style="font-family:'Sans Serif';font-size:9pt;font-weight:400;font-style:normal">
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">On vendredi 19 mai 2017 13:07:08 CEST <a href="mailto:svn_gdal@osgeo.org" target="_blank">svn_gdal@osgeo.org</a> wrote:</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> Author: goatbar</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> Date: 2017-05-19 13:07:08 -0700 (Fri, 19 May 2017)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> New Revision: 38502</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> Modified:</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">>    trunk/gdal/gcore/<wbr>gdaldrivermanager.cpp</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> Log:</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> gdaldrivermanager.cpp: Only call OGRCleanupXercesMutex() if HAVE_XERCES is</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> set.</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">HAVE_XERCES is never defined by port/GNUmakefile nor port/<a href="http://makefile.vc" target="_blank">makefile.vc</a></p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">$ valgrind --leak-check=full --show-reachable=yes ogrinfo poly.gml --config GML_PARSER XERCES --debug on -al -q</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085== 64 bytes in 1 blocks are still reachable in loss record 4 of 13</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    at 0x4C2DB8F: malloc (in /usr/lib/valgrind/vgpreload_<wbr>memcheck-amd64-linux.so)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5C588E3: CPLCreateMutexInternal(bool, int) (cpl_multiproc.cpp:1476)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5C5864A: CPLCreateOrAcquireMutexEx (cpl_multiproc.cpp:1344)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5C583C1: CPLMutexHolder::<wbr>CPLMutexHolder(_CPLMutex**, double, char const*, int, int) (cpl_multiproc.cpp:167)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x64F51C2: OGRInitializeXerces() (ogr_xerces.cpp:56)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5E677A1: GMLReader::SetupParserXerces() (gmlreader.cpp:292)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5E676AC: GMLReader::SetupParser() (gmlreader.cpp:262)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5E681BC: GMLReader::NextFeatureXerces() (gmlreader.cpp:516)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x5E68748: GMLReader::NextFeature() (gmlreader.cpp:629)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x60FFC13: OGRGMLLayer::GetNextFeature() (ogrgmllayer.cpp:157)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x4072E4: ReportOnLayer(OGRLayer*, char const*, char const*, OGRGeometry*, int, int, char**, int, int) (ogrinfo.cpp:793)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085==    by 0x40660A: main (ogrinfo.cpp:530)</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">==7085== </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> Modified: trunk/gdal/gcore/<wbr>gdaldrivermanager.cpp</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> ==============================<wbr>==============================<wbr>=======</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> --- trunk/gdal/gcore/<wbr>gdaldrivermanager.cpp 2017-05-19 19:22:19 UTC (rev</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> 38501) +++ trunk/gdal/gcore/<wbr>gdaldrivermanager.cpp  2017-05-19 20:07:08 UTC</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> (rev 38502) @@ -248,7 +248,9 @@</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">>  /* ------------------------------<wbr>------------------------------<wbr>-------- */</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">>      OSRCleanup();</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> +#ifdef HAVE_XERCES</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">>      OGRCleanupXercesMutex();</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> +#endif</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">>  /* ------------------------------<wbr>------------------------------<wbr>-------- */</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">>  /*      Cleanup VSIFileManager.                                         */</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> ______________________________<wbr>_________________</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> gdal-commits mailing list</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> <a href="mailto:gdal-commits@lists.osgeo.org" target="_blank">gdal-commits@lists.osgeo.org</a></p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">> <a href="https://lists.osgeo.org/mailman/listinfo/gdal-commits" target="_blank">https://lists.osgeo.org/<wbr>mailman/listinfo/gdal-commits</a></p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"> </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">-- </p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px">Spatialys - Geospatial professional services</p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"><a href="http://www.spatialys.com" target="_blank">http://www.spatialys.com</a></p></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">--<div><a href="http://schwehr.org" target="_blank">http://schwehr.org</a></div></div>
</div>