diff options
author | Alexander Smishlajev <als@turnhere.com> | 1999-04-25 17:58:29 +0300 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1999-05-10 04:39:15 +0000 |
commit | 8736538c3cff6585c95a01b990d3b3a9e5d5744d (patch) | |
tree | a62ec1da701a15abcbfdff76f248259b80548f1a /cygwin32/build-instructions.steven-morlock2 | |
parent | 3eeba6fb8b434fcb27f601771baa0ea98f44d487 (diff) | |
download | perl-8736538c3cff6585c95a01b990d3b3a9e5d5744d.tar.gz |
cygwin32 update (untested adaptation of patch against 5.005_03)
Message-ID: <37230365.5F68B460@turnhere.com>
Subject: [PATCH]5.005_03 (CORE) cygwin32 port
p4raw-id: //depot/perl@3358
Diffstat (limited to 'cygwin32/build-instructions.steven-morlock2')
-rw-r--r-- | cygwin32/build-instructions.steven-morlock2 | 76 |
1 files changed, 76 insertions, 0 deletions
diff --git a/cygwin32/build-instructions.steven-morlock2 b/cygwin32/build-instructions.steven-morlock2 new file mode 100644 index 0000000000..0370b7053c --- /dev/null +++ b/cygwin32/build-instructions.steven-morlock2 @@ -0,0 +1,76 @@ +This is an addendum to Steven Morlock's original post. The patch, perl5.005_02.patch, contains the USEMYBINMODE correction described below. + +***************************** +Subject: Re: HOWTO: Builiding Perl under Win95/98 using Cygwin32 +Author: Steven Morlock <newspost@morlock.net> +Date: 1998/12/22 +Forum: comp.lang.perl.misc + +I realized that in my original post I left out a couple important +details. I'd like to correct that here. + +There is a need to address the issue of end of lines being CR/NL or +NL on the Windows platform. Cygwin32 by default converts NL to CR/NL +during file I/O by non Cygwin32-savvy applications. This means that +Perl, since it does not support 'binmode' for the Cygwin32 platform, will +not be able to read & write untranslated/binary files. There are two +methods of over coming this. The first is to mount the Cygwin32 +partitions in binary mode. The second is to enable binmode support +in Perl. In the original post I had mounted the partition as binary +and neglected to include that fact in the post. + +* Using a binary partition: + + Mount the Perl source & installation destination partitions in binary + mode. Refer to the Cygnus documentation on 'mount' for details: + + http://sourceware.cygnus.com/cygwin/cygwin-ug-net/mount.html + + On my system since everything was in the root partition I issued the + following commands from the bash shell: + + umount / + mount -b c:\\ / + + You must also get and install the gzip'd version of the Perl source code + archive. The zip'd version of the archive has all NL converted to CR/NL + pairs in all text files. So you should be downloading the files ending in + '.gz', not '.zip'. + +* Patching Perl to add Cygwin32 binmode support: + + For this method you can use either the gzip'd or zip'd version of the + Perl source archive. + + Apply the following patch to <PERL>/perl.h: + +*** perl.h.ORIG Tue Dec 22 09:22:42 1998 +--- perl.h Tue Dec 22 09:43:10 1998 +*************** +*** 1480,1483 **** +--- 1480,1495 ---- + #endif + ++ #if defined(__CYGWIN32__) ++ /* USEMYBINMODE ++ * This symbol, if defined, indicates that the program should ++ * use the routine my_binmode(FILE *fp, char iotype) to insure ++ * that a file is in "binary" mode -- that is, that no translation ++ * of bytes occurs on read or write operations. ++ */ ++ #define USEMYBINMODE / **/ ++ #define my_binmode(fp, iotype) \ ++ (PerlLIO_setmode(PerlIO_fileno(fp), O_BINARY) != -1 ? TRUE : NULL) ++ #endif ++ + #include "regexp.h" + #include "sv.h" + +Regards, +Steve + +-- +Steven Morlock +Foliage Software Systems +aka The Nerd Farm +http://www.foliage.com |