adding provide to php composer.json (#13141)

Adding composer config to allow the native protobuf extension to provide ext-protobuf.

This allows libraries to require at least one protobuf implementation. If the extension is not available, it can be provided by the native package. If the extension is available but the native package is required, the native will be installed.

Importantly, for libraries which require at least one of them to be installed, composer will complain if neither is available.

Closes #13141

COPYBARA_INTEGRATE_REVIEW=https://github.com/protocolbuffers/protobuf/pull/13141 from brettmc:php-provides-ext 72d3e447f3
PiperOrigin-RevId: 546312826
pull/13241/head
Brett McBride 1 year ago committed by Copybara-Service
parent 5db61db331
commit d603b4199e
  1. 3
      php/composer.json

@ -8,6 +8,9 @@
"require": {
"php": ">=8.0.0"
},
"provide": {
"ext-protobuf": "*"
},
"require-dev": {
"phpunit/phpunit": ">=5.0.0 <8.5.27"
},

Loading…
Cancel
Save