<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">On Saturday, 9 November 2024 4:59:17 AM AEDT Barry DeZonia wrote:</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> If (totally fake example) I set the dependency in my jar to gdal 3.0.0 and</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> I only make calls within the 3.0.0 java bindings api in my code, then if</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> someone has gdal 3.7.x installed, will my code be able to interact with the</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> installed gdal?</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Possibly I didn't explain this very well.</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">There are at least four moving parts:</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"> - the end application</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"> - your code (which I'll call zorbage for this explanation, even though that is a generalisation)</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"> - the GDAL java bindings</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"> - the installed version of GDAL (the native libraries).</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Your options are to specify the GDAL java bindings (or not), and to try to influence the other parts. </p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Since zorbage isn't providing the native libraries, what you put in your maven dependencies makes no difference as to whether anything you do works or not.</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">It might not even be installed.</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">If you specify a version of the java bindings, they'll be added as a dependency by default. You can choose whether to bundle them, or assume its provided.</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">The key is that the end-application can override the version of the java bindings. </p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="font-size:1em;"><span style="font-family:Noto Mono;"><dependencyManagement></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">  <dependencies></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">    <dependency></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">      <groupId>io.github.bdezonia</groupId></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">      <artifactId>zorbage-gdal</artifactId></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">      <version>0.2.1</version></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">    </dependency></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">    <dependency></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">      <groupId>org.gdal</groupId></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">      <artifactId>gdal</artifactId></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">      <version>3.10.0</version></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;"><span style="background-color:#ffffff;"><span style="color:#4d4d4d;">    </dependency></span></span></p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">  </dependencies></p>
<p style="margin-top:0;margin-bottom:12;margin-left:0;margin-right:0;"></dependencyManagement></p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Brad</p>
</body>
</html>