r16123 - gnucash/trunk/packaging/win32 - Use UNIX line delimiters in packaging/win32/exetype.pl.

Andreas Köhler andi5 at cvs.gnucash.org
Wed May 23 13:21:24 EDT 2007


Author: andi5
Date: 2007-05-23 13:21:20 -0400 (Wed, 23 May 2007)
New Revision: 16123
Trac: http://svn.gnucash.org/trac/changeset/16123

Modified:
   gnucash/trunk/packaging/win32/exetype.pl
Log:
Use UNIX line delimiters in packaging/win32/exetype.pl.


Modified: gnucash/trunk/packaging/win32/exetype.pl
===================================================================
--- gnucash/trunk/packaging/win32/exetype.pl	2007-05-23 17:21:14 UTC (rev 16122)
+++ gnucash/trunk/packaging/win32/exetype.pl	2007-05-23 17:21:20 UTC (rev 16123)
@@ -1,28 +1,28 @@
-#!/usr/bin/env perl
-
-# URL: http://jenda.krynicky.cz/perl/GUIscripts.html
-# code by: Jan Dubois <jand at ActiveState.com>
-
-use strict;
-unless (@ARGV == 2) {
-    print "Usage: $0 exefile [CONSOLE|WINDOWS]\n";
-    exit;
-}
-unless ($ARGV[1] =~ /^(console|windows)$/i) {
-    print "Invalid subsystem $ARGV[1], please use CONSOLE or WINDOWS\n";
-    exit;
-}
-my ($record,$magic,$offset,$size);
-open EXE, "+< $ARGV[0]" or die "Cannot open $ARGV[0]: $!";
-binmode EXE;
-read EXE, $record, 32*4;
-($magic,$offset) = unpack "Sx58L", $record;
-die "Not an MSDOS executable file" unless $magic == 0x5a4d;
-seek EXE, $offset, 0;
-read EXE, $record, 24;
-($magic,$size) = unpack "Lx16S", $record;
-die "PE header not found" unless $magic == 0x4550;
-die "Optional header not in NT32 format" unless $size == 224;
-seek EXE, $offset+24+68, 0;
-print EXE pack "S", uc($ARGV[1]) eq 'CONSOLE' ? 3 : 2;
-close EXE;
+#!/usr/bin/env perl
+
+# URL: http://jenda.krynicky.cz/perl/GUIscripts.html
+# code by: Jan Dubois <jand at ActiveState.com>
+
+use strict;
+unless (@ARGV == 2) {
+    print "Usage: $0 exefile [CONSOLE|WINDOWS]\n";
+    exit;
+}
+unless ($ARGV[1] =~ /^(console|windows)$/i) {
+    print "Invalid subsystem $ARGV[1], please use CONSOLE or WINDOWS\n";
+    exit;
+}
+my ($record,$magic,$offset,$size);
+open EXE, "+< $ARGV[0]" or die "Cannot open $ARGV[0]: $!";
+binmode EXE;
+read EXE, $record, 32*4;
+($magic,$offset) = unpack "Sx58L", $record;
+die "Not an MSDOS executable file" unless $magic == 0x5a4d;
+seek EXE, $offset, 0;
+read EXE, $record, 24;
+($magic,$size) = unpack "Lx16S", $record;
+die "PE header not found" unless $magic == 0x4550;
+die "Optional header not in NT32 format" unless $size == 224;
+seek EXE, $offset+24+68, 0;
+print EXE pack "S", uc($ARGV[1]) eq 'CONSOLE' ? 3 : 2;
+close EXE;



More information about the gnucash-changes mailing list