After playing around with manually installed boost versions to meet software dependencies, I did something stupid: I deleted by system boost libraries (the .so files) from /usr/lib/x86_64-linux.gnu/ . I have tried to remove and reinstall the libboost-all-dev package. I did not get error essages, but the library files were not restored. I have downloaded all the .deb files and installed them manually with dpkg, without success. How can I repair my system and recover the files?
2 Answers
You should check which Boost-related packages do you have installed.
For example with dpkg -l | grep boost
and then reinstall all of them with
sudo apt-get install --reinstall \
$(dpkg -l | grep ^ii.*boost | awk '{print $2}')
-
1@Norbert Thank you so much, this one worked for me! You really saved my day!– tglasJul 7, 2018 at 16:15
Try to reinstall the package libboost-all-dev
along with its dependencies. You can find packages which libboost-all-dev
depends on using the following command in terminal
sudo apt-cache depends libboost-all-dev
Then reinstall all of them
sudo apt install --reinstall libboost-all-dev <list_of_dependencies>
Or use two all-in-one commands (try both of them):
sudo apt-cache depends libboost-all-dev | grep '[ |](Depends): [^:]' | cut -d: -f2 | tr -d ' ' | xargs sudo apt --reinstall install -y
and
sudo apt-cache depends libboost-all-dev | grep '[ |]Depends: [^:]' | cut -d: -f2 | tr -d ' ' | xargs sudo apt --reinstall install -y
-
Thanks for the quick reply. This is pretty much along the lines of what I tried already. I got the list, the command apparently did something, but the files are not restored. Any idea how to debug this situation?– tglasJul 7, 2018 at 8:23
-
Thanks, I tried both. The first did nothing, the second one did essentially the same as my attempt with the manually compiled dependency list - it loaded some stuff, but the libs did not come back. I worked around the problem in the meantime by compiling boost manually, putting the files in place, and creating a ton of symlinks by hand. However, I'd still like to understand what goes wrong...– tglasJul 7, 2018 at 9:05
apt --reinstall install
does not solve my problem.