Make examples not be built by default
authorMitch Watrous <watrous@u.washington.edu>
Tue, 12 Apr 2011 14:35:16 -0700
changeset 7024 4392d52b3536
parent 7023 af9c5ac72f2c
child 7025 32212c736ab4
Make examples not be built by default
CHANGES.html
doc/build.txt
doc/manual/source/attributes.rst
doc/manual/source/click.rst
doc/manual/source/distributed.rst
doc/manual/source/openflow-switch.rst
doc/manual/source/tcp.rst
doc/release_steps.txt
doc/testing/source/testing-framework.rst
doc/tutorial/source/conceptual-overview.rst
doc/tutorial/source/getting-started.rst
utils.py
utils/.ns3rc
wscript
--- a/CHANGES.html	Tue Apr 12 10:39:17 2011 -0700
+++ b/CHANGES.html	Tue Apr 12 14:35:16 2011 -0700
@@ -48,17 +48,17 @@
 
 <h2>Changes to build system:</h2>
 <ul>
-<li><b>Tests are no longer built by default in ns-3</b>
+<li><b>Examples and tests are no longer built by default in ns-3</b>
 <p>
-You can now make tests be built in ns-3 in two ways.
+You can now make examples and tests be built in ns-3 in two ways.
 <ol>
 <li> Using build.py when ns-3 is built for the first time:
 <pre>
-    ./build.py --enable-tests
+    ./build.py --enable-examples --enable-tests
 </pre>
 <li> Using waf once ns-3 has been built:
 <pre>
-    ./waf configure --enable-tests
+    ./waf configure --enable-examples --enable-tests
 </pre>
 </ol>
 </p></li>
--- a/doc/build.txt	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/build.txt	Tue Apr 12 14:35:16 2011 -0700
@@ -36,8 +36,8 @@
 
 Other waf usages include:
 
- 1. ./waf configure --enable-tests
-    Turn on unit tests.
+ 1. ./waf configure --enable-examples --enable-tests
+    Turn on examples and tests.
 
  2. ./waf --doxygen
     Run doxygen to generate documentation
--- a/doc/manual/source/attributes.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/manual/source/attributes.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -768,7 +768,7 @@
     sudo apt-get install libgtk2.0-0 libgtk2.0-dev
 
 To check whether it is configured or not, check the output of the
-./waf configure --enable-tests step:::
+./waf configure --enable-examples --enable-tests step:::
 
     ---- Summary of optional NS-3 features:
     Threading Primitives          : enabled
@@ -776,7 +776,7 @@
     GtkConfigStore                : not enabled (library 'gtk+-2.0 >= 2.12' not found)
 
 In the above example, it was not enabled, so it cannot be used until a suitable
-version is installed and ./waf configure --enable-tests; ./waf is rerun.
+version is installed and ./waf configure --enable-examples --enable-tests; ./waf is rerun.
 
 Usage is almost the same as the non-GTK-based version, but there
 are no ConfigStore attributes involved:::
--- a/doc/manual/source/click.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/manual/source/click.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -73,7 +73,7 @@
 Once Click has been built successfully, change into the ns-3 directory and 
 configure ns-3 with Click Integration support::
 
-  $: ./waf configure --enable-tests --with-nsclick=/path/to/click/source
+  $: ./waf configure --enable-examples --enable-tests --with-nsclick=/path/to/click/source
 
 If it says 'enabled' beside 'NS-3 Click Integration Support', then you're good to go.
 
--- a/doc/manual/source/distributed.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/manual/source/distributed.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -118,7 +118,7 @@
 
 Configure |ns3| with the --enable-mpi option:::
 
-    ./waf -d debug configure --enable-tests --enable-mpi
+    ./waf -d debug configure --enable-examples --enable-tests --enable-mpi
 
 Ensure that MPI is enabled by checking the optional features shown from the
 output of configure.
--- a/doc/manual/source/openflow-switch.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/manual/source/openflow-switch.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -143,7 +143,7 @@
 link to an ns-3 build with this OpenFlow switch module, run from the ns-3-dev
 (or whatever you have named your distribution):::
 
-  $ ./waf configure --enable-tests --with-openflow=path/to/openflow
+  $ ./waf configure --enable-examples --enable-tests --with-openflow=path/to/openflow
 
 #3 Under ``---- Summary of optional NS-3 features:`` you should see:::
 
--- a/doc/manual/source/tcp.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/manual/source/tcp.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -164,7 +164,7 @@
 default unless the platform does not support it. To disable it when building
 |ns3|, type:::
 
-./waf configure --enable-tests --disable-nsc
+./waf configure --enable-examples --enable-tests --disable-nsc
 
 Building and validating
 +++++++++++++++++++++++
--- a/doc/release_steps.txt	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/release_steps.txt	Tue Apr 12 14:35:16 2011 -0700
@@ -48,7 +48,7 @@
    - cd ns-3.x
    - ./test.py
    - ./test.py -g
-   - ./waf -d optimized --enable-tests configure
+   - ./waf -d optimized --enable-examples --enable-tests configure
    - ./waf
    - ./test.py
    - ./test.py -g
--- a/doc/testing/source/testing-framework.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/testing/source/testing-framework.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -64,11 +64,12 @@
 ``test.py`` is very flexible in allowing the user to specify the number
 and kind of tests to run; and also the amount and kind of output to generate.
 
-Before running ``test.py``, make sure that ns3's tests have been built by doing the following
+Before running ``test.py``, make sure that ns3's examples and tests
+have been built by doing the following
 
 ::
 
-  ./waf configure --enable-tests
+  ./waf configure --enable-examples --enable-tests
   ./waf
 
 By default, ``test.py`` will run all available tests and report status
--- a/doc/tutorial/source/conceptual-overview.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/tutorial/source/conceptual-overview.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -249,10 +249,10 @@
 
 ::
 
-  ./waf -d debug --enable-tests configure
+  ./waf -d debug --enable-examples --enable-tests configure
 
 in order to configure the project to perform debug builds that include 
-tests.  You will also have done a
+examples and tests.  You will also have done a
 
 ::
 
--- a/doc/tutorial/source/getting-started.rst	Tue Apr 12 10:39:17 2011 -0700
+++ b/doc/tutorial/source/getting-started.rst	Tue Apr 12 14:35:16 2011 -0700
@@ -264,12 +264,12 @@
 
 ::
 
-  ./build.py --enable-tests
+  ./build.py --enable-examples --enable-tests
 
-Because we are working with tests in this tutorial, and because they
-are not built by default in |ns3|, the argument for build.py tells it
-to build them for us.  In the future you can build |ns3| without tests
-if you wish.
+Because we are working with examples and tests in this tutorial, and
+because they are not built by default in |ns3|, the arguments for
+build.py tells it to build them for us.  In the future you can build
+|ns3| without examples and tests if you wish.
 
 You will see lots of typical compiler output messages displayed as the build
 script builds the various pieces you downloaded.  Eventually you should see the
@@ -300,12 +300,12 @@
 build the optimized version of the code.  By default you have configured
 your project to build the debug version.  Let's tell the project to 
 make an optimized build.  To explain to Waf that it should do optimized
-builds that include the tests, you will need to execute the 
+builds that include the examples and tests, you will need to execute the 
 following command,
 
 ::
 
-  ./waf -d optimized --enable-tests configure
+  ./waf -d optimized --enable-examples --enable-tests configure
 
 This runs Waf out of the local directory (which is provided as a convenience
 for you).  As the build system checks for various dependencies you should see
@@ -379,11 +379,11 @@
 a feature to use the program ``sudo`` to set the suid bit of certain programs.
 This is not enabled by default and so this feature is reported as "not enabled."
 
-Now go ahead and switch back to the debug build that includes the tests.
+Now go ahead and switch back to the debug build that includes the examples and tests.
 
 ::
 
-  ./waf -d debug --enable-tests configure
+  ./waf -d debug --enable-examples --enable-tests configure
 
 The build system is now configured and you can build the debug versions of 
 the |ns3| programs by simply typing,
@@ -396,11 +396,11 @@
 in the configuration phase.  For example, if you wanted to use the emulation 
 features of |ns3|, you might want to enable setting the suid bit using
 sudo as described above.  This turns out to be a configuration-time command, and so 
-you could reconfigure using the following command that also includes the tests
+you could reconfigure using the following command that also includes the examples and tests
 
 ::
 
-  ./waf -d debug --enable-sudo --enable-tests configure
+  ./waf -d debug --enable-sudo --enable-examples --enable-tests configure
 
 If you do this, waf will have run sudo to change the socket creator programs of the
 emulation code to run as root.  There are many other configure- and build-time options
@@ -499,10 +499,10 @@
 
 ::
 
-  ./waf -d debug --enable-tests configure
+  ./waf -d debug --enable-examples --enable-tests configure
 
 to tell ``waf`` to build the debug versions of the |ns3| 
-programs that includes the tests.  You must still build 
+programs that includes the examples and tests.  You must still build 
 the actual debug version of the code by typing,
 
 ::
--- a/utils.py	Tue Apr 12 10:39:17 2011 -0700
+++ b/utils.py	Tue Apr 12 14:35:16 2011 -0700
@@ -85,10 +85,10 @@
 
     '''
 
-    # By default, all modules will be enabled, examples will be enabled,
+    # By default, all modules will be enabled, examples will be disabled,
     # and tests will be disabled.
     modules_enabled  = ['all_modules']
-    examples_enabled = True
+    examples_enabled = False
     tests_enabled    = False
 
     # See if the ns3 configuration file exists in the current working
@@ -111,7 +111,7 @@
         modules_enabled = ['all_modules']
 
     # Read in whether examples should be enabled or not.
-    value_if_missing = True
+    value_if_missing = False
     examples_enabled = get_bool_from_file(dot_ns3rc_path, 'examples_enabled', value_if_missing)
 
     # Read in whether tests should be enabled or not.
--- a/utils/.ns3rc	Tue Apr 12 10:39:17 2011 -0700
+++ b/utils/.ns3rc	Tue Apr 12 14:35:16 2011 -0700
@@ -7,7 +7,7 @@
 modules_enabled = ['all_modules']
 
 # Set this equal to true if you want examples to be run.
-examples_enabled = True
+examples_enabled = False
 
 # Set this equal to true if you want tests to be run.
 tests_enabled = False
--- a/wscript	Tue Apr 12 10:39:17 2011 -0700
+++ b/wscript	Tue Apr 12 14:35:16 2011 -0700
@@ -30,10 +30,10 @@
 
 from utils import read_config_file
 
-# By default, all modules will be enabled, examples will be enabled,
+# By default, all modules will be enabled, examples will be disabled,
 # and tests will be disabled.
 modules_enabled  = ['all_modules']
-examples_enabled = True
+examples_enabled = False
 tests_enabled    = False
 
 # Get the information out of the NS-3 configuration file.