This was the command line I had to use to get it to install. It was trying to link against a more modern version of OpenSSL otherwise that did not work.
CFLAGS=-Wno-implicit-function-declaration CPPFLAGS="-I$(brew --prefix [email protected])/include -I$(xcrun --show-sdk-path)/usr/include" LDFLAGS="-L$(brew --prefix [email protected])/lib -Wno-implicit-function-declaration" pyenv install 3.6.15