For each PHP version, we have formulae with thread-safety support (zts) and debug symbols support (debug) and both (debug-zts) as well. The formulae with debug symbols can be used when building or debugging PHP extensions and are not recommended for production usage. The formulae with thread-safety support can be used with applications that require multi-threading support.

https://github.com/shivammathur/homebrew-php