Skip to content

Installation error: mautic/core-lib 7.0.0 requires ext-imap #153

@derwaldgeist

Description

@derwaldgeist

As a PHP noob, I'm following the instructions to install Mautic using composer on my Mac M3.

However, running the composer install results in an error message (see below). I think for noobs like me, it would be worth mentioning that this "imap" extension is needed and how to install it (I looked in php.ini, but couldn't find anything about it there).

It's a bit frustrating to run into an error that quick.

After some research I saw that the library is not bundled with PHP anymore since PHP 8.4. Maybe that's why.

Digging deeper, the imap plugin tells me that I should use a PECL repository, which then tells me to use PIE instead. Pretty tough for a noob to understand all of this PHP-specific stuff, tbh.

And then I stumbled upon this:
https://php.watch/versions/8.4/imap-unbundled
which tells me that this library should better not be used. Hm.

When trying to install this extension, I landed on the PECL package's homepage, which only includes instructions for Debian or Ubuntu. So I'm quite stuck right now.

Creating a "mautic/recommended-project:^7.0" project at "./"
Installing mautic/recommended-project (7.0.0)
  - Downloading mautic/recommended-project (7.0.0)
  - Installing mautic/recommended-project (7.0.0): Extracting archive
Created project in /Users/tom/dev/marble/tests/mautic/.
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 mautic/core-lib 7.0.0 -> satisfiable by mautic/core-lib[7.0.0].
    - mautic/core-lib 7.0.0 requires ext-imap * -> it is missing from your system. Install or enable PHP's imap extension.
  Problem 2
    - Root composer.json requires mautic/theme-welcome 7.0.0 -> satisfiable by mautic/theme-welcome[7.0.0].
    - mautic/core-lib 7.0.0 requires ext-imap * -> it is missing from your system. Install or enable PHP's imap extension.
    - mautic/theme-welcome 7.0.0 requires mautic/core-lib ^7.0 -> satisfiable by mautic/core-lib[7.0.0].

To enable extensions, verify that they are enabled in your .ini files:
    - /opt/homebrew/etc/php/8.5/php.ini
You can also run `php --ini` in a terminal to see which files are used by PHP in CLI mode.
Alternatively, you can run Composer with `--ignore-platform-req=ext-imap` to temporarily ignore these required extensions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions