2016-06-21 8 views
2

と様々な問題私はPHPBrewとPHP 5.4をインストールしようとしているが、これらのエラーを持っています:PHPBrew - インストール

-> % phpbrew install 5.4.6 +default +apxs2 +mysql        
===> phpbrew will now build 5.4.6 
===> Loading and resolving variants... 
Checking distribution checksum... 
Checksum matched: c9aa0f4996d1b91ee9e45afcfaeb5d2e 
===> Distribution file was successfully extracted, skipping... 
Found existing Makefile, running make clean to ensure everything will be rebuilt. 
You can append --no-clean option after the install command if you don't want to rebuild. 
===> Running make clean: /usr/bin/make -C '/home/breq/.phpbrew/build/php-5.4.6' --quiet 'clean' 
===> Checking patches... 
Checking patch for replace apache php module name with custom version name 
0 changes patched. 
Found existing build.log, renaming it to /home/breq/.phpbrew/build/php-5.4.6/build.log.1466515643 
===> Configuring 5.4.6... 


Use tail command to see what's going on: 
    $ tail -F /home/breq/.phpbrew/build/php-5.4.6/build.log 


===> Checking patches... 
Checking patch for php5.3.29 multi-sapi patch. 
Checking patch for php5.3.x on 64bit machine when intl is enabled. 
Checking patch for openssl dso linking patch 
===> Building... 
Error: Make failed: 
The last 5 lines in the log file: 
/home/breq/.phpbrew/build/php-5.4.6/ext/openssl/xp_ssl.c:355: undefined reference to `SSLv3_server_method' 

/home/breq/.phpbrew/build/php-5.4.6/ext/openssl/xp_ssl.c:343: undefined reference to `SSLv3_client_method' 

collect2: error: ld returned 1 exit status 

Makefile:244: recipe for target 'sapi/cli/php' failed 

make: *** [sapi/cli/php] Error 1 

Please checkout the build log file for more details: 
    tail /home/breq/.phpbrew/build/php-5.4.6/build.log 

+openssl

-> % phpbrew install 5.4.6 +default +apxs2 +mysql +openssl=/usr/include/openssl 
===> phpbrew will now build 5.4.6 
===> Loading and resolving variants... 
Checking distribution checksum... 
Checksum matched: c9aa0f4996d1b91ee9e45afcfaeb5d2e 
===> Distribution file was successfully extracted, skipping... 
Found existing Makefile, running make clean to ensure everything will be rebuilt. 
You can append --no-clean option after the install command if you don't want to rebuild. 
===> Running make clean: /usr/bin/make -C '/home/breq/.phpbrew/build/php-5.4.6' --quiet 'clean' 
===> Checking patches... 
Checking patch for replace apache php module name with custom version name 
0 changes patched. 
Found existing build.log, renaming it to /home/breq/.phpbrew/build/php-5.4.6/build.log.1466516015 
===> Configuring 5.4.6... 


Use tail command to see what's going on: 
    $ tail -F /home/breq/.phpbrew/build/php-5.4.6/build.log 


Error: Configure failed: 
The last 5 lines in the log file: 
checking for Kerberos support... no 

checking for DSA_get_default_method in -lssl... no 

checking for X509_free in -lcrypto... yes 

checking for pkg-config... /usr/bin/pkg-config 

configure: error: Cannot find OpenSSL's <evp.h> 

Please checkout the build log file for more details: 
    tail /home/breq/.phpbrew/build/php-5.4.6/build.log 

と私のOS:+ PHP 7.07Xubuntu 16.10

-> % tail /home/lmalicki/.phpbrew/build/php-5.4.6/build.log 
checking whether to enable LIBXML support... yes 
checking libxml2 install dir... /usr 
checking for xml2-config path... /usr/bin/xml2-config 
checking whether libxml build works... yes 
checking for OpenSSL support... yes 
checking for Kerberos support... no 
checking for DSA_get_default_method in -lssl... no 
checking for X509_free in -lcrypto... yes 
checking for pkg-config... /usr/bin/pkg-config 
configure: error: Cannot find OpenSSL's <evp.h> 

答えて

0

私はいくつかの依存関係が欠けているようです。

最初のSSL devパッケージをインストールして試してみてください:

apt-get install libssl-dev 

PHPBrewだけダウンロードしてPHPをコンパイルしますが、それはあなたのOSで必要なの依存性をインストールしません。

EDIT:

私はちょうどあなたが+openssl=/usr/include/opensslにOpenSSLライブラリのパスを提供してきましたことに気付きました。

本当にありますか?これはwhich opensslで確認できます。このコマンドは、opensslバイナリのパスを返します。

また、PHPBrewが独自のバイナリを見つけられるため、パスを削除することもできます。

+0

- >%はsudoのlibssl-devの 読み込みパッケージ一覧をインストールapt-getを...の状態情報を読み取る ビルの依存関係ツリー を完了... を完了libssl-devはすでに最新バージョン(1.0.2h-1 + deb.sury.org〜xenial + 1)です。 アップグレード済み、0は新しくインストール済み、0は削除済み、40はアップグレードされていません。 – breq

+0

最新の回答をご覧ください。この溶液を用いて –

0

+のopensslのディレクティブは、実際のパスが含まれていないプレフィックスを提供しているので、あなたのディストリビューションが提供する、あなたは、OpenSSLの新しいバージョンを持っている場合、この問題が発生する可能性があり

+openssl=/usr -- --with-libdir=lib64 
+0

私が持っている:Kerberosサポートのチェック...いや が-lsslにDSA_get_default_methodをチェック...いや はPKG-config設定をチェック-lcrypto ...はい にX509_freeをチェック../usr/bin/pkg-config configure:エラー:OpenSSLのライブラリが見つかりません – breq

+0

configureコマンドを含む最後の10行だけでなく、ビルドログ全体を貼り付けることができますか? – canto

0
configure: error: Cannot find OpenSSL's <evp.h> 

インストールさしてみてください。

ubuntuを使用している場合は、パッケージを元に戻す必要があります。

#file etc/apt/preferences.d/allow-downgrade 

Package: * 
Pin: release o=Ubuntu 
Pin-Priority: 1001 

その後、

sudo apt-get update 
sudo apt-get upgrade 

とオプション

-- --with-openssl=/path/to/libs 

または

+openssl 

(おそらくあなたが理由で異なるバージョンがインストールされているので、ここで注意してください)すべきですうまく動作します。

すでにPHPbrewからインストールいくつかのmisfunctioningのPHPは、Ubuntuの16日

phpbrew switch recently_installed_php_ver_number_here 
0

に切り替えることを忘れないでくださいしている場合。10

sudo apt-get install libssl-dev 
sudo apt-get install libcurl4-openssl-dev 
sudo apt-get install clibcurl4-openssl-dev pkg-config libssl-dev libsslcommon2-dev 

その後、再実行

phpbrew install 5.4.6 +default +apxs2 +mysql +openssl=/usr/include/openssl 
関連する問題