andy@AndyMacBookPro:/usr/lib/php/extensions/no-debug-non-zts-20100525$ ll
total 2256
drwxr-xr-x 10 root wheel 340 2 19 23:09 ./
drwxr-xr-x 3 root wheel 102 1 20 2014 ../
-rwxr-xr-x 1 root wheel 10496 2 6 14:58 andy.so*
-rwxr-xr-x 1 root wheel 172732 7 23 2014 apc.so*
-rwxr-xr-x 1 root wheel 51424 7 1 2014 mssql.so*
-rwxr-xr-x 1 root wheel 26928 2 13 15:11 pcntl.so*
-rwxr-xr-x 1 root wheel 30084 7 2 2014 pdo_odbc.so*
-rwxr-xr-x 1 root wheel 255656 6 23 2014 redis.so*
-rwxr-xr-x 1 root wheel 388312 2 19 23:09 swoole.so*
-rwxr-xr-x 1 root wheel 200880 9 22 09:37 xdebug.so*
andy@AndyMacBookPro:/usr/lib/php/extensions/no-debug-non-zts-20100525$
可以看到这里已经有很多之前安装的扩展了,然后我们接下来只要把这一句添加进我们本地的php.ini文件就好了:
复制代码 代码如下:
extension = swoole.so
如果不知道本机的php.ini在哪里,可以这样找:
复制代码 代码如下: