build: fix ldconfig executable error in python