質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
PHP

PHPは、Webサイト構築に特化して開発されたプログラミング言語です。大きな特徴のひとつは、HTMLに直接プログラムを埋め込むことができるという点です。PHPを用いることで、HTMLを動的コンテンツとして出力できます。HTMLがそのままブラウザに表示されるのに対し、PHPプログラムはサーバ側で実行された結果がブラウザに表示されるため、PHPスクリプトは「サーバサイドスクリプト」と呼ばれています。

Q&A

0回答

1829閲覧

PHP_BUILD_INSTALL_EXTENSIONでライブラリをインストールした際にエラーが発生します。

marshmallowy

総合スコア204

PHP

PHPは、Webサイト構築に特化して開発されたプログラミング言語です。大きな特徴のひとつは、HTMLに直接プログラムを埋め込むことができるという点です。PHPを用いることで、HTMLを動的コンテンツとして出力できます。HTMLがそのままブラウザに表示されるのに対し、PHPプログラムはサーバ側で実行された結果がブラウザに表示されるため、PHPスクリプトは「サーバサイドスクリプト」と呼ばれています。

0グッド

0クリップ

投稿2016/11/14 08:52

###前提・実現したいこと
お世話になっております。

PHPで複数のバージョンを共存させたく、"PHPENV" と "PHP-BUILD" を利用し、環境を構築しました。
その後、APCUをインストールしたのですが、エラーが出力されます。

よろしければ、ご教授のほど、よろしくお願いいたします。

また、.phpenv/plugins/php-build/share/php-build/extension 配下にある "definition" には、以下の記述がされてます。

###該当のソースコード

"name","url-dist","url_source","source_cwd","configure_args","extension_type","after_install" "apc","http://pecl.php.net/get/APC-$version.tgz","git@git.php.net:/pecl/caching/apc.git",,"--enable-apc","extension", "apcu","http://pecl.php.net/get/apcu-$version.tgz","https://github.com/krakjoe/apcu.git",,,"extension", "igbinary","http://pecl.php.net/get/igbinary-$version.tgz","https://github.com/igbinary/igbinary.git",,,"extension", "imagick","http://pecl.php.net/get/imagick-$version.tgz","https://github.com/mkoppanen/imagick.git",,,"extension", "memcache","http://pecl.php.net/get/memcache-$version.tgz","git@git.php.net:/pecl/caching/memcache.git",,,"extension", "memcached","http://pecl.php.net/get/memcached-$version.tgz","https://github.com/php-memcached-dev/php-memcached.git",,"--disable-memcached-sasl","extension", "uprofiler",,"https://github.com/FriendsOfPHP/uprofiler.git","extension",,"extension","uprofiler_after_install" "xcache","http://xcache.lighttpd.net/pub/Releases/$version/xcache-$version.tar.gz",,,"--enable-xcache","extension", "xdebug","http://xdebug.org/files/xdebug-$version.tgz","git://github.com/xdebug/xdebug.git",,"--enable-xdebug","zend_extension","xdebug_after_install" "xhprof","http://pecl.php.net/get/xhprof-$version.tgz","git://github.com/facebook/xhprof.git",,,"extension","xhprof_after_install"

###該当のソースコード

[user@host ~]$ sudo PHP_BUILD_INSTALL_EXTENSION='apcu=@' phpenv install 5.6.27

###発生している問題・エラーメッセージ

[Info]: Loaded extension plugin [Info]: Loaded apc Plugin. [Info]: Loaded composer Plugin. [Info]: Loaded github Plugin. [Info]: Loaded uprofiler Plugin. [Info]: Loaded xdebug Plugin. [Info]: Loaded xhprof Plugin. [Info]: php.ini-production gets used as php.ini [Info]: Building 5.6.27 into /home/hironobu/.phpenv/versions/5.6.27 [Skipping]: Already downloaded and extracted https://secure.php.net/distributions/php-5.6.27.tar.bz2 [Preparing]: /tmp/php-build/source/5.6.27 [Compiling]: /tmp/php-build/source/5.6.27 [xdebug]: Installing version 2.4.1 [xdebug]: Compiling xdebug in /tmp/php-build/source/xdebug-2.4.1 [xdebug]: Cleaning up. [Info]: Enabling Opcache... [Info]: Done [apcu]: Installing from source [apcu]: Fetching from Git Master [apcu]: Compiling apcu in /tmp/php-build/source/apcu-master ----------------- | BUILD ERROR | ----------------- Here are the last 10 lines from the log: ----------------------------------------- /tmp/php-build/source/apcu-master/apc.c:336: error: too few arguments to function ‘zend_hash_get_current_data_ex’ /tmp/php-build/source/apcu-master/apc.c:338:61: error: macro "zend_hash_update" requires 6 arguments, but only 3 given /tmp/php-build/source/apcu-master/apc.c:338: error: ‘zend_hash_update’ undeclared (first use in this function) /tmp/php-build/source/apcu-master/apc.c:338: error: (Each undeclared identifier is reported only once /tmp/php-build/source/apcu-master/apc.c:338: error: for each function it appears in.) /tmp/php-build/source/apcu-master/apc.c:340:68: error: macro "zend_hash_index_update" requires 5 arguments, but only 3 given /tmp/php-build/source/apcu-master/apc.c:340: error: ‘zend_hash_index_update’ undeclared (first use in this function) /tmp/php-build/source/apcu-master/apc.c:345: warning: passing argument 1 of ‘_zval_ptr_dtor’ from incompatible pointer type /home/hironobu/.phpenv/versions/5.6.27/include/php/Zend/zend_variables.h:51: note: expected ‘struct zval **’ but argument is of type ‘struct zval *’ make: *** [apc.lo] Error 1 ----------------------------------------- The full Log is available at '/tmp/php-build.5.6.27.20161114171520.log'. [Warn]: Aborting build.

###補足情報(言語/FW/ツール等のバージョンなど)
CentOS 6.8 Final
PHP 5.6.27

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

matsu

2016/11/14 16:20

/tmp/php-build.5.6.27.20161114171520.log を確認しましょう。ここにエラーの全てが入っているはずです。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだ回答がついていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問