VirtualBox

source: kBuild/trunk/src/gmakenew/README.OS2.template@ 925

Last change on this file since 925 was 903, checked in by bird, 18 years ago

Merged with the 2007-05-23 CVS. Added rsort and fixed a couple of windows build issues.

File size: 6.6 KB
Line 
1Port of GNU make to OS/2.
2
3Features of GNU make that do not work under OS/2:
4 - remote job execution
5 - dynamic load balancing
6
7
8Special features of the OS/2 version:
9
10Due to the fact that some people might want to use sh syntax in
11Makefiles while others might want to use OS/2's native shell cmd.exe,
12GNU make supports both shell types. The following list defines the order
13that is used to determine the shell:
14
15 1. The shell specified by the environment variable MAKESHELL.
16 2. The shell specified by the SHELL variable within a Makefile. Like
17 Unix, SHELL is NOT taken from the environment.
18 3. The shell specified by the COMSPEC environment variable.
19 4. The shell specified by the OS2_SHELL environment variable.
20 5. If none of the above is defined /bin/sh is used as default. This
21 happens e.g. in the make testsuite.
22
23Note: - Points 3 and 4 can be turned off at compile time by adding
24 -DNO_CMD_DEFAULT to the CPPFLAGS.
25 - DOS support is not tested for EMX and therefore might not work.
26 - The UNIXROOT environment variable is supported to find /bin/sh
27 if it is not on the current drive.
28
29
30COMPILATION OF GNU MAKE FOR OS/2:
31
32I. ***** SPECIAL OPTIONS *****
33
34 - At compile time you can turn off that cmd is used as default shell
35 (but only /bin/sh). Simply set CPPFLAGS="-DNO_CMD_DEFAULT" and make
36 will not use cmd unless you cause it to do so by setting MAKESHELL to
37 cmd or by specifying SHELL=cmd in your Makefile.
38
39 - At compile time you can set CPPFLAGS="-DNO_CHDIR2" to turn off that
40 GNU make prints drive letters. This is necessary if you want to run
41 the testsuite.
42
43
44II. ***** REQUIREMENTS FOR THE COMPILATION *****
45
46A standard Unix like build environment:
47
48 - sh compatible shell (ksh, bash, ash, but tested only with pdksh 5.2.14
49 release 2)
50 If you use pdksh it is recommended to update to 5.2.14 release 2. Older
51 versions may not work! You can get this version at
52 http://www.math.ohio-state.edu/~ilya/software/os2/pdksh-5.2.14-bin-2.zip
53 - GNU file utilities (make sure that install.exe from the file utilities
54 is in front of your PATH before X:\OS2\INSTALL\INSTALL.EXE. I recommend
55 also to change the filename to ginstall.exe instead of install.exe
56 to avoid confusion with X:\OS2\INSTALL\INSTALL.EXE)
57 - GNU shell utilities
58 - GNU text utilities
59 - gawk
60 - grep
61 - sed
62 - GNU make 3.79.1 (special OS/2 patched version) or higher
63 - perl 5.005 or higher
64 - GNU texinfo (you can use 3.1 (gnuinfo.zip), but I recommend 4.0)
65
66If you want to recreate the configuration files (developers only!)
67you need also: GNU m4 1.4, autoconf 2.59, automake 1.9.6 (or compatible)
68
69
70III. ***** COMPILATION AND INSTALLATION *****
71
72 a) ** Developers only - Everyone else should skip this section **
73 To recreate the configuration files use:
74
75 export EMXSHELL=ksh
76 aclocal -I config
77 automake
78 autoconf
79 autoheader
80
81
82b) Installation into x:/usr
83
84 Note: Although it is possible to compile make using "./configure",
85 "make", "make install" this is not recommended. In particular,
86 you must ALWAYS use LDFLAGS="-Zstack 0x6000" because the default
87 stack size is far to small and make will not work properly!
88
89Recommended environment variables and installation options:
90
91 export ac_executable_extensions=".exe"
92 export CPPFLAGS="-D__ST_MT_ERRNO__"
93 export CFLAGS="-O2 -Zomf -Zmt"
94 export LDFLAGS="-Zcrtdll -Zlinker /exepack:2 -Zlinker /pm:vio -Zstack 0x6000"
95 export RANLIB="echo"
96 ./configure --prefix=x:/usr --infodir=x:/usr/share/info --mandir=x:/usr/share/man --without-included-gettext
97 make AR=emxomfar
98 make install
99
100Note: If you use gcc 2.9.x I recommend to set also LIBS="-lgcc"
101
102Note: You can add -DNO_CMD_DEFAULT and -DNO_CHDIR2 to CPPFLAGS.
103 See section I. for details.
104
105
106IV. ***** NLS support *****
107
108GNU make has NLS (National Language Support), with the following
109caveats:
110
111 a) It will only work with GNU gettext, and
112 b) GNU gettext support is not included in the GNU make package.
113
114Therefore, if you wish to enable the internationalization features of
115GNU make you must install GNU gettext on your system before configuring
116GNU make.
117
118You can choose the languages to be installed. To install support for
119English, German and French only enter:
120
121 export LINGUAS="en de fr"
122
123If you don't specify LINGUAS all languages are installed.
124
125If you don't want NLS support (English only) use the option
126--disable-nls for the configure script. Note if GNU gettext is not
127installed then NLS will not be enabled regardless of this flag.
128
129
130V. ***** Running the make test suite *****
131
132To run the included make test suite you have to set
133
134 CPPFLAGS="-D__ST_MT_ERRNO__ -DNO_CMD_DEFAULT -DNO_CHDIR2"
135
136before you compile make. This is due to some restrictions of the
137testsuite itself. -DNO_CMD_DEFAULT causes make to use /bin/sh as default
138shell in every case. Normally you could simply set MAKESHELL="/bin/sh"
139to do this but the testsuite ignores the environment. -DNO_CHDIR2 causes
140make not to use drive letters for directory names (i.e. _chdir2() and
141_getcwd2() are NOT used). The testsuite interpretes the whole output of
142make, especially statements like make[1]: Entering directory
143`C:/somewhere/make-3.79.1/tests' where the testsuite does not expect the
144drive letter. This would be interpreted as an error even if there is
145none.
146
147To run the testsuite do the following:
148
149 export CPPFLAGS="-D__ST_MT_ERRNO__ -DNO_CMD_DEFAULT -DNO_CHDIR2"
150 export CFLAGS="-Zomf -O2 -Zmt"
151 export LDFLAGS="-Zcrtdll -s -Zlinker /exepack:2 -Zlinker /pm:vio -Zstack 0x6000"
152 export RANLIB="echo"
153 ./configure --prefix=x:/usr --disable-nls
154 make AR=emxomfar
155 make check
156
157All tests should work fine with the exception of one of the "INCLUDE_DIRS"
158tests which will fail if your /usr/include directory is on a drive different
159from the make source tree.
160
161
162
163-------------------------------------------------------------------------------
164Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
165This file is part of GNU Make.
166
167GNU Make is free software; you can redistribute it and/or modify it under the
168terms of the GNU General Public License as published by the Free Software
169Foundation; either version 2, or (at your option) any later version.
170
171GNU Make is distributed in the hope that it will be useful, but WITHOUT ANY
172WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
173A PARTICULAR PURPOSE. See the GNU General Public License for more details.
174
175You should have received a copy of the GNU General Public License along with
176GNU Make; see the file COPYING. If not, write to the Free Software
177Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette