<html><body><div style="font-family: arial, helvetica, sans-serif; font-size: 12pt; color: #000000"><div><span style="color: rgb(0, 0, 0);" data-mce-style="color: #000000;">Thanks Even.</span></div><div><span style="color: rgb(0, 0, 0);" data-mce-style="color: #000000;">My project needs proj6, but as a test of cmake I installed proj9 with MacPorts - and find_package(Proj9 CONFIG REQUIRED) fails just as before.</span></div><div><span style="color: rgb(0, 0, 0);" data-mce-style="color: #000000;">Question - if the installed proj9 provides CONFIG support, I presume there is a <code class="docutils literal notranslate" style="background-color: rgb(236, 240, 243); padding: 0px 1px; font-size: 0.95em; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: justify; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;" data-mce-style="background-color: #ecf0f3; padding: 0px 1px; font-size: 0.95em; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: justify; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><span class="pre" style="hyphens: none;" data-mce-style="hyphens: none;">proj9-config.cmake</span></code><span style="font-family: sans-serif; font-size: 16px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: justify; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: rgb(255, 255, 255); float: none; display: inline !important;" data-mce-style="font-family: sans-serif; font-size: 16px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: justify; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff; float: none; display: inline !important;"> or </span><code class="docutils literal notranslate" style="background-color: rgb(236, 240, 243); padding: 0px 1px; font-size: 0.95em; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: justify; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;" data-mce-style="background-color: #ecf0f3; padding: 0px 1px; font-size: 0.95em; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: justify; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><span class="pre" style="hyphens: none;" data-mce-style="hyphens: none;">Proj9Config.cmake file somewhere. Where would I look for this file? I see /opt/local/lib/proj9 - but the file is not in there. Would this file be in there if proj9 supports CONFIG mode or is there some other place to look?</span></code></span><div style="clear: both;" data-mce-style="clear: both;"><br data-mce-bogus="1"></div></div><div><span style="color: rgb(0, 0, 0);" data-mce-style="color: #000000;">Thanks</span></div><div><span style="color: rgb(0, 0, 0);" data-mce-style="color: #000000;">Tom</span></div><div><br></div><div data-marker="__SIG_PRE__">--------------------------------------------------<br>Thomas C. O'Reilly<br>Monterey Bay Aquarium Research Institute<br>7700 Sandholdt Road<br>Moss Landing, California 95039-9644<br>831-775-1766 (voice)<br>831-775-1620 (FAX)<br>oreilly@mbari.org (email)<br>http://www.mbari.org (World-wide Web)<br> <br>"The machine does not isolate us from the great mysteries<br> of nature, but plunges us more deeply into them."<br> <br> - ANTOINE DE SAINT-EXUPERY<br> "Wind, Sand, and Stars" (1939)<br> </div><div><br></div><hr id="zwchr" data-marker="__DIVIDER__"><div data-marker="__HEADERS__"><b>From: </b>"Even Rouault" <even.rouault@spatialys.com><br><b>To: </b>"Tom O'Reilly" <oreilly@mbari.org>, "proj" <proj@lists.osgeo.org><br><b>Sent: </b>Wednesday, June 1, 2022 11:39:55 AM<br><b>Subject: </b>Re: [PROJ] cmake find_package() fails to find PROJ6 installed with MacPorts<br></div><div><br></div><div data-marker="__QUOTED_TEXT__"><p>Tom,</p>
<p>You should try to use a more recent version than PROJ 6.x (not
sure what "proj6" corresponds to in MacPorts). I believe PROJ
Config support was only added in PROJ > 6, or can only be
relied upon in those later versions</p>
<p>Even<br>
</p>
<div class="moz-cite-prefix">Le 01/06/2022 à 20:29, Tom O'Reilly a
écrit :<br>
</div>
<blockquote>
<div>
<div>
<div>I'm running cmake 3.22.4 on MacOS
11.6.</div>
<div>I installed proj6 with "sudo port proj6" which looks to be <span class="Object" id="OBJ_PREFIX_DWT2075_com_zimbra_url"><span class="Object" id="OBJ_PREFIX_DWT2081_com_zimbra_url"><a href="https://proj.org/install.html" rel="nofollow noopener noreferrer nofollow noopener noreferrer" target="_blank">the <span class="Object" id="OBJ_PREFIX_DWT171_com_zimbra_url"><span class="Object" id="OBJ_PREFIX_DWT212_com_zimbra_url">proj-recommended way to
install with MacPorts</span></span></a></span></span>.
I see the proj6 include/ and lib/ subdirectories in
/opt/local/lib/proj6, and set PROJ6_ROOT to
/opt/local/lib/proj6 accordingly in my applications's
CMakeLists.txt.</div>
<div><br>
</div>
<div>But CmakeLists.txt is unable to find
proj on the system. The <span class="Object" id="OBJ_PREFIX_DWT172_com_zimbra_url"><span class="Object" id="OBJ_PREFIX_DWT213_com_zimbra_url"><span class="Object" id="OBJ_PREFIX_DWT2076_com_zimbra_url"><span class="Object" id="OBJ_PREFIX_DWT2082_com_zimbra_url"><a href="https://proj.org/development/cmake.html" rel="nofollow noopener noreferrer nofollow noopener noreferrer nofollow noopener noreferrer" target="_blank">proj page
also says</a></span></span></span></span>: </div>
<div>
<p dir="ltr"><br>
</p>
<p dir="ltr">The
recommended way to use the PROJ library in a CMake
project is to link to the imported library target PROJ::proj
provide by the CMake configuration which comes with
the library. Typical usage is:</p>
<p dir="ltr"><br>
</p>
<p dir="ltr">
find_package(PROJ CONFIG REQUIRED) </p>
<p dir="ltr"><br>
</p>
<p dir="ltr">However
find_package() cannot find PROJ or PROJ6 on my system
- find_package() exits with this message:</p>
<p dir="ltr">CMake Error at CMakeLists.txt:95
(find_package):</p>
<p dir="ltr"> Could not find a package configuration
file provided by "PROJ6" with any of</p>
<p dir="ltr"> the following names:</p>
<p dir="ltr"> </p>
<p dir="ltr"> PROJ6Config.cmake</p>
<p dir="ltr"> proj6-config.cmake</p>
<p dir="ltr"><br>
</p>
<p dir="ltr">Moreover
I do not see any files named "proj*.cmake" in
/opt/local - somehow installing proj6 with MacPorts
did not include this package information? What am I
doing wrong?</p>
<p dir="ltr">Any
help much appreciated!</p>
<p dir="ltr"><br>
</p>
<p dir="ltr">Thanks</p>
<p dir="ltr">Tom</p>
<p dir="ltr"><br>
</p>
</div>
</div>
<div>--------------------------------------------------<br>
Thomas C.
O'Reilly<br>
Monterey
Bay Aquarium Research Institute<br>
7700
Sandholdt Road<br>
Moss
Landing, California 95039-9644<br>
831-775-1766
(voice)<br>
831-775-1620
(FAX)<br>
<a href="mailto:oreilly@mbari.org" target="_blank" rel="nofollow noopener noreferrer">oreilly@mbari.org</a>
(email)<br>
<a href="http://www.mbari.org" target="_blank" rel="nofollow noopener noreferrer">http://www.mbari.org</a>
(World-wide Web)<br>
<br>
"The
machine does not isolate us from the great mysteries<br>
of nature,
but plunges us more deeply into them."<br>
<br>
-
ANTOINE DE SAINT-EXUPERY<br>
"Wind,
Sand, and Stars" (1939)<br>
</div>
</div>
<br>
<fieldset class="moz-mime-attachment-header"></fieldset>
<pre class="moz-quote-pre">_______________________________________________
PROJ mailing list
<a href="mailto:PROJ@lists.osgeo.org" target="_blank" rel="nofollow noopener noreferrer">PROJ@lists.osgeo.org</a>
<a href="https://lists.osgeo.org/mailman/listinfo/proj" target="_blank" rel="nofollow noopener noreferrer">https://lists.osgeo.org/mailman/listinfo/proj</a>
</pre>
</blockquote>
<pre class="moz-signature">--
<a href="http://www.spatialys.com" target="_blank" rel="nofollow noopener noreferrer">http://www.spatialys.com</a>
My software is free, but my time generally not.</pre><br></div></div></body></html>