[MacPorts] #60566: Setting known_fail yes should prevent the port from being installed
MacPorts
noreply at macports.org
Thu May 28 04:17:49 UTC 2020
#60566: Setting known_fail yes should prevent the port from being installed
-------------------------+-----------------------------
Reporter: ryandesign | Owner: (none)
Type: enhancement | Status: new
Priority: Normal | Milestone: MacPorts Future
Component: base | Version: 2.6.2
Keywords: | Port:
-------------------------+-----------------------------
Some ports do this (this is from go):
{{{
if {${os.platform} eq "darwin" && ${os.major} < 11} {
known_fail yes
pre-fetch {
ui_error "${name} @${version} requires OS X 10.7 or greater."
return -code error "incompatible Mac OS X version"
}
}
}}}
In other words in addition to setting `known_fail yes` it prints an error
message in a `pre-fetch` block to prevent the port from being installed.
It would be great if MacPorts base itself would ensure that the port
cannot be installed when `known_fail yes` is set.
Ports still need an opportunity to specify a reason why they would fail.
Maybe a new option could be created for that, so that a portfile could
then say:
{{{
# hypothetical code
if {${os.platform} eq "darwin" && ${os.major} < 11} {
known_fail yes
known_fail_reason requires OS X 10.7 or greater
}
}}}
Maybe implementing this would make other smaller enhancements to
`known_fail yes` like #60564 and #60565 unnecessary.
--
Ticket URL: <https://trac.macports.org/ticket/60566>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list