diff --git a/src/DependencyResolver/ResolveDependencyWithComposer.php b/src/DependencyResolver/ResolveDependencyWithComposer.php index 74082b71..a2d9ec31 100644 --- a/src/DependencyResolver/ResolveDependencyWithComposer.php +++ b/src/DependencyResolver/ResolveDependencyWithComposer.php @@ -142,6 +142,15 @@ private function assertBuildProviderProvidersBundledExtensions(TargetPlatform $t )); } + if ($buildProvider === 'Homebrew') { + $identifiedBuildProvider = true; + $this->io->write(sprintf( + '%sThe bundled extension %s is likely already installed with Homebrew, and you should use that version.', + $note, + $piePackage->extensionName()->name(), + )); + } + if ($identifiedBuildProvider && ! $forceInstallPackageVersion) { throw BundledPhpExtensionRefusal::forPackage($piePackage); } diff --git a/test/end-to-end/Dockerfile b/test/end-to-end/Dockerfile index 627c53b7..50b3a374 100644 --- a/test/end-to-end/Dockerfile +++ b/test/end-to-end/Dockerfile @@ -26,9 +26,8 @@ FROM homebrew/brew AS test_pie_installs_build_tools_with_brew RUN brew install php COPY --from=build_pie_phar /app/pie.phar /usr/local/bin/pie USER root -RUN apt-get update && apt-get install -y unzip libbz2-dev +RUN apt-get update && apt-get install -y unzip RUN apt-get remove --allow-remove-essential -y apt USER linuxbrew -RUN brew install bzip2 -RUN pie install --auto-install-build-tools -v php/bz2 +RUN pie install --auto-install-build-tools -v asgrim/example-pie-extension RUN pie show