Current Guidelines have explaination for PSR-0
A PSR-0  compliant library would put its PHP files in /usr/share/php/<vendor name="">
PSR-0 use a full tree which match class namespace, which is perfect for downstream.
But a lot of library start to switch to PSR-4. In this new standard, some top directories of the PSR-0 tree can be dropped from the sources tree. (A PSR-4 autoloader have to be aware of this dropped prefix).
PSR-4 have no sense for downstream distribution.
Proposal: restore a PSR-0 compliant tree to avoid any name conflict. Such an installation can be used from a PSR-0 or PSR-4 autoloader:
In both case Foo\Bar\Pop class is /usr/share/php/Foo/Bar/Pop.php
Proposed changes to PHP Guidelines
A PSR-4  compliant library would put its PHP files
in /usr/share/php/<vendor name=""> in a PSR-0 compliant tree.
With link to https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-4-autoloader.md
This change is mostly only to avoid ambiguity, some PHP packaged libraries already follow this (sometime, simply because upstream have switch from PSR-0 to PSR-4 in their sources repository)
We discussed this at this weeks meeting (http://meetbot.fedoraproject.org/fedora-meeting-1/2015-01-08/fpc.2015-01-08-17.01.txt), summary is:
I wrote this up during the meeting.
Added information to the PHP guidelines on dealing with PSR-4 libraries. http://fedoraproject.org/wiki/Packaging:PHP
Metadata Update from @tibbs:
- Issue assigned to tibbs
to comment on this ticket.