notes icon indicating copy to clipboard operation
notes copied to clipboard

phpbrew install extension with custom options

Open lanlin opened this issue 3 years ago • 0 comments

举例扩展名

event

查看扩展可选配置项

~ phpbrew ext show event

                Name: event
    Source Directory: /Users/lanlin/.phpbrew/build/php-8.1.2/ext/event
              Config: /Users/lanlin/.phpbrew/build/php-8.1.2/ext/event/config.m4
            INI File: /Users/lanlin/.phpbrew/php/php-8.1.2/var/db/event.ini
           Extension: Pecl
                Zend: no
              Loaded: yes

   Configure Options:

        --enable-event-debug[=no]        Enable internal debugging in Event

        --enable-event-sockets[=yes]     Enable sockets support in Event

        --with-event-libevent-dir[=/usr] libevent installation prefix

        --with-event-pthreads[=no]       Include libevent's pthreads library and enable thread safety support in Event

        --with-event-extra[=yes]         Include libevent protocol-specific functionality support including HTTP, DNS, and RPC

        --with-event-openssl[=yes]       Include libevent OpenSSL support

        --with-event-ns[=no]             PHP Namespace for all Event classes

开始安装扩展

~ phpbrew ext install event -- \
--enable-event-debug=no \
--enable-event-sockets=yes \
--with-event-libevent-dir=/usr \
--with-event-pthreads=no \
--with-event-extra=yes \
--with-event-openssl=no \
--with-event-ns=yes \
--with-openssl-dir=no

注意: phpbrew ext install event -- 最后的 -- 并不是写错了

lanlin avatar Jan 25 '22 12:01 lanlin