<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<div class="moz-cite-prefix">Am 24.10.25 um 15:08 schrieb Andrew C
Aitchison via gdal-dev:<br>
</div>
<blockquote type="cite"
cite="mid:f6bbed22-e335-17d0-eb1a-e9f14e43bd3d@aitchison.me.uk">On
Fri, 24 Oct 2025, Javier Jimenez Shaw via gdal-dev wrote: <br>
<br>
<blockquote type="cite">One breaking change for GDAL 4.0 could be
to add "gdal" to the path of the
<br>
includes for external applications or libraries.
<br>
<br>
An external application should do :
<br>
#include <gdal/cpl_string.h>
<br>
instead of
<br>
#include <cpl_string.h>
<br>
</blockquote>
<br>
That does mean that if I have multiple versions installed <br>
they would have to be in eg <br>
~/gdal/4.0/include/gdal/cpl_string.h <br>
~/gdal/4.1/include/gdal/cpl_string.h <br>
~/gdal/git/include/gdal/cpl_string.h <br>
<br>
instead of just <br>
~/gdal/4.0/include/cpl_string.h <br>
~/gdal/4.1/include/cpl_string.h <br>
~/gdal/git/include/cpl_string.h <br>
</blockquote>
<p>AFAICS the original proposal doesn't imply a particular prefix.</p>
<p>There could also be<br>
/usr/include/gdal3/cpl_string.h<br>
/usr/include/gdal4.0/gdal/cpl_string.h</p>
<p>Compare with libxml2:<br>
/usr/include/libxml2/libxml/uri.h</p>
<p><br>
</p>
<blockquote type="cite"
cite="mid:f6bbed22-e335-17d0-eb1a-e9f14e43bd3d@aitchison.me.uk">
The people most affected by this change are probably packagers; do
we <br>
have many of those here, or would we need to ask somewhere where
they <br>
would see ? <br>
<br>
I note that the Ubuntu (and presumably Debian) libgdal-dev package
<br>
already has its header files in /usr/include/gdal/ <br>
and the libmapserver-dev package has /usr/include/gdal in the
cmake <br>
setting: MAPSERVER_INCLUDE_DIRS <br>
so your suggestion might be a no-op for Ubuntu developers. <br>
<br>
</blockquote>
<p>It is not so easy, see my example. If you don't want to allow
gdal to add /usr/include (or similar top-level prefixes) to the
search path, you must still add another subdir.</p>
<p>Are there particular GDAL include files which are prone to name
clashes?<br>
</p>
<p>Kai.<br>
</p>
<p><br>
</p>
</body>
</html>