We deploy our application with all the necessary dependencies in one directory. Our application sets LD_LIBRARY_PATH to this location. Some of the libraries (for instance OpenSSL) are also present at system locations. And indeed when we remove such a shared object from the application directory the application still runs with all possible disasters (like wrong version). I would rather have a warning issued that the shared object cannot be found if I remove it from the application directory
Is it possible to reset the search path of the dynamic loader such that indeed it only looks in the LD_LIBRARY_PATH for certain objects?