ITK/Release 4/Wrapping/Tasks/WrapITKModular

From KitwarePublic
< ITK‎ | Release 4‎ | Wrapping‎ | Tasks
Revision as of 00:48, 1 June 2011 by Ashishs99 (talk | contribs) (Created page with "= Modular WrapITK = == Mapping of files == * measure the build speedup * write documentation on the wiki ** Documentation: [http://itk.org/Wiki/ITK_Release_4/Wrapping/ccache Usi...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

Modular WrapITK

Mapping of files

Script used to obtain the mapping

#!/usr/bin/perl -w 
require 5.004;
 
$fname = "Ashish_AllWrapFiles";
$outname = "Ashish_ModFiles";

# First, prepare the input file
open(FILE2, ">$fname") || die "Could not open $fname\n";
system("find . -name \*\.wrap >> $fname")  == 0 || die "system error $?"; 
close(FILE2);
# Next, process and write it in the output file
open(FILE, "$fname") || die "Could not open $fname\n";
open (OUTPUT, ">$outname") || die "Could not open $outname\n";
#$pattern = '^\.\/Wrapping\/WrapITK\/Libraries\/(\w*)\/(\w*)\.wrap';
$pattern = '^\.\/(((\w*)\/)+)(\w*)\.wrap';

while ($line = <FILE>) { 
    chomp($line);
    if($line=~/$pattern/)  {
        system("find . -name \'$4.h\' >> $outname") == 0 || die "system error $?"; 
    }
} 
close(FILE);
close(OUTPUT);