What have I forgotten about specifying which Perl should be /opt/local/bin/perl?

Kastus Shchuka macports at tprfct.net
Sat Jan 22 04:48:06 UTC 2022



> On Jan 21, 2022, at 5:42 PM, Gabriel Rosenkoetter <gr at eclipsed.net> wrote:
> 
> On 2022-01-21 00:21 EST, Kastus Shchuka wrote:
>> You got the link /opt/local/bin/perl -> perl5.28 from the default variant of perl5 as you did not specify which variant you wanted.
> 
> Yep, I understood that, and that's exactly what I would've expected: I just didn't realize that system didn't even have the "meta-port" installed at the beginning of this, and I'm rusty at best on port variants. :^>
> 
>> You need to install perl5 +perl5_34 if you want 5.34.
> 
> That's *precisely* the syntax I was trying to remember. Thank you!
> 
> But, I'm confused by the `port info perl5` output after doing that. Is the "[+]" just meant to imply "preferred version" rather than "active version"? That seems… at best confusing…?
> 


"port info" gives you information about existing variants of the port, not what you have installed. "[+]" means deafault variant which is used if you do not specify any variants. If you want to see what you actually installed, the syntax is "port installed and perl5"

This is for example what I have:

$ port installed and perl5
The following ports are currently installed:
  perl5 @5.26.1_0+perl5_28
  perl5 @5.28.3_0+perl5_28
  perl5 @5.28.3_0+perl5_30 (active)

If you want to see just the active port, you may trim down the output like this:

$ port installed and active and perl5
The following ports are currently installed:
  perl5 @5.28.3_0+perl5_30 (active)

Hope this helps to reduce confusion.

-Kastus


More information about the macports-users mailing list