I have installed ngnix on mac from source using below commands.
cd pcre-8.40
/configure --prefix=/Users/nginx/
make && make install && make clean
cd ..
cd ngnix-1.10.3
/configure --prefix=/Users/nginx/ --with-pcre=../pcre-8.40 --with-http_ssl_module
make && make install && make clean
nginx works fine when i run it from the installed machine.
Now, I have copied nginx folder from /Users/nginx/ on another mac machine.
It is throwing the following error when I run sudo ./nginx.
dyld: Library not loaded: /opt/local/lib/libssl.1.0.0.dylib
Referenced from: Users/nginx/sbin/./nginx
Reason: no suitable image found.
Tried many ways but no luck. Any idea on how to achieve this.