Navigation



Version 3 (modified by Sebastien Decugis, 14 years ago) (diff)

--

Information for developers

The project is managed with mercurial. You can access the repository at this address: http://www.freediameter.net/hg/freeDiameter

The repository is read-only. If you want to submit patches, please use the developers mailing-list dev@freediameter.net. You can subscribe to the list here and check the archives there. The tickets system can also be used.

Last but not least, please feel free to contribute to the website! Thank you.

Developer's quick start

Although you can find a lot of information on Mercurial and CMake on the Internet, the following are a few useful tips and tricks for starting development with freeDiameter.

Clone the repository
The following command will fetch the latest source tree in a freeDiameter directory:
hg clone http://www.freediameter.net/hg/freeDiameter
Update your source tree
When you already have cloned the repository, you can retrieve updates from upstream with the command bellow:
hg pull -u
If you have made local changes, Mercurial will attempt to merge everything by it-self, which is very convenient. If you need archiving your changes, you might have a look at Mercurial Queues.
Build and test
Files/Directories named test.* are ignored by Mercurial in the freeDiameter package ([source:.hgignore]). The following files can reside in your tree without interacting with the repository, and simplify your build-and-test process:
$ ls test.conf/
CMakeFlags   freeDiameter.conf  myextension.conf
$ cat test.rebuild
#!/bin/bash -x
rm -rf test.build
cp -Rs `pwd`/test.conf test.build
cd test.build
cmake `cat CMakeFlags` ..
make
This allows you to save your configuration files in test.conf directory, and rebuild the whole tree from scratch in a different folder by simply running the test.rebuild script.
Useful CMake flags for development
The following flags are useful for configuring the source, for example in CMakeFlags file (see previous point).
-DCMAKE_BUILD_TYPE:STRING=Debug
This impacts both the compiler's flags (including symbols for debug) and freeDiameter itself (allowing some slow tracing options such as --dbg-func).
-DSKIP_TESTS:BOOL=OFF
Allows the compilation of the unit tests, called by running make test.
-DBUILD_TEST_APP:BOOL=ON
Compile the test application extension test_app.fdx.