Ticket #14615 (closed defect: fixed)
select.sh tools (python_select, gcc_select) should remember selected versions across upgrade
| Reported by: | macports_dharland@… | Owned by: | macports-tickets@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 1.6.0 |
| Keywords: | Cc: | raimue@…, macports_dharland@…, mww@…, blb@… | |
| Port: |
Description
Suppose that a user has installed python_select and used as follows
python_select python24
Currently, an upgrade to python_select will result in the users setting being forgotten. In fact since the post-destroot for python_select explicitly chooses python23-apple, /opt/local/bin/python will now point to a different executable/version than before the upgrade.
This isn't great and can cause python programs to crash for reasons that aren't that obvious to the user.
A suggested solution is for $TOOL_select to also write a symlink pointing to the selected option such as
/opt/local/etc/selected/python->/opt/local/etc/select/python/python24
Then upon activation $TOOL_select can be run passing the users previously selected version.
In addition a -s option could be provided to $TOOL_select to report the currently selected version.


