Question

I'm trying to run a program on a remote system on which I can't set environment variables (no access to export). The problem I'm having is I can't set LD_LIBRARY_PATH to run my binary because I don't have (and can't get) permission.

I need a quick fix for this so I can run and test the application, I was wondering if there are any flags I can set when executing that will have the same effect - ie ./test -LD_LIBRARY_PATH="path-to-lib"

Looked around on the net and can't find anything =( help would be greatly appreciated.

Was it helpful?

Solution

In bash, you can prepend executable with environment settings: LD_LIBRARY_PATH="path-to-lib" ./test

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top