Commit | Line | Data |
867988ae |
1 | after 5.003_05: |
2 | PERLLIB_PREFIX was not active if it matches an element of @INC |
3 | as a whole. |
4 | Do not need PERL_SBRK if crtdll-revision is >= 50. |
5 | Use -Zsmall-conv if crtdll-revision is >= 50 (in static perl!). |
6 | :7: warning: #warning <dirent.h> requires <sys/types.h> |
7 | We compile miniperl static. It cannot fork, thus there may be |
8 | problems with pipes (since HAS_FORK is in |
9 | place). Pipes are required by makemaker. |
10 | We compile perl___.exe A.OUT and dynamic. It should be able to |
11 | fork. |
12 | If we can fork, we my_popen by popen unless "-|". Thus we |
13 | write a cooky "-1" into the pid array to indicate |
14 | this. |
15 | Apparently we can fork, and we can load dynamic extensions |
16 | now, though probably not simultaneously. |
17 | *DB tests corrected for OS/2 one-user stat[2]. |
18 | /bin/sh is intercepted and replaced by SH_PATH. |
19 | Note that having '\\' in the command line of one-arg `system' |
20 | would trigger call via shell. |
21 | Segfault with system {'ls'} 'blah'; corrected. |
22 | Documentation of OS/2-different features added to main PODs. |
23 | New buitins in Cwd:: |
24 | |
25 | Cwd::current_drive |
26 | Cwd::sys_chdir - leaves drive as it is. |
27 | Cwd::change_drive |
28 | Cwd::sys_is_absolute - has drive letter and is_rooted |
29 | Cwd::sys_is_rooted - has leading [/\\] (maybe |
30 | after a drive) |
31 | Cwd::sys_is_relative - changes with current dir |
32 | Cwd::sys_cwd - Interface to cwd from EMX. |
33 | Cwd::sys_abspath(name, dir) |
34 | - Really really odious |
35 | function. Returns absolute |
36 | name of file which would |
37 | have 'name' if CWD were 'dir'. |
38 | Dir defaults to the current dir. |
39 | Cwd::extLibpath [type] - Get/set current value of extended |
40 | Cwd::extLibpath_set - library search path. |
41 | path [type] |
42 | The optional last argument redirects |
43 | to END-path if true, |
44 | default is to search BEGIN-path. |
45 | (Note that some of these may be moved to different |
46 | libraries - eventually). |
47 | Executables: |
48 | perl - can fork, can dynalink (but not simultaneously) |
49 | perl_ - can fork, cannot dynalink |
50 | perl__ - same as perl___, but PM. |
51 | perl___ - cannot fork, can dynalink. |
52 | The build of the first one - perl - is rather convoluted, and |
53 | requires a build of miniperl_. |
54 | after 5.003_05: |
55 | PERLLIB_PREFIX was not active if it matches an element of @INC |
56 | as a whole. |
57 | Do not need PERL_SBRK if crtdll-revision is >= 50. |
58 | Use -Zsmall-conv if crtdll-revision is >= 50 (in static perl!). |
59 | :7: warning: #warning <dirent.h> requires <sys/types.h> |
60 | We compile miniperl static. It cannot fork, thus there may be |
61 | problems with pipes (since HAS_FORK is in |
62 | place). Pipes are required by makemaker. |
63 | We compile perl___.exe A.OUT and dynamic. It should be able to |
64 | fork. |
65 | If we can fork, we my_popen by popen unless "-|". Thus we |
66 | write a cooky "-1" into the pid array to indicate |
67 | this. |
68 | Apparently we can fork, and we can load dynamic extensions |
69 | now, though probably not simultaneously. |
70 | *DB tests corrected for OS/2 one-user stat[2]. |
71 | /bin/sh is intercepted and replaced by SH_PATH. |
72 | Note that having '\\' in the command line of one-arg `system' |
73 | would trigger call via shell. |
74 | Segfault with system {'ls'} 'blah'; corrected. |
75 | Documentation of OS/2-different features added to main PODs. |
76 | New buitins in Cwd:: |
77 | |
78 | Cwd::current_drive |
79 | Cwd::sys_chdir - leaves drive as it is. |
80 | Cwd::change_drive |
81 | Cwd::sys_is_absolute - has drive letter and is_rooted |
82 | Cwd::sys_is_rooted - has leading [/\\] (maybe |
83 | after a drive) |
84 | Cwd::sys_is_relative - changes with current dir |
85 | Cwd::sys_cwd - Interface to cwd from EMX. |
86 | Cwd::sys_abspath(name, dir) |
87 | - Really really odious |
88 | function. Returns absolute |
89 | name of file which would |
90 | have 'name' if CWD were 'dir'. |
91 | Dir defaults to the current dir. |
92 | Cwd::extLibpath [type] - Get/set current value of extended |
93 | Cwd::extLibpath_set - library search path. |
94 | path [type] |
95 | The optional last argument redirects |
96 | to END-path if true, |
97 | default is to search BEGIN-path. |
98 | (Note that some of these may be moved to different |
99 | libraries - eventually). |
100 | Executables: |
101 | perl - can fork, can dynalink (but not simultaneously) |
102 | perl_ - can fork, cannot dynalink |
103 | perl__ - same as perl___, but PM. |
104 | perl___ - cannot fork, can dynalink. |
105 | The build of the first one - perl - is rather convoluted, and |
106 | requires a build of miniperl_. |
55497cff |
107 | |
108 | after 5.003_07: |
109 | custom tmpfile and tmpname which may use $TMP, $TEMP. |
110 | all the calls to OS/2 API wrapped so that it is safe to use |
111 | them under DOS (may die(), though). |
112 | Tested that popen works under DOS with modified PDKSH and RSX. |
113 | File::Copy works under DOS. |
114 | MakeMaker modified to work under DOS (perlmain.c.tmp and sh -c true). |
72ea3524 |
115 | |
116 | after 5.003_08: |
117 | OS2::PrfDB exports symbols as documented; |
118 | should work on OS/2 2.1 again. |
119 | uses reliable signals when spawing. |
120 | do not use popen() any more - no intermediate shell unless needed. |
df3ef7a9 |
121 | |
122 | after 5.003_11: |
123 | Functions emx_{malloc,realloc,calloc,free} are exported from DLL. |
124 | get_sysinfo() bugs corrected (flags were not used and wrongly defined). |
44a8e56a |
125 | |
126 | after 5.003_20: |
127 | _isterm is substituted instead of isatty, s?random instead of srand. |
128 | `register' disabled if -DDEBUGGING and not AOUT build: stupid SD386. |
129 | 3-argument select() was stomping over memory. |
e29f6e02 |
130 | |
131 | after 5.003_21: |
132 | Can start scripts by executing 'dir/script' and |
133 | 'script.sh'. Form without extension will call shell only if |
134 | the specified file exists (will not look on path) (to prohibit |
135 | trying to run shell commands directly). - Needed by magic.t. |
aa689395 |
136 | |
137 | after 5.003_27: |
138 | ALTERNATE_SHEBANG="extproc " supported, thus options on this |
139 | line are processed (possibly twice). -S is made legal on such |
140 | a line. This -S -x is not needed any more. |
141 | perl.dll may be used from non-EMX programs (via PERL_SYS_INIT |
142 | - the caller should have valid variable "env" with |
143 | environment). Known problems: $$ does not work - is 0, waitpid |
144 | returns immediately, thus Perl cannot wait for completion of |
145 | started programs. |
d8c2d278 |
146 | |
367f3c24 |
147 | after 5.004_01: |
148 | flock emulation added (disable by setting env PERL_USE_FLOCK=0), |
149 | thanks to Rocco Caputo; |
150 | RSX bug with missing waitpid circomvented; |
151 | -S bug with full path with \ corrected. |
152 | |
d8c2d278 |
153 | before 5.004_02: |
154 | -S switch to perl enables a search with additional extensions |
155 | .cmd, .btm, .bat, .pl as well. This means that if you have |
156 | mycmd.pl or mycmd.bat on PATH, |
157 | perl -S mycmd |
158 | will work. Perl will also look in the current directory first. |
159 | Moreover, a bug with \; in PATH being non-separator is fixed. |
84902520 |
160 | |
fb73857a |
161 | after 5.004_03: |
162 | $^E tracks calls to CRT now. (May break if Perl masks some |
163 | changes to errno?) |
164 | $0 may be edited to longer lengths (at least under OS/2). |
165 | OS2::REXX->loads looks in the OS/2-ish fashion too. |
dd96f567 |
166 | |
91643db9 |
167 | after 5.004_04: |
168 | Default perl.exe was built with a shorter stack than expected. |
169 | Strip extensions DLLs too (unless debugging build). |
170 | ./os2.c being RO could stop cp. |
171 | When starting scripts, Perl will find them on path (using the same |
172 | extensions as for -S command-line switch). If it finds magic |
173 | `extproc ' or `#!' cookies, it will start the scripts directly. |
174 | May use `cmd /c more <' as a pager. |
175 | If a program could not be started, this might have been hidden. |
176 | End of pipe was closed twice when `open'ing a pipeline. |
177 | |
dd96f567 |
178 | after 5.004_53: |
179 | Minimal thread support added. One needs to manually move pthread.h |
3aefca04 |
180 | |
181 | after 5.004_64: |
182 | Make DLL names different if thread-enabled. |
183 | Emit more informative internal DLL descriptions. |
2c2e0e8c |
184 | |
185 | 5.004_72: |
186 | Updated OS2::Process (v0.2) included. |
187 | |
188 | after 5.004_73: |
189 | Fixed a bug with argv not NULL-terminated when starting scripts. |
190 | Support all the forms of starting scripts. |
191 | Support killing a child when receiving a signal during system() |
192 | (in two stage, on first send the same signal, on the next |
193 | send SIGKILL). |
194 | Add the same logic for scripts as in pdksh, including |
195 | stripping the path from #! line if needed, |
196 | calling EXECSHELL or COMSPEC for magic-less scripts; |
197 | Now pdksh is called only if one-arg system()/friends contains |
198 | metachars, or if magic-line asks for sh, or there is no magic |
199 | line and EXECSHELL is set to sh. |
200 | Shell is supplied the original command line if possible. |
017f25f1 |
201 | |
202 | after 5.005_02: |
203 | Can start PM programs from non-PM sessions by plain system() |
204 | and friends. Can start DOS/Win programs. Can start |
205 | fullscreen programs from non-fullscreen sessions too. |
206 | In fact system(P_PM,...) was broken. |
207 | We mangle the name of perl*.DLL, to allow coexistence of different |
208 | versions of Perl executables on the system. Mangling of |
209 | names of extension DLL is also changed, thus running two |
210 | different versions of the executable with loaded |
211 | extensions should not lead to conflicts (since |
212 | extension-full-name and Perl-version mangling work in the |
213 | same set ot 576 possible keys, this may lead to clashes). |
214 | $^E was reset on the second read, and contained ".\r\n" at the end. |
4bfbfac5 |
215 | |
216 | after 5.005_53: |
e96326af |
217 | Would segfault system()ing non-existing program; |
218 | AOUT build was hosed; |
4bfbfac5 |
219 | warning-test for getpriority() might lock the system hard on |
220 | pre-fixpak22 configuration (calling getpriority() on |
221 | non-existing process triggers a system-wide bug). |
222 | |
4e3d4845 |
223 | |
224 | PrfDB was using a bug in processing XSUBs returning U32. |
225 | |
4bfbfac5 |
226 | Variable $OS2::emx_rev implemented (string and numberic values |
227 | are the same as C variables _emx_rev and _emx_vprt). |
228 | Variable $OS2::emx_env implemented (same as C variable _emx_env). |
229 | Variable $OS2::os_ver implemented (_osmajor + 0.001 * _osminor). |
230 | |
231 | Improved centralized management of HAB and HMQ. To get Perl's |
232 | HAB, call perl_hab_GET(). (After the initial call one |
233 | can use Perl_hab instead.) To require Perl's HMQ, |
234 | call perl_hmq_GET(), to release it call perl_hmq_UNSET(), |
235 | to obtain it between these calls use Perl_hmq. |
236 | HMQ management is refcounted, and the program will morph |
237 | itself into/from PM if required. |
238 | If perl.h cannot be included, hab may be obtained by Perl_hab_GET(). |
239 | |
240 | New function OS2::Error(do_harderror,do_exception). Returns |
241 | undef if it was not called yet, otherwise bit 1 is |
242 | set if on previous call do_harderror was enabled, bit |
243 | 2 is set if if on previous call do_exception was enabled. |
244 | This function enables/disables error popups associated with |
245 | hardware errors (Disk not ready etc.) and software exceptions. |
246 | |
247 | New function OS2::Errors2Drive(drive). Returns undef if it was |
248 | not called yet, otherwise return false if Errors were |
249 | not requested to be written to a hard drive, or the |
250 | drive letter if this was requested. |
251 | This function may redirect error popups associated with |
252 | hardware errors (Disk not ready etc.) and software exceptions |
253 | to the file POPUPLOG.OS2 at the root directory of the |
254 | specified drive. Overrides OS2::Error() specified by |
255 | individual programs. Given argument undef will |
256 | disable redirection. Has global effect, persists |
257 | after the application exits. |
258 | |
259 | New function OS2::SysInfo(). Returns a hash with system information. |
260 | The keys of the hash are |
261 | |
262 | MAX_PATH_LENGTH, MAX_TEXT_SESSIONS, MAX_PM_SESSIONS, |
263 | MAX_VDM_SESSIONS, BOOT_DRIVE, DYN_PRI_VARIATION, |
264 | MAX_WAIT, MIN_SLICE, MAX_SLICE, PAGE_SIZE, |
265 | VERSION_MAJOR, VERSION_MINOR, VERSION_REVISION, |
266 | MS_COUNT, TIME_LOW, TIME_HIGH, TOTPHYSMEM, TOTRESMEM, |
267 | TOTAVAILMEM, MAXPRMEM, MAXSHMEM, TIMER_INTERVAL, |
268 | MAX_COMP_LENGTH, FOREGROUND_FS_SESSION, |
269 | FOREGROUND_PROCESS |
270 | |
271 | New function OS2::BootDrive(force). Returns a letter without colon. |
272 | |
273 | New functions OS2::MorphPM(serve)/OS2::UnMorphPM(serve). Transforms |
274 | the current application into a PM application and back. |
275 | The argument true means that a real message loop is |
276 | going to be performed. |
277 | OS2::MorphPM() returns the PM message queue handle as an integer. |
278 | |
279 | New function OS2::Serve_Messages(force). Fake on-demand |
280 | retrieval of outstanding PM messages. If force is false, |
281 | will not dispatch messages if a real message loop is known to |
282 | be present. Returns number of messages retrieved. |
283 | Dies with "QUITing..." if WM_QUIT message is obtained. |
284 | |
285 | New function OS2::Process_Messages(force [, cnt]). Retrieval |
286 | of PM messages until window creation/destruction. |
287 | If force is false, will not dispatch messages |
288 | if a real message loop is known to be present. |
289 | Returns change in number of windows. If cnt is given, |
290 | it is incremented by the number of messages retrieved. |
291 | Dies with "QUITing..." if WM_QUIT message is obtained. |
292 | |
5838269b |
293 | after 5.005_54: |
294 | Opening pipes from/to processes could fail if (un)appropriate |
295 | combination of STDIN/STDOUT was closed. |
296 | |
297 | If the only shell-metachars of a command are ' 2>&1' at the |
298 | end of a command, it is executed without calling the external shell. |
ed344e4f |
299 | |
300 | after 5.005_57: |
301 | Make UDP sockets return correct caller address (OS2 API bug); |
302 | Enable TCPIPV4 defines (works with Warp 3 IAK too?!); |
303 | Force Unix-domain sockets to start with "/socket", convert |
304 | '/' to '\' in the calls; |
305 | Make C<system 1, $cmd> to treat $cmd as in C<system $cmd>; |
306 | Autopatch Configure; |
307 | Find name and location of g[nu]patch.exe; |
308 | Autocopy perl????.dll to t/ when testing; |
309 | |
310 | after 5.005_62: |
311 | Extract a lightweight DLL access module OS2::DLL from OS2::REXX |
312 | which would not load REXX runtime system; |
313 | Allow compile with os2.h which loads os2tk.h instead of os2emx.h; |
314 | Put the version of EMX CRTL into -D define; |
315 | Use _setsyserror() to store last error of OS/2 API for $^E; |
316 | New macro PERL_SYS_INIT3(argvp, argcp, envp); |
317 | Make Dynaloader return info on the failing module after failed dl_open(); |
318 | OS2::REXX test were done for interactive testing (were writing |
319 | "ok" to stderr); |
320 | system() and friends return -1 on failure (was 0xFF00); |
321 | Put the full name of executable into $^X |
322 | (alas, uppercased - but with /); |
323 | t/io/fs.t was failing on HPFS386; |
324 | Remove extra ';' from defines for MQ operations. |
9c130f5b |
325 | |
326 | pre 5.6.1: |
327 | Resolved: "Bad free()" messages (e.g., from DB_File) with -Zomf build. |
328 | The reason was: when an extension DLL was linked, the order of |
329 | libraries was similar to this: |
330 | f1.obj f2.obj libperl.lib -llibr1 -llibr2 |
331 | (with C RTL implicitly after this). When libperl.lib overrides |
332 | some C RTL functions, they are correctly resolved when mentioned |
333 | in f1.obj and f2.obj. However, the resolution for libr1.lib and |
334 | libr2.lib is implementation-dependent. |
335 | |
336 | With -Zomf linking the symbols are resolved for libr1.lib and |
337 | libr2.lib *only if* they reside in .obj-file-sections of libperl.lib |
338 | which were already "picked up" for symbols in f1.obj f2.obj. |
339 | However, libperl.lib is an import library for a .DLL, so *each |
340 | symbol in libperl.lib sits in its own pseudo-section*! |
341 | |
342 | Corollary: only those symbol from libperl.lib which were already |
343 | mentioned in f1.obj f2.obj would be used for libr1.lib and |
344 | libr2.lib. Example: if f1.obj f2.obj do not mention calloc() but |
345 | libr1.lib and libr2.lib do, then .lib's will get calloc() of C RTL, |
346 | not one of libperl.lib. |
347 | |
348 | Solution: create a small duplicate of libperl.lib with overriding |
349 | symbols only. Put it *after* -llibr1 -llibr2 on the link line. |
350 | Map strdup() and putenv() to Perl_strdup() and Perl_putenv() |
351 | inside this library. |
352 | |
353 | Resolved: rmdir() and mkdir() do not accept trailing slashes. |
354 | Wrappers are implemented. |
355 | Resolved: when loading modules, FP mask may be erroneously changed by |
356 | _DLLInitTerm() (e.g., TCP32IP). |
357 | Solutions: a) dlopen() saves/restores the FP mask. |
358 | b) When starting, reset FP mask to a sane value |
359 | (if the DLL was compile-time linked). |
360 | New functions in package OS2: |
361 | unsigned _control87(unsigned new,unsigned mask) # as in EMX |
362 | unsigned get_control87() |
363 | # with default values good for handling exception mask: |
364 | unsigned set_control87_em(new=MCW_EM,mask=MCW_EM) |
365 | Needed to guard against other situations when the FP mask is |
366 | stompted upon. Apparently, IBM used a compiler (for some period |
367 | of time around '95?) which changes FP mask right and left... |
368 | Resolved: $^X was always uppercased (cosmetic). Solution: |
369 | use argv[0] if it differs from what the OS returns only in case. |
370 | Resolved: when creating PM message queues, WinCancelShutdown() was |
371 | not called even if the application said that it would not serve |
372 | messages in this queue. Could result in PM refusing to shutdown. |
373 | |
374 | Solution: resolve WinCancelShutdown at run time, keep the refcount |
375 | of who is going to serve the queue. |
376 | Resolved: Perl_Deregister_MQ() segfaulted (pid/tid not initialized). |
377 | Resolved: FillWinError() would not fetch the error. |
378 | Solution: resolve WinGetLastError at run time, call it. |
379 | Resolved: OS2::REXX would ignore arguments given to a Perl function |
380 | imported into the REXX compartment via REXX_eval_with(). |
381 | Resolved: OS2::REXX would treat arguments given to a Perl function |
382 | imported into the REXX compartment via _register() as ASCIIZ |
383 | strings inside of binary strings. |
384 | Resolved: OS2::REXX did not document _register(). |
385 | Resolved: OS2::REXX would not report the error to REXX if an error |
386 | condition appeared during a call to Perl function from REXX |
387 | compartment. As a result, the return string was not initialized. |
388 | A complete example of a mini-application added to OS2::REXX. |
389 | |