[CMAKE] Fix split debug not working for libs on Debian
Summary:
By default cmake will install all the shared libs with the executable
bit set as it is the default from the linker, but Debian has a special
policy to no set this bit. As a consequence cmake special cased the way
the shared libs permissions are set during installation on Debian only
and remove the executable bit unless some flag is set to overwrite this
feature.
As a consequence the script checking for executable files for splitting
the debug info out of the binary will miss the shared libs on Debian.
This diff changes to behavior by supplying the bin and lib install
directories so the script no longer needs to guess what to strip.
Test Plan:
On Debian:
ninja install-bitcoind-debug
Check the libbitcoinconsensus.so is stripped and has split debug info.
Reviewers: #bitcoin_abc, deadalnix
Reviewed By: #bitcoin_abc, deadalnix
Subscribers: deadalnix
Differential Revision: https://reviews.bitcoinabc.org/D7242