# HG changeset patch # User Craig Dowell # Date 1269039241 25200 # Node ID 9f2dea6094dab40fb4a76f6f94d18382746fbaa8 # Parent f64266d592a4410140a39eb9abdfa1bb8847ccbc small explanation about (lack of) logging in optimized builds diff -r f64266d592a4 -r 9f2dea6094da doc/tutorial/getting-started.texi --- a/doc/tutorial/getting-started.texi Fri Mar 05 11:15:20 2010 -0800 +++ b/doc/tutorial/getting-started.texi Fri Mar 19 15:54:01 2010 -0700 @@ -601,6 +601,34 @@ @emph{Congratulations. You are now an ns-3 user.} +@emph{What do I do if I don't see the output?} + +If you don't see @code{waf} messages indicating that the build was +completed successfully, but do not see the ``Hello Simulator'' output, +chances are that you have switched your build mode to ``optimized'' in +the ``Building with Waf'' section, but have missed the change back to +``debug'' mode. All of the console output used in this tutorial uses a +special @command{ns-3} logging component that is useful for printing +user messages to the console. Output from this component is +automatically disabled when you compile optimized code -- it is +``optimized out.'' If you don't see the ``Hello Simulator'' output, +type the following, + +@verbatim + ./waf -d debug configure +@end verbatim + +to tell @code{waf} to build the debug versions of the @command{ns-3} +programs. You must still build the actual debug version of the code by +typing, + +@verbatim + ./waf +@end verbatim + +Now, if you run the @code{hello-simulator} program, you should see the +expected output. + If you want to run programs under another tool such as gdb or valgrind, see this @uref{http://www.nsnam.org/wiki/index.php/User_FAQ#How_to_run_NS-3_programs_under_another_tool,,wiki entry}.