Im trying to link my program to the shared library. Im using a makefile to compile. It looks like this: `

```
make: sms_out.cpp SMSDispatch.cpp SMSDispatch.h
      g++ -c -fPIC SMSDispatch.cpp -o SMSDispatch.o
      g++ -shared SMSDispatch.o -o libSMSDispatch.so
`     g++ sms_out.cpp -L. -lSMSDispatch -o sms_out

```

It works fine if I run the program in the command window with:

```
LD_LIBRARY_PATH="." ./sms_out

```

But I want to run it with just `./sms_out`, can someone help me?
Tried to add `export LD_LIBRARY_PATH=.` to the makefile, but that didnt work, just got the error " error while loading shared libraries: libSMSDispatch.so: cannot open shared object file: No such file or directory" when I try to run the program.