Description of problem: cpanspec parses version numbers starting with 'v' and concludes that this should be a part of the version number for the rpm packages. This could be both considered as a bug and a feature :) Version-Release number of selected component (if applicable): cpanspec-1.65-1.fc5 How reproducible: always Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info: I would like cpanspec to parse the package versions and split of the the first v or v. from the package - do you agree? The package in the URL shows this behaviour.
I'd argue that this is a bug in the upstream package, since it is different than every other package on CPAN that I have looked at. Looking more closely, there appears to be one package on CPAN that uses "v." in the file name, and something like 75 that use "V" or "v". While I'm not crazy about supporting this, it seems to be easy enough. Try the attached patch. It seems obvious enough that I will apply it to the next release, but I'd appreciate some feedback.
Created attachment 128681 [details] strip leading "v" from rpm version
Created attachment 128682 [details] strip leading "v" from rpm version Safer regex.
(In reply to comment #1) > I'd argue that this is a bug in the upstream package, since it is different than > every other package on CPAN that I have looked at. > > Looking more closely, there appears to be one package on CPAN that uses "v." in > the file name, and something like 75 that use "V" or "v". > > While I'm not crazy about supporting this, it seems to be easy enough. Try the > attached patch. It seems obvious enough that I will apply it to the next > release, but I'd appreciate some feedback. I completely agree with you that this is a bug in the upstream package, but I also believe that the time invested in making cpanspec more liberal would be minimal compared to trying to get all those packages fixed :) I tried building one package that shows this problem, works as expected. This package also has another problem, the $VERSION doesn't get picked up correctly - but that is a problem of rpm. I registered a bug against it in rt.cpan.org
That sounds like bug 140597. Does the patch included there fix the problem?
(In reply to comment #5) > That sounds like bug 140597. Does the patch included there fix the problem? No, this is http://rt.cpan.org/Public/Bug/Display.html?id=19103 - a different matter. I don't think perl could pick up these things reliably unless it's starts evaling.