Resolving the ´ld: library not found for -lssl error when installing mysqlclient from pip

I want to share just a note on this error.

On macOS Mojave i keep getting the error ld: library not found for -lssl when installing mysqlclient from pip. I get this error both on python2 and python3.

The solution i found that works for me is:

Note: updating mysqlclient seems to solve the problem too.