最近在給用戶配置服務器的時候出現寶塔面板安裝php失敗:提示No package 'libjpeg' found的錯誤,折騰了一段時間終于找到解決辦法,分享給大家:
1、寶塔后臺打開消息盒子,點擊“執行日志”。這里面會有具體的錯誤提示,我這個的錯誤如下:
No package 'libjpeg' foundConsider adjusting the PKG_CONFIG_PATH environment variable if youinstalled software in a non-standard prefix.Alternatively, you may set the environment variables JPEG_CFLAGSand JPEG_LIBS to avoid the need to call pkg-config.See the pkg-config man page for more details.make: *** No targets specified and no makefile found. Stop.make: *** No rule to make target `install'. Stop.
弄去翻譯下,說的是找不到“libjpeg”這個包,目測是php7.4版本必須依賴這個包,但是安裝環境里面找不到這個包導致的錯誤。
2、解決辦法
ssh鏈接上服務器,輸入:“yum install libjpeg libjpeg-devel”,然后回車,提示你“[y/d/N]”的時候輸入“y”回車即可完成安裝libjpeg包,具體過程如下圖:
安裝完成后再去寶塔后臺安裝“php7.4”就是真的安裝完成了...
以上就是寶塔面板安裝php失敗:提示No package 'libjpeg' found的解決辦法的全部內容,希望對大家的學習和解決疑問有所幫助,也希望大家多多支持武林網。新聞熱點
疑難解答