forked from vsamtuc/tinyos3
-
Notifications
You must be signed in to change notification settings - Fork 0
/
manhelp.man
97 lines (97 loc) · 1.87 KB
/
manhelp.man
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
.\" Automatically generated by Pandoc 2.2.3.2
.\"
.TH "" "" "" "" ""
.hy
.SH Building tinyos using make
.PP
To build your code easily, a complex Makefile is provided.
This manual presents several ways to run make using this Makefile.
.SS Basic building
.PP
Just type the command
.IP
.nf
\f[C]
$\ make
\f[]
.fi
.PP
This command will compile all the files and build all the executable
programs and the examples.
The built programs will contain debugging information, so that you can
run the debugger on them.
.SS Recompiling all the files
.PP
When there are weird errors, it is possible that something was
corrupted.
To remove all binary files as well as all named pipes, give the
following command:
.IP
.nf
\f[C]
$\ make\ clean
\f[]
.fi
.PP
The you can rebuild everything by giving the command
.IP
.nf
\f[C]
$\ make
\f[]
.fi
.SS Building with full optimizations on
.PP
To see how fast your code is, you can build with full optimizations.
Give the following:
.IP
.nf
\f[C]
$\ make\ DEBUG=0\ clean\ all
\f[]
.fi
.SS Using valgrind
.PP
If you have not installed valgrind, the code will be built without
support for it.
But valgrind is very useful for debugging.
You can install it with the following command:
.IP
.nf
\f[C]
$\ sudo\ apt\ install\ valgrind
\f[]
.fi
.SS Re\-making the dependencies
.PP
When you change the #include headers in some file, you should rebuild
the dependencies.
.IP
.nf
\f[C]
$\ make\ depend
\f[]
.fi
.PP
This way you are sure that make re\-builds everything it needs to
rebuild every time.
.SS Building the documentation
.PP
The code of tinyos comes with a lot of useful documentation.
To build it, you need a program called `doxygen'.
Then, you can view the documentation in your browser.
Here is how to install doxygen
.IP
.nf
\f[C]
$\ sudo\ apt\ install\ doxygen\ graphvis
\f[]
.fi
.PP
Then, you can build the documentation, by the following command:
.IP
.nf
\f[C]
$\ make\ doc
\f[]
.fi