mac編譯安裝php7遇到問題,錯誤
我的編譯參數為:/usr/local/php7 --with-apxs2=/usr/sbin/apxs --with-mysqli --with-pdo-mysql --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --enable-mbregex --enable-mbstring --with-mcrypt --enable-ftp --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --disable-fileinfo --enable-maintainer-zts
這個問題該怎麼解決呢?
回複內容:
mac編譯安裝php7遇到問題,錯誤
我的編譯參數為:/usr/local/php7 --with-apxs2=/usr/sbin/apxs --with-mysqli --with-pdo-mysql --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir --enable-xml --disable-rpath --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --enable-mbregex --enable-mbstring --with-mcrypt --enable-ftp --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --disable-fileinfo --enable-maintainer-zts
這個問題該怎麼解決呢?
檢查openssl的相關依賴是否裝了,如果你是brew額外裝了新版本的openssl,記得指向那個路徑 '--with-openssl=/usr/local/opt/openssl'
如果1檢查無誤,在編譯前make clean,並進行一次./buildconf --force
1樓的方法沒效果
自己編譯恐怕是要折騰些許時日,如果非必須,在mac下,大可以brew install。
header和lib版本不匹配