ea024c164404d280f4e520ac4301e1d13407d037
[pintos-anon] / doc / devel.texi
1 @node Development Tools
2 @appendix Development Tools
3
4 Here are some tools that you might find useful while developing code.
5
6 @menu
7 * Tags::
8 * cscope::
9 * CVS:: @ifset recommendsourceforge 
10 * SourceForge:: @end ifset 
11 @ifset recommendvnc
12 * VNC:: @end ifset 
13 @ifset recommendcygwin
14 * Cygwin:: @end ifset
15 @end menu
16
17 @node Tags
18 @section Tags
19
20 Tags are an index to the functions and global variables declared in a
21 program.  Many editors, including Emacs and @command{vi}, can use
22 them.  The @file{Makefile} in @file{pintos/src} produces Emacs-style
23 tags with the command @code{make TAGS} or @command{vi}-style tags with
24 @code{make tags}.
25
26 In Emacs, use @kbd{M-.} to follow a tag in the current window,
27 @kbd{C-x 4 .} in a new window, or @kbd{C-x 5 .} in a new frame.  If
28 your cursor is on a symbol name for any of those commands, it becomes
29 the default target.  If a tag name has multiple definitions, @kbd{M-0
30 M-.} jumps to the next one.  To jump back to where you were before
31 you followed the last tag, use @kbd{M-*}.
32
33 @node cscope
34 @section cscope
35
36 The @command{cscope} program also provides an index to functions and
37 variables declared in a program.  It has some features that tag
38 facilities lack.  Most notably, it can find all the points in a
39 program at which a given function is called.
40
41 The @file{Makefile} in @file{pintos/src} produces @command{cscope}
42 indexes when it is invoked as @code{make cscope}.  Once the index has
43 been generated, run @command{cscope} from a shell command line; no
44 command-line arguments are normally necessary.  Then use the arrow
45 keys to choose one of the search criteria listed near the bottom of
46 the terminal, type in an identifier, and hit @key{Enter}.
47 @command{cscope} will then display the matches in the upper part of
48 the terminal.  You may use the arrow keys to choose a particular
49 match; if you then hit @key{Enter}, @command{cscope} will invoke the
50 default system editor@footnote{This is typically @command{vi}.  To
51 exit @command{vi}, type @kbd{: q @key{Enter}}.} and position the
52 cursor on that match.  To start a new search, type @key{Tab}.  To exit
53 @command{cscope}, type @kbd{Ctrl-d}.
54
55 Emacs and some versions of @command{vi} have their own interfaces to
56 @command{cscope}.  For information on how to use these interface,
57 visit @url{http://cscope.sourceforge.net, the @command{cscope} home
58 page}.
59
60 @node CVS
61 @section CVS
62
63 CVS is a version-control system.  That is, you can use it to keep
64 track of multiple versions of files.  The idea is that you do some
65 work on your code and test it, then check it into the version-control
66 system.  If you decide that the work you've done since your last
67 check-in is no good, you can easily revert to the last checked-in
68 version.  Furthermore, you can retrieve any old version of your code
69 as of some given day and time.  The version control logs tell you who
70 made changes and when.
71
72 CVS is not the best version control system out there, but it's
73 free, it's fairly easy to use, and it's already installed in most
74 Unix-like environments.
75
76 For more information, visit the @uref{https://www.cvshome.org/, , CVS
77 home page}.
78
79 @include localcvsinstructions.texi
80
81 @ifset recommendsourceforge
82 @node SourceForge
83 @section SourceForge
84
85 SourceForge is a web-based system for facilitating software
86 development.  It provides you with a version-control system (typically
87 CVS, as described above) and other tools for tracking your software.
88 You can use it to store files, track bugs, and post notes about
89 development progress.  You can set up your own
90 project in SourceForge at @uref{http://sourceforge.net, ,
91 sourceforge.net}.
92 @end ifset
93
94 @ifset recommendvnc
95 @node VNC
96 @section VNC
97
98 VNC stands for Virtual Network Computing.  It is, in essence, a remote
99 display system which allows you to view a computing ``desktop''
100 environment not only on the machine where it is running, but from
101 anywhere on the Internet and from a wide variety of machine
102 architectures.  It is already installed on the lab machines.  
103 For more information, look at the @uref{http://www.realvnc.com/, , VNC
104 Home Page}.
105 @end ifset
106
107 @ifset recommendcygwin
108 @node Cygwin
109 @section Cygwin
110
111 @uref{http://cygwin.com/, ,Cygwin} provides a Linux-compatible environment
112 for Windows.  It includes ssh client and an X11 server, Cygwin/X.  If your
113 primary work environment is Windows, you will find Cygwin/X extremely
114 useful for these projects.  Install Cygwin/X, then start the X server
115 and open a new xterm.  The X11 server also allows you to run pintos while
116 displaying the bochs- or qemu-emulated console on your Windows desktop.
117 @end ifset
118
119 @localdevelopmenttools{}
120