#!c:/pgg/bin/perl.exe -w use strict; ##### Name: cc2p.pl ##### Version: 0.0.1.0 ##### Author: pGG ##### Contact: y6cme@sohu.com [http://perl.3322.org/~pgg] ##### Licence: The license of Perl ##### Updated: 2003-2-8 my $old=shift||'cc2p.exe'; my $new=shift||'cc2p.ple'; open(FILE,$old); binmode(FILE); my $gh; while(){ $gh.=$_; } my $hmm=index($gh,'-e',0); my $vov=index($gh,'dl_win32.c',0); $hmm+=2; $vov-=1; my $len=$vov-$hmm; close FILE; open(OLD,$old); binmode(OLD); my $pgg; seek(OLD,$hmm,1); read(OLD,$pgg,$len,0); $pgg=~s/\\\$/\$/g; $pgg=~s/\\\{/\{/g; $pgg=~s/\\\}/\}/g; $pgg=~s/\\\\/\\/g; $pgg=~s/\\\"/\"/g; $pgg=~s/\\\@/\@/g; open(NEW,">$new"); print NEW $pgg; close OLD; close NEW; #enjoy