[solved] polybar misses libjsoncpp.so.21

Hi there, after the last pacman -Syu polybar didn’t want to start anymore.

So I tried to start polybar from a terminal, which yielded:

polybar: error while loading shared libraries: libjsoncpp.so.21: cannot open shared object file: No such file or directory

Did some investigation with google.com and then digged around as root:

sudo su
pacman -Qi jsoncpp
[…] libjsoncpp.so=22-64 […]
updatedb
locate jsoncpp
cd /usr/lib/
ls -al libjsoncpp.*
[…] .a .so .so.22 […]

Tried a workaround like this.

ln -s libjsoncpp.so.22 libjsoncpp.so.21

Workaround works. Sharing workaround. Stay home. Stay safe.

Thx for sharing @anon39737049 . Might help other members in the forum.

As this will inevitably break once jsoncpp is updated again the thing to do would be

baph -inN polybar
1 Like

It looks like a Slackware procedure, I just reinstalled polybar so jsoncpp could be rebuild. Your tip is fine but as @natemaia said you will have to manually do so every time an update comes.

1 Like

Used natemaia’s solution and seems to be fine with no other fixes required

So far I have used the AUR just for selective cases only and looked into .SRCINFO and PKGBUILD carefully each time.

However “polybar” very probably is part of the archlabs_repo, but I can’t “reach” it with

pacman -S polybar

I remember having issues with polybar before, grepped through my history, but can’t find how I fixed things without an AUR-Helper.

edit: can’t even find the post (something like “hold on before updating polybar”) I made in this forum half a year or so

I believe I reinstalled polybar from the AUR the last time it made trouble.

The package is called archlabs-polybar and it is still in the repo but hasn’t been updated in a long time and will be removed soon leaving no other option but the AUR or manual install.

2 Likes

Sorry to hear that.

I wouldn’t be, polybar has been a PITA to configure across various WM, and helping users that have no interest in reading their wiki (which is really quite good) change things. Not to mention it constantly needing to be rebuilt because jsoncpp got a minor version bump. Things have been much better (for me) since dropping it.

Hi everyone in old distro archlabs I still have
archlabs-polybar.
Not to remove archlabs-polybar
I used this approach, I don’t know if it is very orthodox I went to:
/ usr / lib and I saved this libjsoncpp.so.21 file to my home
I have updated jsoncpp.
Then I copied the libjsoncpp.so.21 file to / usr / lib and everything works.
what do you say is a bad idea ?!
Cheers

yes, eventually that package will be gone.

Are you still using a bar and if yes, which?

I was mainly speaking as the person doing 90% of the AL configs but to answer your question, no not for a couple years now, not that I think bars are pointless or wasteful but in my case I found I was less distracted and less things to configure. It really depends on your use case, preferences, and how well it integrates with the WM.

For the record I do still think polybar is one of the better bars for tiling window managers, it’s just geared towards intermediate-advanced users and not really suitable for AL’s use case.

1 Like

Polybar isn’t in the Arch official repo… so pacman wont install it.

I don’t think so.