Ignore:
Timestamp:
Mar 8, 2010, 12:52:58 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.6.2 sources.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/bin/patch_capabilities.pl

    r561 r651  
    22#############################################################################
    33##
    4 ## Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
     4## Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
    55## All rights reserved.
    66## Contact: Nokia Corporation (qt-info@nokia.com)
     
    109109        open (PKG, "<".$pkgFileName);
    110110
     111        my $manufacturerElseBlock = 0;
     112
    111113        # Parse each line.
    112114        while (<PKG>)
    113115        {
     116            # Patch pkg UID
    114117            my $line = $_;
    115118            my $newLine = $line;
    116             if ( $line =~ m/^\#.*\(0x[0-9|a-f|A-F]*\).*$/)
     119            if ($line =~ m/^\#.*\(0x[0-9|a-f|A-F]*\).*$/)
    117120            {
    118121                $newLine =~ s/\(0x./\(0xE/;
    119122            }
     123
     124            # Patch embedded sis name and UID
     125            if ($line =~ m/^@.*\.sis.*\(0x[0-9|a-f|A-F]*\).*$/)
     126            {
     127                $newLine =~ s/\(0x./\(0xE/;
     128                if ($line !~ m/^.*_selfsigned.sis.*$/)
     129                {
     130                    $newLine =~ s/\.sis/_selfsigned\.sis/i;
     131                }
     132            }
     133
     134            # Remove dependencies to known problem packages (i.e. packages that are likely to be patched, also)
     135            # to reduce unnecessary error messages.
     136            if ($line =~ m/^\(0x2002af5f\).*\{.*\}$/)
     137            {
     138                $newLine = "\n"
     139            }
     140            if ($line =~ m/^\(0x2001E61C\).*\{.*\}$/)
     141            {
     142                $newLine = "\n"
     143            }
     144
     145            # Remove manufacturer ifdef
     146            if ($line =~ m/^.*\(MANUFACTURER\)\=\(.*\).*$/)
     147            {
     148                $newLine = "\n";
     149            }
     150
     151            if ($line =~ m/^ELSEIF.*MANUFACTURER$/)
     152            {
     153                $manufacturerElseBlock = 1;
     154            }
     155
     156            if ($manufacturerElseBlock eq 1)
     157            {
     158                $newLine = "\n";
     159            }
     160
     161            if ($line =~ m/^ENDIF.*MANUFACTURER$/)
     162            {
     163                $manufacturerElseBlock = 0;
     164            }
     165
    120166            print NEW_PKG $newLine;
    121167
Note: See TracChangeset for help on using the changeset viewer.