Mercurial > flash_v2
comparison host/README @ 76:435cced73e2f ecos-v1_3_1-release
eCos v1.3.1 merged from eCos master repository on 2000-03-27-23:22:51-BST
| author | jlarmour |
|---|---|
| date | Tue, 28 Mar 2000 14:10:45 +0000 |
| parents | |
| children | 518f42066aba |
comparison
equal
deleted
inserted
replaced
| 75:41bf073c0c32 | 76:435cced73e2f |
|---|---|
| 1 eCos Host-side Software | |
| 2 ======================= | |
| 3 | |
| 4 This directory contains the eCos host-side sources. This includes | |
| 5 libcdl, the CDL library which underlies the whole eCos configuration | |
| 6 system, and both the command-line and graphical configuration tools. | |
| 7 | |
| 8 The eCos host-side software is free software, released under the GNU | |
| 9 General Public License. See the file COPYING for further details. | |
| 10 | |
| 11 | |
| 12 Contents | |
| 13 ======== | |
| 14 | |
| 15 The host-side sources include the following: | |
| 16 | |
| 17 infra/ | |
| 18 This is an implementation of the eCos infrastructure that can be | |
| 19 used on the host-side, and provides assertion, tracing and | |
| 20 testcase support. | |
| 21 | |
| 22 NOTE: the eCos infrastructure facilities are not especially | |
| 23 well-suited to host-side development, in particular they are not | |
| 24 C++-oriented. There are plans to remove the current infrastructure | |
| 25 completely and replace it with something more suitable. People | |
| 26 planning new projects should be aware of this, and may wish to | |
| 27 avoid using the current infrastructure. | |
| 28 | |
| 29 libcdl/ | |
| 30 The CDL library lies at the heart of the eCos configuration system. | |
| 31 | |
| 32 tools/configtool/ | |
| 33 The sources to the various configuration tools can be found here. | |
| 34 In particular the command line ecosconfig tool lives in | |
| 35 tools/configtool/standalone/common; the sources related to | |
| 36 makefile generation currently live in | |
| 37 tools/configtool/common/common, and the graphical configuration | |
| 38 tool is spread over various directories including | |
| 39 tools/configtool/common/win32 and tools/configtool/standalone/win32 | |
| 40 | |
| 41 There are various other sub-directories related to the admin tool, | |
| 42 testing support, and so on. | |
| 43 | |
| 44 It should be noted that the eCos host-side software is still | |
| 45 undergoing rapid development, and the sources are subject to change | |
| 46 and reorganization at any time. | |
| 47 | |
| 48 Much of the code is cross-platform. The obvious exception is the | |
| 49 graphical configuration tool which, at the time of writing, can only | |
| 50 be built for Windows hosts and requires Visual C++. It should be | |
| 51 possible to build the underlying libraries and the command-line | |
| 52 configuration tool using gcc/g++ on any Unix platform. A Unix version | |
| 53 of the graphical configuration tool is planned but not yet available. | |
| 54 | |
| 55 More Information | |
| 56 ================ | |
| 57 | |
| 58 Please see the eCos web site, http://sourceware.cygnus.com/ecos/, for | |
| 59 further details. This includes the FAQ, a form for reporting problems, | |
| 60 and details of the various mailing lists | |
| 61 (http://sourceware.cygnus.com/ecos/intouch.html) | |
| 62 At the time of writing there are no separate mailing lists for the | |
| 63 eCos host-side sources, the main mailing list | |
| 64 ecos-discuss@sourceware.cygnus.com should be used instead. | |
| 65 | |
| 66 | |
| 67 Installation | |
| 68 ============ | |
| 69 | |
| 70 Test builds of the eCos host-side generally happen on the following | |
| 71 platforms: Red Hat Linux 6.1 and later; Windows NT using cygwin 1.0 or | |
| 72 later; and Windows NT using VC++ 6.0. The graphical configuration tool | |
| 73 can only be built with VC++ and involves a Developer Studio project, | |
| 74 see tools/configtool/standalone/win32/Configtool.dsw. The other | |
| 75 software can be built using the conventional "configure/make/make | |
| 76 install" steps. It should be noted that the eCos host-side software is | |
| 77 not fully auto-confiscated, and some facilities like "make dist" will | |
| 78 not work. Also, the existing DejaGnu-based testing facilities are | |
| 79 minimal, only intended as a starting point, and may not work on all | |
| 80 platforms. | |
| 81 | |
| 82 The eCos host-side software has a dependency on Tcl. This is not | |
| 83 supplied with the sources, because many users will already have a | |
| 84 suitable installation. Any release of Tcl from 8.0 onwards should be | |
| 85 usable. There are some configure command-line options related to the | |
| 86 Tcl installation, as described below. | |
| 87 | |
| 88 The instructions for installing under Linux are given first. | |
| 89 Installation on other platforms is very similar, so only the | |
| 90 differences will be noted. | |
| 91 | |
| 92 Installing on Linux | |
| 93 =================== | |
| 94 | |
| 95 It is strongly recommended that a separate build tree is used, as | |
| 96 opposed to building directly in the source tree. The latter has not | |
| 97 been tested and, given some of the build steps, may not work very | |
| 98 well. | |
| 99 | |
| 100 $ mkdir build | |
| 101 $ cd build | |
| 102 | |
| 103 The next step is to run the toplevel configure script. It might be | |
| 104 possible to configure and build individual directories within the | |
| 105 host-side hierarchy, but again this has not been tested. | |
| 106 | |
| 107 $ <path>/configure <args> | |
| 108 | |
| 109 A list of the all the command-line options can be obtained by running | |
| 110 "configure --help". The most important ones are as follows: | |
| 111 | |
| 112 1) --prefix. This can be used to specify the location of the install | |
| 113 tree, defaulting to /usr/local, so the ecosconfig program ends up | |
| 114 in /usr/local/bin/ecosconfig and the CDL library ends up in | |
| 115 /usr/local/lib/libcdl.a. If an alternative location is preferred | |
| 116 this can be specified with --prefix, for example: | |
| 117 | |
| 118 $ <path>/configure --prefix=/usr/local/ecos <args> | |
| 119 | |
| 120 2) --enable-debug. By default all assertions and tracing are disabled. | |
| 121 When debugging any of the host-side software these must be enabled. | |
| 122 | |
| 123 $ <path>/configure --enable-debug | |
| 124 | |
| 125 It is also possible to control most of the assertion and tracing | |
| 126 macros at a finer grain. This is likely to be useful only to the | |
| 127 main developers: | |
| 128 | |
| 129 --disable-asserts disable all assertions | |
| 130 --disable-preconditions disable a subset of the assertions | |
| 131 --disable-postconditions disable a subset of the assertions | |
| 132 --disable-invariants disable a subset of the assertions | |
| 133 --disable-loopinvariants disable a subset of the assertions | |
| 134 --disable-tracing disable tracing | |
| 135 --disable-fntracing disable function entry/exit tracing | |
| 136 | |
| 137 3) --with-tcl=<path> and --with-tcl-version=<number> | |
| 138 The host-side tools have a dependency on Tcl, which is not supplied | |
| 139 with the sources because many people will already have a suitable | |
| 140 installation. Specifically it is necessary to have the header file | |
| 141 tcl.h and appropriate libraries such that -ltcl will work - this | |
| 142 can involve either static or shared libraries. | |
| 143 | |
| 144 By default the configure script will assume that there is a | |
| 145 suitable Tcl installation in the install location, so if there is | |
| 146 no --prefix argument then it will look for /usr/local/include/tcl.h | |
| 147 and it will add -L/usr/local/lib to the library search path. If | |
| 148 Tcl is installed elsewhere then this can be specified with a | |
| 149 --with-tcl option. For example, if the default installation in | |
| 150 /usr should be used then the following configure option is | |
| 151 appropriate: | |
| 152 | |
| 153 $ <path>/configure --with-tcl=/usr <args> | |
| 154 | |
| 155 It is possible to have multiple versions of Tcl installed, for | |
| 156 example libtcl8.0.a, libtcl8.1.a, and so on. Typically linking with | |
| 157 -ltcl will result in the latest version being used. It is possible | |
| 158 to specify a different version using --with-tcl-version, e.g.: | |
| 159 | |
| 160 $ <path>configure --with-tcl=/usr/local/scriptics --with-tcl-version=8.1 <args> | |
| 161 | |
| 162 Following the configure step the build tree should be set up | |
| 163 correctly. All that remains is the actual build and install: | |
| 164 | |
| 165 $ make | |
| 166 $ make install | |
| 167 | |
| 168 This should result in an ecosconfig executable, plus appropriate | |
| 169 libraries and header files. | |
| 170 | |
| 171 | |
| 172 Installing on cygwin | |
| 173 ==================== | |
| 174 | |
| 175 Installing under cygwin requires essentially the same steps as | |
| 176 under Linux. It is more likely that a suitable --prefix option will | |
| 177 have to be used, and that the location of the Tcl installation needs | |
| 178 to be specified with --with-tcl. However appropriate use of cygwin | |
| 179 mount points may avoid some of these problems. If the full path to | |
| 180 the configure script contains spaces, then the short form of the path | |
| 181 should be used when invoking configure. | |
| 182 | |
| 183 One issue to be aware of is the naming convention for the Tcl library. | |
| 184 On a Unix system this will typically be called libtcl8.0.a (adjusted | |
| 185 according to the version number), with a symbolic link from libtcl.a | |
| 186 to the most recent version. Under cygwin the equivalent library is | |
| 187 called libtcl80.a, and symbolic links are not used. For a standard | |
| 188 cygwin 1.0 installation the configure script knows how to pick up the | |
| 189 appropriate library, but if a more recent version of Tcl has been | |
| 190 installed then due care has to be taken with the --with-tcl-version | |
| 191 option. | |
| 192 | |
| 193 | |
| 194 Installing on NT with VC++ | |
| 195 ========================== | |
| 196 | |
| 197 It is possible to build both the graphical configuration tool and the | |
| 198 ecosconfig command line tool using a Developer Studio project, | |
| 199 tools/ecosconfig/standalone/win32/Configtool.dsw | |
| 200 | |
| 201 It is also possible to build the command line tool and the various | |
| 202 libraries using the configure script. At the time of writing the | |
| 203 graphical configuration tool cannot yet be built that way. This still | |
| 204 requires a cygwin installation because it needs the bash shell and GNU | |
| 205 make. First, it is necessary to tell the configure script to use a | |
| 206 compiler other than gcc: | |
| 207 | |
| 208 $ mkdir build | |
| 209 $ cd build | |
| 210 $ CC=cl CXX=cl <path>/configure <args> | |
| 211 | |
| 212 The configure script will do the right thing if VC++ is specified in | |
| 213 this way. | |
| 214 | |
| 215 It is likely that /usr/local will be an inappropriate install location | |
| 216 for VC++ applications, so an alternative prefix needs to be specified: | |
| 217 | |
| 218 $ CC=cl CXX=cl <path>/configure --prefix=<install-path> <args> | |
| 219 | |
| 220 Note that the install path should be a cygwin path, i.e. cygwin mount | |
| 221 points are accepted and forward slashes should be used. | |
| 222 | |
| 223 It is also necessary to use the right version of Tcl. For a VC++ build | |
| 224 the cygwin release of Tcl should not be used. Instead a suitable | |
| 225 prebuilt Tcl package can be obtained from http://www.scriptics.com/. | |
| 226 It is necessary to tell the configure script where this has been | |
| 227 installed, for example: | |
| 228 | |
| 229 $ CC=cl CXX=cl <path>/configure --prefix=<install-path> \ | |
| 230 --with-tcl=/d/local/scriptics/Tcl/tcl8.1 <args> | |
| 231 | |
| 232 The library name will be of the form tcl81.lib, and there will not be | |
| 233 a symbolic link from tcl.lib to the appropriate version. Typically it | |
| 234 will be necessary to specify the Tcl version explicitly: | |
| 235 | |
| 236 $ CC=cl CXX=cl <path>/configure --prefix=<install-path> \ | |
| 237 --with-tcl=/d/local/scriptics/Tcl/tcl8.1 --with-tcl-version=81 <args> | |
| 238 | |
| 239 Following a successful configure, the tools can be built and installed | |
| 240 in the normal fashion: | |
| 241 | |
| 242 $ make | |
| 243 $ make install | |
| 244 | |
| 245 This assumes that the cl.exe executable is on the shell's search path, | |
| 246 and that appropriate environment variables such as INCLUDE and LIB are | |
| 247 set up correctly. The VC++ documentation should be consulted for | |
| 248 further information. | |
| 249 | |
| 250 | |
| 251 //####COPYRIGHTBEGIN#### | |
| 252 // | |
| 253 // ---------------------------------------------------------------------------- | |
| 254 // Copyright (C) 2000 Red Hat, Inc. | |
| 255 // | |
| 256 // This file is part of the eCos host tools. | |
| 257 // | |
| 258 // This program is free software; you can redistribute it and/or modify it | |
| 259 // under the terms of the GNU General Public License as published by the Free | |
| 260 // Software Foundation; either version 2 of the License, or (at your option) | |
| 261 // any later version. | |
| 262 // | |
| 263 // This program is distributed in the hope that it will be useful, but WITHOUT | |
| 264 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
| 265 // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | |
| 266 // more details. | |
| 267 // | |
| 268 // You should have received a copy of the GNU General Public License along with | |
| 269 // this program; if not, write to the Free Software Foundation, Inc., | |
| 270 // 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | |
| 271 // | |
| 272 // ---------------------------------------------------------------------------- | |
| 273 // | |
| 274 //####COPYRIGHTEND#### |
