# HG changeset patch # User Simon Howkins # Date 1287070173 -3600 # Node ID 77ff148fa4d23f839a92dbb1bd5f299018d92642 # Parent 13e40df944921e4a5091dc60a6155cd683c313e5 Added a post build check that the release zips don't collide. Collisions are BRAG affecting. diff -r 13e40df94492 -r 77ff148fa4d2 common/build.postbuild.xml --- a/common/build.postbuild.xml Tue Oct 12 17:23:11 2010 +0100 +++ b/common/build.postbuild.xml Thu Oct 14 16:29:33 2010 +0100 @@ -61,6 +61,9 @@ + + + @@ -828,6 +831,20 @@ + + + + + + + + + + + + + + diff -r 13e40df94492 -r 77ff148fa4d2 common/tools/brag/rules.ArchiveCollisions.tsv --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/common/tools/brag/rules.ArchiveCollisions.tsv Thu Oct 14 16:29:33 2010 +0100 @@ -0,0 +1,2 @@ +^ERROR: samsung_rndonly.txt ignore +^ERROR: major diff -r 13e40df94492 -r 77ff148fa4d2 common/tools/detectArchiveCollisions.pl --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/common/tools/detectArchiveCollisions.pl Thu Oct 14 16:29:33 2010 +0100 @@ -0,0 +1,56 @@ +#!perl -w +# Copyright (c) 2010 Symbian Foundation Ltd +# This component and the accompanying materials are made available +# under the terms of the License "Eclipse Public License v1.0" +# which accompanies this distribution, and is available +# at the URL "http://www.eclipse.org/legal/epl-v10.html". +# +# Initial Contributors: +# Symbian Foundation Ltd - initial contribution. +# +# Contributors: +# +# Description: +# Identify collisions between file archives +# +# Usage: +# detectArchiveCollisions.pl this.zip that.zip several_*.zip and\also_*.7z + +use strict; + +# Expand shell wildcards +@ARGV = map { glob $_ } @ARGV; + +my $data; + +foreach my $archive (@ARGV) +{ + print "Reading $archive...\n"; + my $file = undef; + foreach my $line (`7z l -slt $archive`) + { + if ($line =~ m{^Path = (.*)}) + { + $file = $1; + next; + } + + if ($line =~ m{^Folder = -}) + { + # Record this (non-directory) item + push @{$data->{$file}}, $archive; + next; + } + } +} + +foreach my $file (sort keys %$data) +{ + next unless scalar @{$data->{$file}} > 1; + print "ERROR: $file\n"; + foreach (@{$data->{$file}}) + { + print "\t$_\n"; + } +} +