Changeset 120199 in webkit


Ignore:
Timestamp:
Jun 13, 2012 6:51:08 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

[EFL] Store and compare md5sum of jhbuild files to trigger cleaning Dependencies
https://bugs.webkit.org/show_bug.cgi?id=85790

Patch by Dominik Röttsches <dominik.rottsches@intel.com> on 2012-06-13
Reviewed by Gustavo Noronha Silva.

Add md5 checks for jhbuild configuration for EFL, reusing the gtk jhbuild related
code in webkitdirs.pm.

  • Scripts/webkitdirs.pm:

(jhbuildConfigurationChanged):
(saveJhbuildMd5):
(cleanJhbuild):
(buildAutotoolsProject):
(generateBuildSystemFromCMakeProject):

Location:
trunk/Tools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r120193 r120199  
     12012-06-13  Dominik Röttsches  <dominik.rottsches@intel.com>
     2
     3        [EFL] Store and compare md5sum of jhbuild files to trigger cleaning Dependencies
     4        https://bugs.webkit.org/show_bug.cgi?id=85790
     5
     6        Reviewed by Gustavo Noronha Silva.
     7
     8        Add md5 checks for jhbuild configuration for EFL, reusing the gtk jhbuild related
     9        code in webkitdirs.pm.
     10
     11        * Scripts/webkitdirs.pm:
     12        (jhbuildConfigurationChanged):
     13        (saveJhbuildMd5):
     14        (cleanJhbuild):
     15        (buildAutotoolsProject):
     16        (generateBuildSystemFromCMakeProject):
     17
    1182012-06-13  Qi Zhang  <qi.2.zhang@nokia.com>
    219
  • trunk/Tools/Scripts/webkitdirs.pm

    r120032 r120199  
    18931893        }
    18941894
    1895         # Get the md5 sum of the file we're testing.
     1895        # Get the md5 sum of the file we're testing, look in the right platform directory.
    18961896        $file =~ m/(.+)\.md5sum/;
    1897         my $actualFile = join('/', $sourceDir, 'Tools', 'gtk', $1);
     1897        my $platformDir = isEfl() ? 'efl' : 'gtk';
     1898        my $actualFile = join('/', $sourceDir, 'Tools', $platformDir, $1);
    18981899        my $currentSum = getMD5HashForFile($actualFile);
    18991900
     
    19071908        }
    19081909    }
     1910}
     1911
     1912sub saveJhbuildMd5() {
     1913    my $platform = isEfl() ? 'efl' : 'gtk';
     1914    # Save md5sum for jhbuild-related files.
     1915    foreach my $file (qw(jhbuildrc jhbuild.modules)) {
     1916        my $source = join('/', $sourceDir, "Tools", $platform, $file);
     1917        my $destination = join('/', getJhbuildPath(), $file);
     1918        open(SUM, ">$destination" . ".md5sum");
     1919        print SUM getMD5HashForFile($source);
     1920        close(SUM);
     1921    }
     1922}
     1923
     1924sub cleanJhbuild() {
     1925        # If the configuration changed, dependencies may have been removed.
     1926        # Since we lack a granular way of uninstalling those we wipe out the
     1927        # jhbuild root and start from scratch.
     1928        my $jhbuildPath = getJhbuildPath();
     1929        if (system("rm -rf $jhbuildPath/Root") ne 0) {
     1930            die "Cleaning jhbuild root failed!";
     1931        }
     1932
     1933        my $platform = isEfl() ? 'efl' : 'gtk';
     1934        if (system("perl $sourceDir/Tools/jhbuild/jhbuild-wrapper --$platform clean") ne 0) {
     1935            die "Cleaning jhbuild modules failed!";
     1936        }
    19091937}
    19101938
     
    19982026    my $needUpdate = 0;
    19992027    if (jhbuildConfigurationChanged()) {
    2000         # If the configuration changed, dependencies may have been removed.
    2001         # Since we lack a granular way of uninstalling those we wipe out the
    2002         # jhbuild root and start from scratch.
    2003         my $jhbuildPath = getJhbuildPath();
    2004         if (system("rm -rf $jhbuildPath/Root") ne 0) {
    2005             die "Cleaning jhbuild root failed!";
    2006         }
    2007 
    2008         if (system("perl $sourceDir/Tools/jhbuild/jhbuild-wrapper --gtk clean") ne 0) {
    2009             die "Cleaning jhbuild modules failed!";
    2010         }
    2011 
     2028        cleanJhbuild();
    20122029        $needUpdate = 1;
    20132030    }
     
    20242041    }
    20252042
    2026     # Save md5sum for jhbuild-related files.
    2027     foreach my $file (qw(jhbuildrc jhbuild.modules)) {
    2028         my $source = join('/', $sourceDir, "Tools", "gtk", $file);
    2029         my $destination = join('/', getJhbuildPath(), $file);
    2030         open(SUM, ">$destination" . ".md5sum");
    2031         print SUM getMD5HashForFile($source);
    2032         close(SUM);
    2033     }
     2043    saveJhbuildMd5();
    20342044
    20352045    # If GNUmakefile exists, don't run autogen.sh unless its arguments
     
    20942104    if ($architecture ne "x86_64" && !isARM()) {
    20952105        $ENV{'CXXFLAGS'} = "-march=pentium4 -msse2 -mfpmath=sse " . ($ENV{'CXXFLAGS'} || "");
     2106    }
     2107
     2108    if (isEfl() && jhbuildConfigurationChanged()) {
     2109        cleanJhbuild();
     2110        system("perl", "$sourceDir/Tools/Scripts/update-webkitefl-libs") == 0 or die $!;
     2111    }
     2112
     2113    if (isEfl()) {
     2114        saveJhbuildMd5();
    20962115    }
    20972116
Note: See TracChangeset for help on using the changeset viewer.