Changeset 41369


Ignore:
Timestamp:
Oct 31, 2008, 6:18:59 PM (11 years ago)
Author:
ricci@…
Message:

Uprev to 0.15
rework patch to fit changed module

Location:
trunk/dports/perl/p5-file-mimeinfo
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/perl/p5-file-mimeinfo/Portfile

    r32568 r41369  
    55PortGroup               perl5 1.0
    66
    7 version                 0.14
     7version                 0.15
    88perl5.setup             File-MimeInfo ${version}
    99revision                0
     
    1313long_description        ${description}
    1414
    15 checksums               md5 b4cb0ea1a30730c24747199784d90968          \
    16                 sha1 5a375be72c3b9107cdb4ada65b3973bb33e4f474
     15checksums           md5     41fa5a252203e1d6023ab5849fd9e0df \
     16                    sha1    e185dd52769ec3c77cbb1eb983e49b843e5e38e5
     17
    1718platforms               darwin
    1819
  • trunk/dports/perl/p5-file-mimeinfo/files/patch-lib-File-MimeInfo.pm.diff

    r32568 r41369  
    1 --- lib/File/MimeInfo.pm.orig   2008-01-07 16:15:31.000000000 -0800
    2 +++ lib/File/MimeInfo.pm        2008-01-07 16:18:02.000000000 -0800
    3 @@ -23,6 +23,8 @@
    4  # $LANG can be used to set a default language for the comments
    5  # @DIRS can be used to specify custom database directories
    6  
    7 +## setup @DIRS to point to the DB that MacPorts installed, thus users don't have to set ENV vars and such.
    8 +push @DIRS, '__PREFIX__/share/mime';
    9  rehash(); # initialise data
    10  
    11  sub new { bless \$VERSION, shift } # what else is there to bless ?
     1--- lib/File/MimeInfo.pm.orig   2008-02-13 16:38:59.000000000 -0800
     2+++ lib/File/MimeInfo.pm        2008-10-31 10:52:12.000000000 -0700
     3@@ -136,6 +136,19 @@
     4 sub rehash {
     5        (@globs, %literal, %extension, %mime2ext) = (); # clear all data
     6        local $_; # limit scope of $_ ... :S
     7+       
     8+       ## setup @DIRS to point to the DB that MacPorts installed,
     9+       ## thus users don't have to set ENV vars and such.
     10+       my $DIRS_index = undef;
     11+       for ($DIRS_index = 0; $DIRS_index < @DIRS; $DIRS_index++) {
     12+               if ($DIRS[$DIRS_index] =~ m|__PREFIX__/share/mime|) {
     13+                       last;
     14+               }
     15+       }
     16+       if ($DIRS_index >= @DIRS) {
     17+               ## we didn't find the MP prefix path, add it...
     18+               push @DIRS, '__PREFIX__/share/mime';
     19+       }
     20        my @globfiles = @DIRS
     21                ? ( grep {-e $_ && -r $_} map "$_/globs", @DIRS )
     22                : ( reverse data_files('mime/globs')        );
Note: See TracChangeset for help on using the changeset viewer.