1PERLQNX(1)             Perl Programmers Reference Guide             PERLQNX(1)
2
3
4

NAME

6       perlqnx - Perl version 5 on QNX
7

DESCRIPTION

9       As of perl5.7.2 all tests pass under:
10
11         QNX 4.24G
12         Watcom 10.6 with Beta/970211.wcc.update.tar.F
13         socket3r.lib Nov21 1996.
14
15       As of perl5.8.1 there is at least one test still failing.
16
17       Some tests may complain under known circumstances.
18
19       See below and hints/qnx.sh for more information.
20
21       Under QNX 6.2.0 there are still a few tests which fail.  See below and
22       hints/qnx.sh for more information.
23
24   Required Software for Compiling Perl on QNX4
25       As with many unix ports, this one depends on a few "standard" unix
26       utilities which are not necessarily standard for QNX4.
27
28       /bin/sh
29           This is used heavily by Configure and then by perl itself. QNX4's
30           version is fine, but Configure will choke on the 16-bit version, so
31           if you are running QNX 4.22, link /bin/sh to /bin32/ksh
32
33       ar  This is the standard unix library builder.  We use wlib. With
34           Watcom 10.6, when wlib is linked as "ar", it behaves like ar and
35           all is fine. Under 9.5, a cover is required. One is included in
36           ../qnx
37
38       nm  This is used (optionally) by configure to list the contents of
39           libraries. I will generate a cover function on the fly in the UU
40           directory.
41
42       cpp Configure and perl need a way to invoke a C preprocessor. I have
43           created a simple cover for cc which does the right thing. Without
44           this, Configure will create its own wrapper which works, but it
45           doesn't handle some of the command line arguments that perl will
46           throw at it.
47
48       make
49           You really need GNU make to compile this. GNU make ships by default
50           with QNX 4.23, but you can get it from quics for earlier versions.
51
52   Outstanding Issues with Perl on QNX4
53       There is no support for dynamically linked libraries in QNX4.
54
55       If you wish to compile with the Socket extension, you need to have the
56       TCP/IP toolkit, and you need to make sure that -lsocket locates the
57       correct copy of socket3r.lib. Beware that the Watcom compiler ships
58       with a stub version of socket3r.lib which has very little
59       functionality. Also beware the order in which wlink searches
60       directories for libraries. You may have /usr/lib/socket3r.lib pointing
61       to the correct library, but wlink may pick up
62       /usr/watcom/10.6/usr/lib/socket3r.lib instead. Make sure they both
63       point to the correct library, that is,
64       /usr/tcptk/current/usr/lib/socket3r.lib.
65
66       The following tests may report errors under QNX4:
67
68       dist/Cwd/Cwd.t will complain if `pwd` and cwd don't give the same
69       results. cwd calls `fullpath -t`, so if you cd `fullpath -t` before
70       running the test, it will pass.
71
72       lib/File/Find/taint.t will complain if '.' is in your PATH. The PATH
73       test is triggered because cwd calls `fullpath -t`.
74
75       ext/IO/lib/IO/t/io_sock.t: Subtests 14 and 22 are skipped due to the
76       fact that the functionality to read back the non-blocking status of a
77       socket is not implemented in QNX's TCP/IP. This has been reported to
78       QNX and it may work with later versions of TCP/IP.
79
80       t/io/tell.t: Subtest 27 is failing. We are still investigating.
81
82   QNX auxiliary files
83       The files in the "qnx" directory are:
84
85       qnx/ar
86           A script that emulates the standard unix archive (aka library)
87           utility.  Under Watcom 10.6, ar is linked to wlib and provides the
88           expected interface. With Watcom 9.5, a cover function is required.
89           This one is fairly crude but has proved adequate for compiling
90           perl.
91
92       qnx/cpp
93           A script that provides C preprocessing functionality.  Configure
94           can generate a similar cover, but it doesn't handle all the
95           command-line options that perl throws at it. This might be
96           reasonably placed in /usr/local/bin.
97
98   Outstanding issues with perl under QNX6
99       The following tests are still failing for Perl 5.8.1 under QNX 6.2.0:
100
101         op/sprintf.........................FAILED at test 91
102         lib/Benchmark......................FAILED at test 26
103
104       This is due to a bug in the C library's printf routine.  printf("'%e'",
105       0. ) produces '0.000000e+0', but ANSI requires '0.000000e+00'. QNX has
106       acknowledged the bug.
107
108   Cross-compilation
109       Perl supports cross-compiling to QNX NTO through the Native Development
110       Kit (NDK) for the Blackberry 10.  This means that you can cross-compile
111       for both ARM and x86 versions of the platform.
112
113       Setting up a cross-compilation environment
114
115       You can download the NDK from
116       <http://developer.blackberry.com/native/downloads/>.
117
118       See
119       <http://developer.blackberry.com/native/documentation/cascades/getting_started/setting_up.html>
120       for instructions to set up your device prior to attempting anything
121       else.
122
123       Once you've installed the NDK and set up your device, all that's left
124       to do is setting up the device and the cross-compilation environment.
125       Blackberry provides a script, "bbndk-env.sh" (occasionally named
126       something like "bbndk-env_10_1_0_4828.sh") which can be used to do
127       this.  However, there's a bit of a snag that we have to work through:
128       The script modifies PATH so that 'gcc' or 'ar' point to their cross-
129       compilation equivalents, which screws over the build process.
130
131       So instead you'll want to do something like this:
132
133           $ orig_path=$PATH
134           $ source $location_of_bbndk/bbndk-env*.sh
135           $ export PATH="$orig_path:$PATH"
136
137       Besides putting the cross-compiler and the rest of the toolchain in
138       your PATH, this will also provide the QNX_TARGET variable, which we
139       will pass to Configure through -Dsysroot.
140
141       Preparing the target system
142
143       It's quite possible that the target system doesn't have a readily
144       available /tmp, so it's generall safer to do something like this:
145
146        $ ssh $TARGETUSER@$TARGETHOST 'rm -rf perl; mkdir perl; mkdir perl/tmp'
147        $ export TARGETDIR=`ssh $TARGETUSER@$TARGETHOST pwd`/perl
148        $ export TARGETENV="export TMPDIR=$TARGETDIR/tmp; "
149
150       Later on, we'll pass this to Configure through -Dtargetenv
151
152       Calling Configure
153
154       If you are targetting an ARM device -- which currently includes the
155       vast majority of phones and tablets -- you'll want to pass
156       -Dcc=arm-unknown-nto-qnx8.0.0eabi-gcc to Configure.  Alternatively, if
157       you are targetting an x86 device, or using the simulator provided with
158       the NDK, you should specify -Dcc=ntox86-gcc instead.
159
160       A sample Configure invocation looks something like this:
161
162           ./Configure -des -Dusecrosscompile \
163               -Dsysroot=$QNX_TARGET          \
164               -Dtargetdir=$TARGETDIR         \
165               -Dtargetenv="$TARGETENV"       \
166               -Dcc=ntox86-gcc                \
167               -Dtarghost=... # Usual cross-compilation options
168

AUTHOR

170       Norton T. Allen (allen@huarp.harvard.edu)
171
172
173
174perl v5.30.1                      2019-11-29                        PERLQNX(1)
Impressum