Commit | Line | Data |
8736538c |
1 | If you read this file _as_is_, just ignore the funny characters you |
2 | see. It is written in the POD format (see pod/perlpod.pod) which is |
3 | specially designed to be readable as is. |
5aabfad6 |
4 | |
8736538c |
5 | =head1 NAME |
5aabfad6 |
6 | |
8736538c |
7 | README.cygwin32 - notes about porting Perl to Cygwin32 |
5aabfad6 |
8 | |
8736538c |
9 | =head1 SYNOPSIS |
5aabfad6 |
10 | |
8736538c |
11 | =over |
5aabfad6 |
12 | |
8736538c |
13 | =item Cygwin32 |
5aabfad6 |
14 | |
8736538c |
15 | The Cygwin tools are ports of the popular GNU development tools for |
16 | Windows NT, 95, and 98. They run thanks to the Cygwin library which |
17 | provides the UNIX system calls and environment these programs expect. |
18 | More info about this project can be found at it's home page |
19 | http://sourceware.cygnus.com/cygwin/ |
5aabfad6 |
20 | |
8736538c |
21 | Cygnus Solutions also made the first set of notes and tools for |
22 | building perl under Cygwin32 beta17. |
23 | |
24 | =item als |
25 | |
26 | no, i am not hunting the patch pumpkin. i just wanted to have working |
27 | non-ActiveState perl binaries for Windows NT that can load dynamic |
28 | extensions. after several days of internet searching i went to conclusion |
29 | that the most promising way is to build it myself. i was wrong. |
30 | |
31 | =back |
32 | |
33 | =head1 BUILDING |
34 | |
35 | =head2 Prerequisites |
36 | |
37 | =over |
38 | |
39 | =item Cygwin b20.1 |
40 | |
41 | since you are willing to build things yourself, you are supposed to use |
42 | not-so-archaic tools. the latest stable Cygwin suite is beta20.1. it may be |
43 | downloaded from ftp://go.cygnus.com/pub/sourceware.cygnus.com/cygwin/latest/ |
44 | or many mirror sites around the world. |
45 | |
46 | =item egcs-1.1.2 |
47 | |
48 | i've tried to build with egcs-1.1 that comes with cygwin b20.1, and |
49 | had no luck. maybe, if a week ago i was as experienced as now, |
50 | things would go different... maybe. but this port was built with |
51 | egcs-1.1.2 downloaded from |
52 | ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/cygwin/egcs-1.1.2/ |
53 | |
54 | =item my patches |
55 | |
56 | if you are reading this, those are probably applied already. |
57 | |
58 | =item crypt library |
59 | |
60 | you do not want to see messages about excessive paranoia, do you? |
61 | well, http://miracle.geol.msu.ru/sos/ points to two different crypt |
62 | libraries ported to cygwin. i used libcrypt.tgz by Andy Piper. |
63 | his home page can be found at http://www.xemacs.freeserve.co.uk/ |
64 | |
65 | =item environment |
66 | |
67 | the locations of cygwin instllation are, well, a little unusual. |
68 | Configure will run smoother if you make more common aliases for cygwin |
69 | directories. it can be made either by C<mount>ing or by creating |
70 | directory symlinks like this: |
71 | |
72 | ln -s /cygnus/cygwin-b20/H-i586-cygwin32/bin/ $prefix/bin |
73 | ln -s /cygnus/cygwin-b20/H-i586-cygwin32/i586-cygwin32/include/ \ |
74 | $prefix/include |
75 | ln -s /cygnus/cygwin-b20/H-i586-cygwin32/i586-cygwin32/lib/ $prefix/lib |
76 | |
77 | $prefix may be empty (root), /usr, or /usr/local, as you preffer. |
78 | i used /usr. futhermore, t/io/taint.t requires cygwin1.dll to be |
79 | present in build directory or somewhere in system path (/WINNT, |
80 | /WINNT/System, /WINNT/System32). |
81 | |
82 | =back |
83 | |
84 | =head2 Configure |
85 | |
86 | run "sh Configure". |
87 | |
88 | When confronted with this prompt: |
89 | |
90 | =begin text |
5aabfad6 |
91 | |
92 | First time through, eh? I have some defaults handy for the |
93 | following systems: |
94 | . |
95 | . |
96 | . |
97 | Which of these apply, if any? |
98 | |
8736538c |
99 | =end text |
100 | |
101 | guess what system do you have. (hint: select "cygwin32"). |
102 | |
103 | i do not use malloc that comes with perl, but haven't put this setting |
104 | to hints file. perl defaults to use own malloc. |
105 | |
106 | Configure proposes additional -fpic flag for shared library module |
107 | compilation. say "none" because gcc complains that -fpic is useless. |
108 | |
109 | i hope that further defaults are ok. please double-chek it. |
110 | |
111 | =head2 make |
112 | |
113 | run "make". after that, run "make test" to see how unstable your system is. |
114 | for me, lib/io_sock.t waits for died child that has to be killed manually. |
115 | other test scripts seem to be more or less harmless. the result of |
116 | ./perl harness reads: |
117 | |
118 | =begin text |
119 | |
120 | Failed Test Status Wstat Total Fail Failed List of failed |
121 | ------------------------------------------------------------------------------- |
122 | lib/anydbm.t 2 512 12 8 66.67% 5-12 |
123 | lib/findbin.t 1 1 100.00% 1 |
124 | lib/io_sock.t 1 256 5 4 80.00% 2-5 |
125 | lib/sdbm.t 2 512 18 15 83.33% 2, 5-18 |
126 | op/magic.t 35 3 8.57% 1, 23, 30 |
127 | op/stat.t 58 3 5.17% 2, 9, 26 |
128 | pragma/locale.t 11 2816 102 4 3.92% 99-102 |
129 | 8 tests skipped, plus 35 subtests skipped. |
130 | Failed 7/190 test scripts, 96.32% okay. 38/6454 subtests failed, 99.41% okay. |
131 | |
132 | =end text |
133 | |
134 | =head1 BUGS |
135 | |
136 | a lot of warnings about incompatible pointer types and comparison |
137 | lacking a cast. this is because of __declspec(dllimport). |
138 | |
139 | upon each start, make warns that a rule for perlmain.o is overrided. |
140 | yes, it is. in order to use libperl.dll, perlmain needs to import |
141 | symbols from there. i saw no better solution than adding an explicit |
142 | define to the rule. |
143 | |
144 | as said above, IO::Socket generates access violation. don't know why. |
145 | don't need IO::Socket for now. |
146 | |
147 | make clean does not remove library .def and .exe.core files |
148 | |
149 | ld2 script is installed with reference to source directory. you should |
150 | change this to /usr/local/bin (or whatever) after install. |
151 | |
152 | .bat wrappers for installed utility scripts are not made during installation. |
5aabfad6 |
153 | |
8736538c |
154 | library man pages are not installed correctly due to file system limitations. |
155 | use perldoc script to read about things like foo::bar. |
5aabfad6 |
156 | |
8736538c |
157 | =head1 AUTHOR |
5aabfad6 |
158 | |
8736538c |
159 | alexander smishlajev <als@turnhere.com> |
5aabfad6 |
160 | |
8736538c |
161 | =head1 DISCLAIMER |
5aabfad6 |
162 | |
8736538c |
163 | i am not going to maintain this document or this port. i only wanted |
164 | to make perl porting a bit easier. if failed, i can't be helpful for you. |
5aabfad6 |
165 | |
8736538c |
166 | =head1 HISTORY |
5aabfad6 |
167 | |
8736538c |
168 | 17..25-apr-1999. perl 5.005_03. cygwin b20.1 egcs 1.1.2. |
169 | far 1.60. nescafe classic. |
5aabfad6 |
170 | |
8736538c |
171 | =cut |