From: Gurusamy Sarathy Date: Thu, 30 Dec 1999 19:36:21 +0000 (+0000) Subject: avoid CRLF in byteloadable files created by perlcc X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c9ce37aecd0e1f7271370137e323df19ca939619;p=p5sagit%2Fp5-mst-13.2.git avoid CRLF in byteloadable files created by perlcc p4raw-id: //depot/perl@4741 --- diff --git a/utils/perlcc.PL b/utils/perlcc.PL index a8c6ab4..734b20a 100644 --- a/utils/perlcc.PL +++ b/utils/perlcc.PL @@ -257,20 +257,19 @@ sub _createCode local($") = " -I"; - open(GENFILE, "> $generated_file") || die "Can't open $generated_file: $!"; - if ($backend eq "Bytecode") { require ByteLoader; + open(GENFILE, "> $generated_file") || die "Can't open $generated_file: $!"; + binmode GENFILE; print GENFILE "#!$^X\n" if @_ == 3; print GENFILE "use ByteLoader $ByteLoader::VERSION;\n"; + close(GENFILE); $output_switch ="a"; } - close(GENFILE); - if (@_ == 3) # compiling a program { chmod $generated_file, 0777 & ~umask if $backend eq "Bytecode";