Skip to content

Developer

Marc Mosko edited this page Feb 11, 2016 · 9 revisions

Developer Resources

Git Sources

The recommended method to develop against git is to fork our public repository to your account and develop against that. You can then generate pull requests to ask for changes to be incorporated in to the public release.

  1. In github.com, you need to have your own account.
  2. Go to our project in github.com/PARC/ccns3Sim and click on the Fork button. Specify your personal account as the target.
  3. Follow the [Getting Started walkthrough](Getting Started#complete-walkthrough), and use your personal fork for the git URI.
  4. Add our repository as the upstream, so you can pull changes (git remote add upstream git@github.com:PARC/ccns3Sim.git).

... FINISH ...

Setting up Eclipse

This is a walkthrough on setting up Eclipse from scratch. It assumes you have followed the [Getting Started walkthrough](Getting Started#complete-walkthrough) to download NS3 and clone our code in to the source directory.

You should have a recent Eclipse (we use Mars) along with the C/C++ module.

Create an Eclipse workspace

We create the workspace in the ~/ns3 directory. This is one directory up from where you put your NS3 allinone package.

Create the project

You should have run "./waf configure" already (from the Getting Started section).

  1. Select File | Import and choose from the C/C++ group "Existing code as Makefile Project".
    1. Project Name = ns-allinone-3.24.1
    2. Location = ~/ns3/ns-allinone-3.24.1
    3. Languages: check both C and C++
    4. Toolchain: Select "MacOSX GCC" (or appropriate Linux one)
  2. Right click the project and select "Properties", navigate to C/C++ Build
    1. "Builder Settings" tab
      1. Deselect "use default build command"
      2. Build command: ${ProjDirPath}/ns-3.24.1/waf
      3. Build directory: ${ProjDirPath}/ns-3.24.1
    2. "Behavior" tab
      1. Check "enable parallel build"
      2. Build (incremental build): build (was "all")
    3. "Refresh Policy" tab
      1. Click the project name
      2. Click "Add Exception"
      3. Click "Add" and exclude these directories: bake, netanim-3.106, pybindgen-..., ns-3.24.1/doc
      4. It's very important to add the ns-3.24.1/doc directory if you will be building the doxygen, otherwise Eclipse can stall out on parsing the directory.
    4. Click "Apply"
  3. In the project properties tree, select "C/C++ General"
    1. Select "Enable project specific settings"
    2. Select "Doxygen" as the Documentation Tool.
  4. In the project properties tree, select "C/C++ General | Formatter"
    1. Enable project specific settings
    2. Select "GNU [built-in]"
  5. In the project properties tree, select "C/C++ General | Paths and Symbols"
    1. "Includes" tab for GNU C++
      1. Click "Add", then "Workspace", then navigate to "ns-allinone-3.24.1/ns-3.24.1/src" and click OK
      2. Click "Add to all configurations" and "Add to all languages".
      3. Click "OK"
    2. "Source Location" tab
      1. Select "Add Folder" and navigate to "ns-3.24.1/src"
      2. Select original entry "ns-allinone-3.24.1" in the "build path" window and then "Delete"
    3. Click "Apply" and then "Yes" to rebuild the index
    4. Click "OK"
  • Home
  • [Getting Started](Getting Started)
  • Developer
    • [Node Architecture](Node Architecture)
    • [Header doc format](Header doc format)
    • [Unit Tests](Unit Tests)
    • [Overriding Implementations](Overriding Implementations)
    • [Code Coverage](Code Coverage)

Clone this wiki locally