LaravelにLaravel Passportを入れようとするとエラーになります。
$ composer require laravel/passport Using version ^10.1 for laravel/passport ./composer.json has been updated Running composer update laravel/passport Loading composer repositories with package information Updating dependencies Your requirements could not be resolved to an installable set of packages. Problem 1 - Root composer.json requires PHP extension ext-mysql_xdevapi * but it is missing from your system. Install or enable PHP's mysql_xdevapi extension. To enable extensions, verify that they are enabled in your .ini files: - /usr/local/etc/php/7.4/php.ini - /usr/local/etc/php/7.4/conf.d/ext-opcache.ini You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode. Installation failed, reverting ./composer.json and ./composer.lock to their original content.
そこで、mysql_xdevapiが入っていないのが問題なのかと思い、
pecl install mysql_xdevapi
を試し、インストールディレクトリをautodetectにして実行したところ
Point out boost library install dir [autodetect] : autodetect Point out protobuf library install dir [autodetect] : autodetect
最終的に
configure: error: protobuf not found, please install it in system, consider use of --with-protobuf or setting MYSQL_XDEVAPI_PROTOBUF_ROOT ERROR: `/private/tmp/pear/temp/mysql_xdevapi/configure --with-php-config=/usr/local/opt/php/bin/php-config --with-boost --with-protobuf' failed
とでて、インストールが完了しません。
昔はPassportをすんなりインストールできたのに、こんなことになったのははじめてです。
よろしくお願いいたします。