Created attachment 824122 [details] drupal7-ultimate_cron.spec Description of problem: Auto-requires throws an rpmbuild error for certain modules. Version-Release number of selected component (if applicable): drupal7-7.23-3 How reproducible: * rpmbuild the attached RPM spec file Actual results: RPM build errors: line 53: Dependency tokens must begin with alpha-numeric, '_' or '/': - Initial package Expected results: Successful RPM build and correct auto-requires being set
I figured out the issue here... on RHEL 5/6, "/usr/lib/rpm/find-requires" does not correctly ignore the missing "#!" line in wrongfully executable PHP files and tries to add invalid "<?php" as a dependency. The solution here is for the packager to remove the executable bit from Drupal files that do not begin with "#!". The packager could bypass the auto-requires (by adding "AutoReqProv: no" to the spec), and manually specify the dependencies, but when he/she runs rpmlint against the resulting RPMs it should throw "E: script-without-shebang" errors which the packager should fix anyway (and then auto-requires could then again be used). I will add this information to the packaging guidelines draft.