Commit | Line | Data |
---|---|---|
e1caacb4 JH |
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 | specifically designed to be readable as is. | |
4 | ||
7a5cdbdf | 5 | =head1 NAME |
e1caacb4 | 6 | |
7a5cdbdf | 7 | perlce - Perl for WinCE |
e1caacb4 | 8 | |
7a5cdbdf | 9 | =head1 DESCRIPTION |
e1caacb4 | 10 | |
dab75801 | 11 | This file gives the instructions for building Perl5.8 and above for |
e1caacb4 JH |
12 | WinCE. Please read and understand the terms under which this |
13 | software is distributed. | |
14 | ||
7a5cdbdf | 15 | =head1 BUILD |
e1caacb4 JH |
16 | |
17 | This section describes the steps to be performed to build PerlCE. | |
dab75801 | 18 | You may find additional and newer information about building perl |
42272d83 | 19 | for WinCE using following URL: |
dab75801 JH |
20 | |
21 | http://perlce.sourceforge.net | |
22 | ||
23 | There should also be pre-built binaries there. | |
e1caacb4 | 24 | |
42272d83 JH |
25 | Don't be confused by large size of downloaded distribution or constructed |
26 | binaries: entire distribution could be large for WinCE ideology, but | |
27 | you may strip it at your wish and use only required parts. | |
28 | ||
e1caacb4 JH |
29 | =head2 Tools & SDK |
30 | ||
dab75801 JH |
31 | For compiling, you need following: |
32 | ||
33 | =over 4 | |
34 | ||
35 | =item * Microsoft Embedded Visual Tools | |
36 | ||
37 | =item * Microsoft Visual C++ | |
38 | ||
39 | =item * Rainer Keuchel's celib-sources | |
40 | ||
41 | =item * Rainer Keuchel's console-sources | |
42 | ||
43 | =back | |
e1caacb4 JH |
44 | |
45 | Needed source files can be downloaded via: | |
46 | www.rainer-keuchel.de/wince/dirlist.html | |
47 | ||
e1caacb4 JH |
48 | =head2 Make |
49 | ||
dab75801 JH |
50 | Please pay attention that starting from 5.8.0 miniperl *is* built |
51 | and it facilitates in further building process. This means that | |
52 | in addition to compiler installation for mobile device you also need | |
53 | to have Microsoft Visual C++ installed as well. | |
e1caacb4 | 54 | |
dab75801 JH |
55 | On the bright side, you do not need to edit any files from ./win32 |
56 | subdirectory. Normally you only need to edit ./wince/compile.bat | |
57 | to reflect your system and run it. | |
e1caacb4 | 58 | |
dab75801 JH |
59 | File ./wince/compile.bat is actually a wrapper to call |
60 | nmake -f makefile.ce with appropriate parameters and it accepts extra | |
61 | parameters and forwards them to "nmake" command as additional | |
62 | arguments. You should pass target this way. | |
e1caacb4 | 63 | |
42272d83 | 64 | To prepare distribution you need to do following: |
dab75801 JH |
65 | |
66 | =over 4 | |
67 | ||
68 | =item * go to ./wince subdirectory | |
69 | ||
70 | =item * edit file compile.bat | |
e1caacb4 | 71 | |
dab75801 JH |
72 | =item * run |
73 | compile.bat | |
e1caacb4 | 74 | |
dab75801 JH |
75 | =item * run |
76 | compile.bat dist | |
e1caacb4 | 77 | |
dab75801 JH |
78 | =back |
79 | ||
42272d83 JH |
80 | makefile.ce has CROSS_NAME macro, and it is used further to refer to |
81 | your cross-compilation scheme. You could assign a name to it, but this | |
82 | is not necessary, because by default it is assigned after your machine | |
83 | configuration name, such as "wince-sh3-hpc-wce211", and this is enough | |
84 | to distinguish different builds at the same time. This option could be | |
85 | handy for several different builds on same platform to perform, say, | |
86 | threaded build. In a following example we assume that all required | |
87 | environment variables are set properly for C cross-compiler (a special | |
88 | *.bat file could fit perfectly to this purpose) and your compile.bat | |
89 | has proper "MACHINE" parameter set, to, say, "wince-mips-pocket-wce300". | |
90 | ||
91 | compile.bat | |
92 | compile.bat dist | |
93 | compile.bat CROSS_NAME=mips-wce300-thr "USE_ITHREADS=define" "USE_IMP_SYS=define" "USE_MULTI=define" | |
94 | compile.bat CROSS_NAME=mips-wce300-thr "USE_ITHREADS=define" "USE_IMP_SYS=define" "USE_MULTI=define" dist | |
95 | ||
96 | If all goes okay and no errors during a build, you'll get two independent | |
97 | distributions: "wince-mips-pocket-wce300" and "mips-wce300-thr". | |
98 | ||
99 | Target 'dist' prepares distribution file set. Target 'zipdist' performs | |
100 | same as 'dist' but additionally compresses distribution files into zip | |
101 | archive. | |
102 | ||
103 | NOTE: during a build there could be created a number (or one) of Config.pm | |
104 | for cross-compilation ("foreign" Config.pm) and those are hidden inside | |
105 | ../xlib/$(CROSS_NAME) with other auxilary files, but, and this is important to | |
106 | note, there should be *no* Config.pm for host miniperl. | |
107 | If you'll get an error that perl could not find Config.pm somewhere in building | |
108 | process this means something went wrong. Most probably you forgot to | |
109 | specify a cross-compilation when invoking miniperl.exe to Makefile.PL | |
110 | When building an extension for cross-compilation your command line should | |
111 | look like | |
112 | ||
113 | ..\miniperl.exe -I..\lib -MCross=mips-wce300-thr Makefile.PL | |
114 | ||
115 | or just | |
116 | ||
117 | ..\miniperl.exe -I..\lib -MCross Makefile.PL | |
118 | ||
119 | to refer a cross-compilation that was created last time. | |
120 | ||
121 | ||
122 | If you decided to build with fcrypt.c file, please refer to README.win32 | |
123 | file, as long as all legal considerations and steps to do are exactly same | |
124 | in this case. | |
125 | ||
126 | All questions related to building for WinCE devices could be asked in | |
127 | perlce-users@lists.sourceforge.net mailing list. | |
e1caacb4 | 128 | |
7a5cdbdf | 129 | =head1 ACKNOWLEDGEMENTS |
e1caacb4 JH |
130 | |
131 | The port for Win32 was used as a reference. | |
132 | ||
dab75801 | 133 | =head1 AUTHORS |
e1caacb4 JH |
134 | |
135 | Rainer Keuchel (keuchel@netwave.de) | |
dab75801 JH |
136 | Vadim Konovalov (vkonovalov@spb.lucent.com) |
137 |