47 print ">>> Executing: $patch_test\n"; |
47 print ">>> Executing: $patch_test\n"; |
48 my $rc = system($patch_test); |
48 my $rc = system($patch_test); |
49 die "*** Error: can't execute the patch tool ***", if ($rc); |
49 die "*** Error: can't execute the patch tool ***", if ($rc); |
50 $baseline_dir = abs_path($baseline_dir); |
50 $baseline_dir = abs_path($baseline_dir); |
51 perl_run("get_upstream.pl $baseline_dir") and die $!; |
51 perl_run("get_upstream.pl $baseline_dir") and die $!; |
52 set_epocroot(); |
52 my $epocroot = get_epocroot(); |
53 my $epocroot = $ENV{'EPOCROOT'}; |
|
54 if (!$patch_in) { |
53 if (!$patch_in) { |
55 my $baseline_rev = get_baseline(); |
54 my $baseline_rev = get_baseline(); |
56 $patch_in = File::Spec->catfile("$epocroot","build","cross-plat-dev-utils", |
55 $patch_in = File::Spec->catfile(get_pkg_dir(),"cross-plat-dev-utils", |
57 "patch-files","diffs","patch-$baseline_rev.patch"); |
56 "patch-files","diffs","patch-$baseline_rev.patch"); |
58 } |
57 } |
59 die "*** Error: can't find patch file \"$patch_in\" ***", unless ( -f $patch_in); |
58 die "*** Error: can't find patch file \"$patch_in\" ***", unless ( -f $patch_in); |
60 $baseline_dir = File::Spec->catfile("$baseline_dir","build"); |
59 $baseline_dir = File::Spec->catfile("$baseline_dir","build"); |
61 my $pnum = compute_pnum($patch_in); |
60 my $pnum = compute_pnum($patch_in); |