1) Introducing support for 32/64-bit variants of the patch files
2) Fix bug in fix_epoc32_linux.pl whereby changes to the gcc -preinclude patch file were not applied if already existed.
3) Extending weed_backups.pl to weed the epoc32 tree as well as the package dir
4) Make build_target.pl return non-0 if build has warnings
5) Make build_all.pl fail a target if it has warnings
#!/usr/bin/perl
# 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:
# Mike Kinghan, mikek@symbian.org, for Symbian Foundation Ltd - initial contribution.
# Subroutine to get the mercurial revision from which this package was branched
# from the file ../baseline.txt
use strict;
use File::Spec;
use places;
sub trim($)
{
my $string = shift;
$string =~ s/^\s+//;
$string =~ s/\s+$//;
return $string;
}
sub get_baseline()
{
my $epocroot = get_epocroot();
my $baseline_txt = File::Spec->catfile(get_pkg_dir(),"baseline.txt");
open IN,"<$baseline_txt" or die $!;
my @lines = <IN>;
close IN;
while(@lines and $lines[0] =~ /^\s*#/) {
shift @lines;
}
die "*** Error: can't extract baseline revsion no. from ../baseline.txt ***",
unless(@lines);
return trim($lines[0]);
}
1;