[MacPorts] #56318: Base should know the installed version of the command line tools
MacPorts
noreply at macports.org
Wed Apr 18 01:50:45 UTC 2018
#56318: Base should know the installed version of the command line tools
-------------------------+--------------------
Reporter: ryandesign | Owner: (none)
Type: enhancement | Status: new
Priority: Normal | Milestone:
Component: base | Version:
Keywords: | Port:
-------------------------+--------------------
Just as MacPorts already knows the version of Xcode (in the `xcodeversion`
variable), it should know the version of the command line tools. This
could then be [ticket:52575 printed in the log] and verified by the
configure script as the Xcode version already is.
Per [https://apple.stackexchange.com/questions/180957/determine-xcode-
command-line-tools-version this post], this information can be obtained on
Mavericks or later using:
{{{
pkgutil --pkg-info=com.apple.pkg.CLTools_Executables
}}}
e.g.:
{{{
$ pkgutil --pkg-info=com.apple.pkg.CLTools_Executables
package-id: com.apple.pkg.CLTools_Executables
version: 9.2.0.0.1.1510905681
volume: /
location: /
install-time: 1514035707
groups: com.apple.FindSystemFiles.pkg-group
}}}
----
On Lion and Mountain Lion, it's:
{{{
pkgutil --pkg-info=com.apple.pkg.DeveloperToolsCLI
}}}
e.g.:
{{{
$ pkgutil --pkg-info=com.apple.pkg.DeveloperToolsCLI
package-id: com.apple.pkg.DeveloperToolsCLI
version: 5.1.0.0.1.1396320587
volume: /
location: /
install-time: 1467560350
}}}
----
On Leopard and Snow Leopard, it appears to be:
{{{
pkgutil --pkg-info=com.apple.pkg.DeveloperToolsCLILeo
}}}
e.g.:
{{{
$ pkgutil --pkg-info=com.apple.pkg.DeveloperToolsCLILeo
package-id: com.apple.pkg.DeveloperToolsCLILeo
version: 1.0.0.9000000000.1.1248867338
volume: /
location: /
install-time: 1470134505
}}}
----
I haven't checked Tiger.
--
Ticket URL: <https://trac.macports.org/ticket/56318>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list