diff --git a/docs/extension-maintainers.md b/docs/extension-maintainers.md index e9f4e94f..eaa9d8e6 100644 --- a/docs/extension-maintainers.md +++ b/docs/extension-maintainers.md @@ -395,6 +395,7 @@ is NOT working, then please [report a bug](https://github.com/php/pie/issues). | lib-freetype2 | ✅ | ❌ | | lib-gdlib | ✅ | ❌ | | lib-gmp | ✅ | ❌ | +| lib-gpgme | ✅ | apt, apk, dnf, yum | | lib-sasl | ✅ | ❌ | | lib-onig | ✅ | ❌ | | lib-odbc | ✅ | ❌ | diff --git a/src/ComposerIntegration/PhpBinaryPathBasedPlatformRepository.php b/src/ComposerIntegration/PhpBinaryPathBasedPlatformRepository.php index 8729a807..293df0b3 100644 --- a/src/ComposerIntegration/PhpBinaryPathBasedPlatformRepository.php +++ b/src/ComposerIntegration/PhpBinaryPathBasedPlatformRepository.php @@ -171,6 +171,7 @@ private function addLibrariesUsingPkgConfig(): void $this->detectLibraryWithPkgConfig('freetype2', 'freetype2'); $this->detectLibraryWithPkgConfig('gdlib', 'gdlib'); $this->detectLibraryWithPkgConfig('gmp', 'gmp'); + $this->detectLibraryWithPkgConfig('gpgme', 'gpgme'); $this->detectLibraryWithPkgConfig('sasl', 'libsasl2'); $this->detectLibraryWithPkgConfig('onig', 'oniguruma'); $this->detectLibraryWithPkgConfig('odbc', 'libiodbc'); diff --git a/src/DependencyResolver/DependencyInstaller/SystemDependenciesDefinition.php b/src/DependencyResolver/DependencyInstaller/SystemDependenciesDefinition.php index 7ea90bff..53808ab1 100644 --- a/src/DependencyResolver/DependencyInstaller/SystemDependenciesDefinition.php +++ b/src/DependencyResolver/DependencyInstaller/SystemDependenciesDefinition.php @@ -62,6 +62,13 @@ public static function default(): self PackageManager::Microdnf->value => 'pkgconfig(libcurl)', PackageManager::Yum->value => 'pkgconfig(libcurl)', ], + 'gpgme' => [ + PackageManager::Apt->value => 'libgpgme-dev', + PackageManager::Apk->value => 'gpgme-dev', + PackageManager::Dnf->value => 'pkgconfig(gpgme)', + PackageManager::Microdnf->value => 'pkgconfig(gpgme)', + PackageManager::Yum->value => 'pkgconfig(gpgme)', + ], ]); } } diff --git a/test/unit/ComposerIntegration/PhpBinaryPathBasedPlatformRepositoryTest.php b/test/unit/ComposerIntegration/PhpBinaryPathBasedPlatformRepositoryTest.php index ca1b5d4b..9aef2094 100644 --- a/test/unit/ComposerIntegration/PhpBinaryPathBasedPlatformRepositoryTest.php +++ b/test/unit/ComposerIntegration/PhpBinaryPathBasedPlatformRepositoryTest.php @@ -176,6 +176,7 @@ public static function installedLibraries(): array ['freetype2', 'freetype2'], ['gdlib', 'gdlib'], ['gmp', 'gmp'], + ['gpgme', 'gpgme'], ['sasl', 'libsasl2'], ['onig', 'oniguruma'], ['odbc', 'libiodbc'],