perl5 portgroup [patch]
Bradley Giesbrecht
pixilla at macports.org
Tue Sep 4 19:17:13 PDT 2012
On Sep 4, 2012, at 6:05 PM, Bradley Giesbrecht wrote:
> This perl5 portgroup proc does not handle this version correctly:
>
> # convert a floating point version to an dotted-integer one
> proc perl5_convert_version {vers} {
> set index [string first . $vers]
> set other_dot [string first . [string range $vers [expr $index + 1] end]]
> if {$index == -1 || $other_dot != -1} {
> return $vers
> }
> set ret [string range $vers 0 [expr $index - 1]]
> incr index
> set fractional [string range $vers $index end]
> set index 0
> while {$index < [string length $fractional] || $index < 6} {
> set sub [string range $fractional $index [expr $index + 2]]
> if {[string length $sub] < 3} {
> append sub [string repeat "0" [expr 3 - [string length $sub]]]
> }
> append ret ".[scan $sub %u]"
> incr index 3
> }
> return $ret
> }
> set perl5.moduleversion 1.03ii
> puts [perl5_convert_version ${perl5.moduleversion}]
> 1.3.{}
>
>
> Manually setting the version after "perl5.setup" fixes the problem.
>
> I was wondering if there is any code in base or another portgroup that might handle this better.
>
> Would simply shifting a run of alpha characters off the right at the beginning and adding them back the result at the end work?
https://trac.macports.org/attachment/ticket/35976/patch-perl5-1.0-alpha-ending-vers.diff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2763 bytes
Desc: not available
URL: <http://lists.macosforge.org/pipermail/macports-dev/attachments/20120904/a8c3ae43/attachment.p7s>
More information about the macports-dev
mailing list