diff options
author | David Holm <dholm@gentoo.org> | 2004-03-05 13:29:09 +0000 |
---|---|---|
committer | David Holm <dholm@gentoo.org> | 2004-03-05 13:29:09 +0000 |
commit | d96d4e3d11cab39dd3e759bce811ea0e3a071817 (patch) | |
tree | 33f70e44aa47fe110614d84ade47fe5bc70831b7 /app-emulation/uae/files/split_cpuemu.pl | |
parent | stable on sparc (Manifest recommit) (diff) | |
download | gentoo-2-d96d4e3d11cab39dd3e759bce811ea0e3a071817.tar.gz gentoo-2-d96d4e3d11cab39dd3e759bce811ea0e3a071817.tar.bz2 gentoo-2-d96d4e3d11cab39dd3e759bce811ea0e3a071817.zip |
Added splitter script from Michal Januszewski (spock@g.o)
Diffstat (limited to 'app-emulation/uae/files/split_cpuemu.pl')
-rw-r--r-- | app-emulation/uae/files/split_cpuemu.pl | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/app-emulation/uae/files/split_cpuemu.pl b/app-emulation/uae/files/split_cpuemu.pl new file mode 100644 index 000000000000..0ddacecc6c87 --- /dev/null +++ b/app-emulation/uae/files/split_cpuemu.pl @@ -0,0 +1,32 @@ +#!/usr/bin/perl + +open(INPUT, "<cpuemu_6.c"); +open(OUT1, ">cpuemu_6.t"); +open(OUT2, ">cpuemu_7.c"); + +$header = 1; +$part = 0; + +while ($line = <INPUT>) { + + $size += length($line); + + if (($line =~ /^#/ || $line eq "\n") && ($line ne "#ifdef PART_1\n") && $header) { + print OUT1 $line; + print OUT2 $line; + } else { + + $header = 0; + + if ($line ne "#ifdef PART_4\n" && $part == 0) { + print OUT1 $line; + } else { + $part = 1; + print OUT2 $line; + } + } +} + +close(OUT2); +close(OUT1); +close(INPUT); |