Expand PMF_FN_* macros.
[netbsd-mini2440.git] / external / bsd / atf / dist / doc / standalone / install.html
blobbe5ab1d8957ffdcde2e8aa99ad4acf3b53ec5c45
1 <?xml version="1.0"?>
2 <html xmlns="http://www.w3.org/1999/xhtml">
3 <head>
4 <meta xmlns="" http-equiv="Content-Type"
5 content="text/html; charset=iso-8859-1" />
6 <link xmlns="" rel="made"
7 href="mailto:atf-devel AT NetBSD DOT org" />
8 <link xmlns="" rel="stylesheet" type="text/css"
9 href="standalone.css" />
10 <title xmlns="">Installation instructions</title>
11 </head>
12 <body>
13 <div xmlns="" class="header">
14 <p class="title">Installation instructions</p>
15 <p class="author">By Julio Merino, The NetBSD Foundation</p>
16 </div>
17 <div xmlns="" class="toc">
18 <h1>Contents</h1>
19 <ol>
20 <li>
21 <p>
22 <a href="#introduction">Introduction</a>
23 </p>
24 </li>
25 <li>
26 <p>
27 <a href="#">Dependencies</a>
28 </p>
29 </li>
30 <li>
31 <p>
32 <a href="#">Regenerating the build system</a>
33 </p>
34 </li>
35 <li>
36 <p>
37 <a href="#">General build procedure</a>
38 </p>
39 </li>
40 <li>
41 <p>
42 <a href="#">Configuration flags</a>
43 </p>
44 </li>
45 <li>
46 <p>
47 <a href="#">Post-installation steps</a>
48 </p>
49 </li>
50 </ol>
51 </div>
52 <div xmlns="" class="contents">
53 <h1>
54 <a name="introduction">Introduction</a>
55 </h1>
56 <p xml:space="preserve">
57 ATF uses the GNU Automake, GNU Autoconf and GNU Libtool utilities
59 its build system. These are used only when compiling the
60 application from
61 the source code package. If you want to install ATF from a binary
62 package,
63 you do not need to read this document.
64 </p>
65 <p xml:space="preserve">
66 For the impatient:
67 </p>
68 <pre class="screen">
69 $ ./configure
70 $ make
71 Gain root privileges
72 # make install
73 Drop root privileges
74 $ make installcheck
75 </pre>
76 <p xml:space="preserve">
77 Or alternatively, install as a regular user into your home
78 directory:
79 </p>
80 <pre class="screen">
81 $ ./configure --prefix ~/local
82 $ make
83 $ make install
84 $ make installcheck
85 </pre>
86 <h1>
87 <a name="">Dependencies</a>
88 </h1>
89 <p xml:space="preserve">
90 To build and use ATF successfully you need:
91 </p>
92 <ul>
93 <li>
94 <p xml:space="preserve">
95 A standards-compliant C/C++ complier. For example, GNU GCC
96 2.95 will not work.
97 </p>
98 </li>
99 <li>
100 <p xml:space="preserve">
101 A POSIX shell interpreter.
102 </p>
103 </li>
104 <li>
105 <p xml:space="preserve">
106 A make(1) utility.
107 </p>
108 </li>
109 </ul>
110 <p xml:space="preserve">
111 If you are building ATF from the code on the repository, you will
112 also need
113 the following tools. The versions listed here are the ones used to
114 build
115 the files bundled in the last formal release, but these are not
116 strictly
117 required. Newer ones will most likely work and, maybe, some
118 slightly older
119 ones:
120 </p>
121 <ul>
122 <li>
123 <p xml:space="preserve">
124 GNU autoconf 2.65
125 </p>
126 </li>
127 <li>
128 <p xml:space="preserve">
129 GNU automake 1.11.1
130 </p>
131 </li>
132 <li>
133 <p xml:space="preserve">
134 GNU libtool 2.2.6b
135 </p>
136 </li>
137 </ul>
138 <p xml:space="preserve">
139 If you are building the XML documentation (which is a requisite to
140 be able
141 to generate a distfile), you will also need the following tools:
142 </p>
143 <ul>
144 <li>
145 <p xml:space="preserve">
146 links
147 </p>
148 </li>
149 <li>
150 <p xml:space="preserve">
151 The Simple DocBook DTD 1.1
152 </p>
153 </li>
154 <li>
155 <p xml:space="preserve">
156 tidy
157 </p>
158 </li>
159 <li>
160 <p xml:space="preserve">
161 xsltproc
162 </p>
163 </li>
164 <li>
165 <p xml:space="preserve">
166 xmlcatalog and xmllint
167 </p>
168 </li>
169 </ul>
170 <h1>
171 <a name="">Regenerating the build system</a>
172 </h1>
173 <p xml:space="preserve">
174 If you are building ATF from code extracted from the repository,
175 you must
176 first regenerate the files used by the build system. You will also
177 need to
178 do this if you modify one of configure.ac or Makefile.am.m4. To do
179 this,
180 simply run:
181 </p>
182 <pre class="screen">
183 $ ./autogen.sh
184 </pre>
185 <p xml:space="preserve">
186 For formal releases, no extra steps are needed.
187 </p>
188 <h1>
189 <a name="">General build procedure</a>
190 </h1>
191 <p xml:space="preserve">
192 To build and install the source package, you must follow these
193 steps:
194 </p>
195 <ol>
196 <li>
197 <p xml:space="preserve">
198 Configure the sources to adapt to your operating system.
199 This is done using the 'configure' script located on the sources'
201 directory, and it is usually invoked without arguments unless you
202 want to
203 change the installation prefix. More details on this procedure are
204 given
205 on a later section.
206 </p>
207 </li>
208 <li>
209 <p xml:space="preserve">
210 Build the sources to generate the binaries and scripts.
211 Simply run 'make' on the sources' top directory after configuring
212 them. No
213 problems should arise.
214 </p>
215 </li>
216 <li>
217 <p xml:space="preserve">
218 Install the program by running 'make install'. You may
219 need to become root to issue this step.
220 </p>
221 </li>
222 <li>
223 <p xml:space="preserve">
224 Issue any manual installation steps that may be required.
225 These are described later in their own section.
226 </p>
227 </li>
228 <li>
229 <p xml:space="preserve">
230 Check that the installed programs work by running 'make
231 installcheck'. You do not need to be root to do this, even though
232 some
233 checks will not be run otherwise. (Be aware that on, some systems,
235 Libtool will break these checks. If you get some failures, try
236 reconfiguring the project providing the '--disable-fast-install'
237 flag to
238 'configure' and then rebuild and recheck.)
239 </p>
240 </li>
241 </ol>
242 <h1>
243 <a name="">Configuration flags</a>
244 </h1>
245 <p xml:space="preserve">
246 The most common, standard flags given to 'configure' are:
247 </p>
248 <ul>
249 <li>
252 <u>--prefix=directory</u>
253 </b>
254 </p>
255 <p xml:space="preserve">
256 Possible values: Any path
257 </p>
258 <p xml:space="preserve">
259 Default: /usr/local
260 </p>
261 <p xml:space="preserve">
262 Specifies where the program (binaries and all associated files)
263 will be installed.
264 </p>
265 </li>
266 <li>
269 <u>--sysconfdir=directory</u>
270 </b>
271 </p>
272 <p xml:space="preserve">
273 Possible values: Any path
274 </p>
275 <p xml:space="preserve">
276 Default: /usr/local/etc
277 </p>
278 <p xml:space="preserve">
279 Specifies where the installed programs will look for
280 configuration files. '/atf' will be appended to the given path
281 unless
282 ATF_CONFSUBDIR is redefined as explained later on.
283 </p>
284 </li>
285 <li>
288 <u>--help</u>
289 </b>
290 </p>
291 <p xml:space="preserve">
292 Shows information about all available flags and exits
293 immediately, without running any configuration tasks.
294 </p>
295 </li>
296 </ul>
297 <p xml:space="preserve">
298 The following environment variables are specific to ATF's
299 'configure'
300 script:
301 </p>
302 <ul>
303 <li>
306 <u>ATF_BUILD_CC</u>
307 </b>
308 </p>
309 <p xml:space="preserve">
310 Possible values: empty, a absolute or relative path to a C
311 compiler.
312 </p>
313 <p xml:space="preserve">
314 Default: the value of CC as detected by the configure
315 script.
316 </p>
317 <p xml:space="preserve">
318 Specifies the C compiler that ATF will use at run time whenever
319 the build-time-specific checks are used.
320 </p>
321 </li>
322 <li>
325 <u>ATF_BUILD_CFLAGS</u>
326 </b>
327 </p>
328 <p xml:space="preserve">
329 Possible values: empty, a list of valid C compiler flags.
330 </p>
331 <p xml:space="preserve">
332 Default: the value of CFLAGS as detected by the configure
333 script.
334 </p>
335 <p xml:space="preserve">
336 Specifies the C compiler flags that ATF will use at run time
337 whenever the build-time-specific checks are used.
338 </p>
339 </li>
340 <li>
343 <u>ATF_BUILD_CPP</u>
344 </b>
345 </p>
346 <p xml:space="preserve">
347 Possible values: empty, a absolute or relative path to a C/C++
348 preprocessor.
349 </p>
350 <p xml:space="preserve">
351 Default: the value of CPP as detected by the
352 configure script.
353 </p>
354 <p xml:space="preserve">
355 Specifies the C/C++ preprocessor that ATF will use at run time
356 whenever the build-time-specific checks are used.
357 </p>
358 </li>
359 <li>
362 <u>ATF_BUILD_CPPFLAGS</u>
363 </b>
364 </p>
365 <p xml:space="preserve">
366 Possible values: empty, a list of valid C/C++ preprocessor
367 flags.
368 </p>
369 <p xml:space="preserve">
370 Default: the value of CPPFLAGS as detected by the configure
371 script.
372 </p>
373 <p xml:space="preserve">
374 Specifies the C/C++ preprocessor flags that ATF will use at run
375 time whenever the build-time-specific checks are used.
376 </p>
377 </li>
378 <li>
381 <u>ATF_BUILD_CXX</u>
382 </b>
383 </p>
384 <p xml:space="preserve">
385 Possible values: empty, a absolute or relative path to a C++
386 compiler.
387 </p>
388 <p xml:space="preserve">
389 Default: the value of CXX as detected by the configure
390 script.
391 </p>
392 <p xml:space="preserve">
393 Specifies the C++ compiler that ATF will use at run time whenever
394 the build-time-specific checks are used.
395 </p>
396 </li>
397 <li>
400 <u>ATF_BUILD_CXXFLAGS</u>
401 </b>
402 </p>
403 <p xml:space="preserve">
404 Possible values: empty, a list of valid C++ compiler
405 flags.
406 </p>
407 <p xml:space="preserve">
408 Default: the value of CXXFLAGS as detected by the configure
409 script.
410 </p>
411 <p xml:space="preserve">
412 Specifies the C++ compiler flags that ATF will use at run time
413 whenever the build-time-specific checks are used.
414 </p>
415 </li>
416 <li>
419 <u>ATF_CONFSUBDIR</u>
420 </b>
421 </p>
422 <p xml:space="preserve">
423 Possible values: empty, a relative path.
424 </p>
425 <p xml:space="preserve">
426 Default: atf.
427 </p>
428 <p xml:space="preserve">
429 Specifies the subdirectory of the configuration directory (given
430 by the --sysconfdir argument) under which ATF will search for
432 configuration files.
433 </p>
434 </li>
435 <li>
438 <u>ATF_M4</u>
439 </b>
440 </p>
441 <p xml:space="preserve">
442 Possible values: empty, absolute path to a M4 macro
443 processor.
444 </p>
445 <p xml:space="preserve">
446 Default: empty.
447 </p>
448 <p xml:space="preserve">
449 Specifies the M4 macro processor that ATF will use at run time to
450 generate GNU Automake files. If empty, the configure script
451 will try
452 to find a suitable M4 implementation for you.
453 </p>
454 </li>
455 <li>
458 <u>ATF_SHELL</u>
459 </b>
460 </p>
461 <p xml:space="preserve">
462 Possible values: empty, absolute path to a POSIX shell
463 interpreter.
464 </p>
465 <p xml:space="preserve">
466 Default: empty.
467 </p>
468 <p xml:space="preserve">
469 Specifies the POSIX shell interpreter that ATF will use at run
470 time to execute its scripts and the test programs written using
472 atf-sh library. If empty, the configure script will try to
473 find a
474 suitable interpreter for you.
475 </p>
476 </li>
477 <li>
480 <u>ATF_WORKDIR</u>
481 </b>
482 </p>
483 <p xml:space="preserve">
484 Possible values: empty, an absolute path.
485 </p>
486 <p xml:space="preserve">
487 Default: /tmp or /var/tmp, depending on availability.
488 </p>
489 <p xml:space="preserve">
490 Specifies the directory that ATF will use to place its temporary
491 files and work directories for test cases. This is just a
492 default and
493 can be overriden at run time.
494 </p>
495 </li>
496 <li>
499 <u>LINKS</u>
500 </b>
501 </p>
502 <p xml:space="preserve">
503 Possible values: absolute path.
504 </p>
505 <p xml:space="preserve">
506 Default: links.
507 </p>
508 <p xml:space="preserve">
509 Specifies the program name or the absolute path of the 'links'
510 application. Required when --enable-doc-build is used;
511 otherwise
512 ignored.
513 </p>
514 </li>
515 <li>
518 <u>TIDY</u>
519 </b>
520 </p>
521 <p xml:space="preserve">
522 Possible values: absolute path.
523 </p>
524 <p xml:space="preserve">
525 Default: tidy.
526 </p>
527 <p xml:space="preserve">
528 Specifies the program name or the absolute path of the 'tidy'
529 tool. Required when --enable-doc-build is used; otherwise
530 ignored.
531 </p>
532 </li>
533 <li>
536 <u>XMLCATALOG</u>
537 </b>
538 </p>
539 <p xml:space="preserve">
540 Possible values: absolute path.
541 </p>
542 <p xml:space="preserve">
543 Default: xmlcatalog.
544 </p>
545 <p xml:space="preserve">
546 Specifies the program name or the absolute path of the
547 'xmlcatalog' tool. Required when --enable-doc-build is used;
548 otherwise
549 ignored.
550 </p>
551 </li>
552 <li>
555 <u>XML_CATALOG_FILE</u>
556 </b>
557 </p>
558 <p xml:space="preserve">
559 Possible values: absolute path.
560 </p>
561 <p xml:space="preserve">
562 Default: /etc/xml/catalog
563 </p>
564 <p xml:space="preserve">
565 Specifies the path to the system-wide XML catalog used to lookup
566 the required DTDs. The build will NOT perform any network
567 access to
568 load them. Required when --enable-doc-build is used; otherwise
569 ignored.
570 </p>
571 </li>
572 <li>
575 <u>XMLLINT</u>
576 </b>
577 </p>
578 <p xml:space="preserve">
579 Possible values: absolute path.
580 </p>
581 <p xml:space="preserve">
582 Default: xmllint.
583 </p>
584 <p xml:space="preserve">
585 Specifies the program name or the absolute path of the 'xmllint'
586 tool. Required when --enable-doc-build is used; otherwise
587 ignored.
588 </p>
589 </li>
590 <li>
593 <u>XSLTPROC</u>
594 </b>
595 </p>
596 <p xml:space="preserve">
597 Possible values: absolute path.
598 </p>
599 <p xml:space="preserve">
600 Default: xsltproc.
601 </p>
602 <p xml:space="preserve">
603 Specifies the program name or the absolute path of the 'xsltproc'
604 tool. Required when --enable-doc-build is used; otherwise
605 ignored.
606 </p>
607 </li>
608 </ul>
609 <p xml:space="preserve">
610 The following flags are specific to ATF's 'configure' script:
611 </p>
612 <ul>
613 <li>
616 <u>--enable-developer</u>
617 </b>
618 </p>
619 <p xml:space="preserve">
620 Possible values: yes, no
621 </p>
622 <p xml:space="preserve">
623 Default: Depends on the version number. Stable versions define
624 this to 'no' while all others have it set to 'yes'.
625 </p>
626 <p xml:space="preserve">
627 Enables several features useful for development, such as the
628 inclusion of debugging symbols in all objects or the enabling
630 warnings during compilation.
631 </p>
632 </li>
633 <li>
636 <u>--enable-doc-build</u>
637 </b>
638 </p>
639 <p xml:space="preserve">
640 Possible values: yes, no
641 </p>
642 <p xml:space="preserve">
643 Default: no.
644 </p>
645 <p xml:space="preserve">
646 Enables the building of the XML documentation. This must be
647 enabled in order to be able to generate a distribution file
648 (aka run
649 'make dist'). Disabled by default because the toolchain
650 required to
651 enable this feature is pretty big, and not everyone needs it:
653 distribution files come with up-to-date, pregenerated
654 documentation.
655 </p>
656 </li>
657 <li>
660 <u>--enable-unstable-shared</u>
661 </b>
662 </p>
663 <p xml:space="preserve">
664 Possible values: yes, no
665 </p>
666 <p xml:space="preserve">
667 Default: no.
668 </p>
669 <p xml:space="preserve">
670 Forces the building of shared libraries in addition to static
671 ones. The build of shared libraries is currently disabled
672 because
673 their ABIs and APIs are unstable and subject to change. This
674 flag is
675 provided for development purposes only and will be removed once
677 libraries are stable enough.
678 </p>
679 </li>
680 </ul>
681 <h1>
682 <a name="">Post-installation steps</a>
683 </h1>
684 <p xml:space="preserve">
685 After installing ATF, you have to register the DTDs it provides
686 into
687 the system-wide XML catalog. See the comments at the top of the
688 files in
689 ${datadir}/share/xml/atf to see the correct public identifiers.
690 This
691 directory will typically be /usr/local/share/xml/atf or
692 /usr/share/xml/atf.
693 Failure to do so will lead to further errors when processing the
694 XML files
695 generated by atf-report.
696 </p>
697 </div>
698 </body>
699 </html>