You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cd~
mkdir tmp &&cd tmp
git clone https://github.com/phpv8/v8js
cd v8js
phpize
./configure CXXFLAGS="-Wno-c++11-narrowing"
make
make test#if this step fails you can try to install anyway. should work.
make install
如果在 make install 步驟跳出 operation not permitted 錯誤的話
需要按這篇文章來解除封鎖
如果遇到 'php.h' file not found 的錯誤, 需要重新安裝 common line tool 和 SDK
安裝 brew (有裝過 brew 可以跳過此步驟)
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
安裝 v8
安裝 v8js
安裝 PECL
參考此篇文章
從 github 下載 v8js 安裝包並安裝
如果在 make install 步驟跳出
operation not permitted
錯誤的話需要按這篇文章來解除封鎖
如果遇到
'php.h' file not found
的錯誤, 需要重新安裝 common line tool 和 SDK安裝成功之後 在 php.ini
(/etc/php.ini)
裡面加入內容重新啟動 Apache
之後可以輸入以下指令確認 v8js 是否安裝成功
php -i | grep v8js
或是直接開啟 phpinfo 看看有沒有 v8js 擴充套件的資訊
參考
1
The text was updated successfully, but these errors were encountered: