According to what I had written in earlier postings, I had co-installed a Debian Jessie / Security version of the GCC / CPP / C++ compiler system, which had version 4.9.2, alongside the official versions, which were 6.3, on the Debian / Stretch computer I name ‘Phosphene’. There was a problem in how I had done that. If next, the Package Maintainers had pushed through an update to their official compiler, the update would have broken my link groups – in a devastating way. And so what I needed to do was to rearrange those link-groups, to make them compatible with this scenario. The result is as follows:
dirk@Phosphene:~$ su
Password:
root@Phosphene:/home/dirk# update-alternatives --config cc
There are 2 choices for the alternative cc (providing /usr/bin/cc).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/gcc 20 auto mode
1 /usr/bin/gcc 20 manual mode
2 /usr/bin/gcc-4.9 10 manual mode
Press to keep the current choice[*], or type selection number:
root@Phosphene:/home/dirk# update-alternatives --config cpp
There are 2 choices for the alternative cpp (providing /lib/cpp).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/cpp 20 auto mode
1 /usr/bin/cpp 20 manual mode
2 /usr/bin/cpp-4.9 10 manual mode
Press to keep the current choice[*], or type selection number:
root@Phosphene:/home/dirk# update-alternatives --config c++
There are 2 choices for the alternative c++ (providing /usr/bin/c++).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/g++ 20 auto mode
1 /usr/bin/g++ 20 manual mode
2 /usr/bin/g++-4.9 10 manual mode
Press to keep the current choice[*], or type selection number:
root@Phosphene:/home/dirk# ls -l /usr/bin/gcc
lrwxrwxrwx 1 root root 5 May 3 10:58 /usr/bin/gcc -> gcc-6
root@Phosphene:/home/dirk# ls -l /usr/bin/cpp
lrwxrwxrwx 1 root root 5 May 3 11:01 /usr/bin/cpp -> cpp-6
root@Phosphene:/home/dirk# ls -l /usr/bin/g++
lrwxrwxrwx 1 root root 5 May 3 11:24 /usr/bin/g++ -> g++-6
root@Phosphene:/home/dirk# exit
exit
dirk@Phosphene:~$
Dirk Mittler
One thought on “My system for switching between compilers needed an overhaul.”