Make it simple!
xcode-select --install brew update brew install httpd brew install --with-httpd php71 apachectl start which httpd brew -v php -v apachectl -v