Prepare release 2.8
Change-Id: I98c36a7763387cd27df88713e68035dff222b187
diff --git a/.jenkins.d/01-deps.sh b/.jenkins.d/01-deps.sh
index db2d808..d3709b5 100755
--- a/.jenkins.d/01-deps.sh
+++ b/.jenkins.d/01-deps.sh
@@ -7,19 +7,48 @@
set -x
if has OSX $NODE_LABELS; then
+ FORMULAE=(boost pkg-config libxml2)
+ if [[ -n $USE_OPENSSL_1_1 ]]; then
+ FORMULAE+=(openssl@1.1)
+ else
+ FORMULAE+=(openssl)
+ fi
+
brew update
- brew upgrade
- brew install boost pkg-config cryptopp openssl
- brew install libxml2
- brew link --force libxml2
+ if [[ -n $TRAVIS ]]; then
+ # Travis images come with a large number of brew packages
+ # pre-installed, don't waste time upgrading all of them
+ for FORMULA in "${FORMULAE[@]}"; do
+ brew outdated $FORMULA || brew upgrade $FORMULA
+ done
+ else
+ brew upgrade
+ fi
+ brew install "${FORMULAE[@]}"
brew cleanup
fi
if has Ubuntu $NODE_LABELS; then
sudo apt-get -qq update
- sudo apt-get -qq install build-essential pkg-config libboost-all-dev \
- libcrypto++-dev libsqlite3-dev libssl-dev
- sudo apt-get install -qq -y python-setuptools python-dev python-pygraphviz python-kiwi
- # sudo apt-get install -qq -y python-pygoocanvas python-gnome2
- # sudo apt-get install -qq -y python-rsvg ipython
+ sudo apt-get -qy install build-essential pkg-config libboost-all-dev \
+ libsqlite3-dev libssl-dev
+
+ if [[ $JOB_NAME == *"code-coverage" ]]; then
+ sudo apt-get -qy install gcovr lcov libgd-perl
+ fi
+fi
+
+if has Ubuntu-16.04 $NODE_LABELS; then
+ sudo apt-get -qy install python-setuptools python-dev python-pygraphviz castxml \
+ python-kiwi python-gnome2 ipython libcairo2-dev python3-gi \
+ libgirepository1.0-dev python-gi python-gi-cairo \
+ gir1.2-gtk-3.0 gir1.2-goocanvas-2.0 python-pip
+ sudo pip install pygraphviz pycairo PyGObject pygccxml
+elif has Ubuntu $NODE_LABELS; then
+ sudo apt-get -qy install build-essential libsqlite3-dev libboost-all-dev libssl-dev \
+ git python3-setuptools castxml \
+ gir1.2-goocanvas-2.0 gir1.2-gtk-3.0 libgirepository1.0-dev \
+ python3-dev python3-gi python3-gi-cairo \
+ python3-pip python3-pygraphviz python3-pygccxml
+ sudo pip3 install kiwi
fi
diff --git a/.jenkins.d/10-build.sh b/.jenkins.d/10-build.sh
index f0fb72e..58599ea 100755
--- a/.jenkins.d/10-build.sh
+++ b/.jenkins.d/10-build.sh
@@ -1,10 +1,11 @@
#!/usr/bin/env bash
-set -x
set -e
JDIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
source "$JDIR"/util.sh
+set -x
+
pushd ns-3 >/dev/null
git submodule update --init
@@ -13,15 +14,18 @@
sudo rm -Rf build/ .waf-1* .waf3-1*
find . -name '*.pyc' | sudo xargs rm -f
-# Configure/build in debug mode
if has OSX $NODE_LABELS; then
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/opt/libxml2/lib/pkgconfig"
+ if [[ -n $USE_OPENSSL_1_1 ]]; then
+ OPENSSL="--with-openssl=/usr/local/opt/openssl@1.1"
+ fi
fi
-./waf -j${WAF_JOBS:-1} configure -d debug --enable-examples --enable-tests $EXTRA_FLAGS
+
+./waf -j${WAF_JOBS:-1} configure -d debug --enable-examples --enable-tests $OPENSSL
./waf -j${WAF_JOBS:-1} build
# Install
-sudo ./waf -j${WAF_JOBS:-1} install
+sudo_preserve_env PATH -- ./waf -j${WAF_JOBS:-1} install
if has Linux $NODE_LABELS; then
sudo ldconfig
diff --git a/.jenkins.d/20-tests.sh b/.jenkins.d/20-tests.sh
index bf14236..bf0bfee 100755
--- a/.jenkins.d/20-tests.sh
+++ b/.jenkins.d/20-tests.sh
@@ -1,40 +1,19 @@
#!/usr/bin/env bash
-set -x
+set -e
JDIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )
source "$JDIR"/util.sh
-set -e
+set -x
pushd ns-3 >/dev/null
-BOOST_VERSION=$(python -c "import sys; sys.path.append('build/c4che'); import _cache; v = _cache.BOOST_VERSION.split('_'); print int(v[0]) * 100000 + int(v[1]) * 100;")
-
-ut_log_args() {
- if (( BOOST_VERSION >= 106200 )); then
- echo --logger=HRF,test_suite,stdout:XML,all,build/xunit-${1:-report}.xml
- else
- if [[ -n $XUNIT ]]; then
- echo --log_level=all $( (( BOOST_VERSION >= 106000 )) && echo -- ) \
- --log_format2=XML --log_sink2=build/xunit-${1:-report}.xml
- else
- echo --log_level=test_suite
- fi
- fi
-}
-
-ASAN_OPTIONS="color=always"
-ASAN_OPTIONS+=":detect_leaks=false"
-ASAN_OPTIONS+=":detect_stack_use_after_return=true"
-ASAN_OPTIONS+=":check_initialization_order=true"
-ASAN_OPTIONS+=":strict_init_order=true"
-ASAN_OPTIONS+=":detect_invalid_pointer_pairs=1"
-ASAN_OPTIONS+=":detect_container_overflow=false"
-ASAN_OPTIONS+=":strict_string_checks=true"
-ASAN_OPTIONS+=":strip_path_prefix=${PWD}/"
-export ASAN_OPTIONS
+export BOOST_TEST_BUILD_INFO=1
+export BOOST_TEST_COLOR_OUTPUT=1
+export BOOST_TEST_DETECT_MEMORY_LEAK=0
+export BOOST_TEST_LOGGER=HRF,test_suite,stdout:XML,all,build/xunit-log.xml
# Run unit tests
-./waf --run "ndnSIM-unit-tests $(ut_log_args)"
+./waf --run "ndnSIM-unit-tests"
popd >/dev/null
diff --git a/.jenkins.d/README.md b/.jenkins.d/README.md
new file mode 100644
index 0000000..7c78349
--- /dev/null
+++ b/.jenkins.d/README.md
@@ -0,0 +1,33 @@
+CONTINUOUS INTEGRATION SCRIPTS
+==============================
+
+Environment Variables Used in Build Scripts
+-------------------------------------------
+
+- `NODE_LABELS`: the variable defines a list of OS properties. The set values are used by the
+ build scripts to select proper behavior for different OS.
+
+ The list should include at least `[OS_TYPE]`, `[DISTRO_TYPE]`, and `[DISTRO_VERSION]`.
+
+ Possible values for Linux:
+
+ * `[OS_TYPE]`: `Linux`
+ * `[DISTRO_TYPE]`: `Ubuntu`
+ * `[DISTRO_VERSION]`: `Ubuntu-16.04`, `Ubuntu-18.04`
+
+ Possible values for macOS:
+
+ * `[OS_TYPE]`: `OSX`
+ * `[DISTRO_TYPE]`: `OSX` (can be absent)
+ * `[DISTRO_VERSION]`: `OSX-10.12`, `OSX-10.13`, `OSX-10.14`
+
+- `JOB_NAME`: optional variable to define type of the job. Depending on the defined job type,
+ the build scripts can perform different tasks.
+
+ Possible values:
+
+ * empty: default build process
+ * `code-coverage` (Ubuntu Linux is assumed): debug build with tests and code coverage analysis
+ * `limited-build`: only a single debug build with tests
+
+- `WAF_JOBS`: number of parallel build jobs used by waf, defaults to 1.
diff --git a/.jenkins.d/util.sh b/.jenkins.d/util.sh
index a89bc27..8ddc4ba 100755
--- a/.jenkins.d/util.sh
+++ b/.jenkins.d/util.sh
@@ -16,3 +16,22 @@
set ${saved_xtrace}
return ${ret}
}
+
+sudo_preserve_env() {
+ local saved_xtrace
+ [[ $- == *x* ]] && saved_xtrace=-x || saved_xtrace=+x
+ set +x
+
+ local vars=()
+ while [[ $# -gt 0 ]]; do
+ local arg=$1
+ shift
+ case ${arg} in
+ --) break ;;
+ *) vars+=("${arg}=${!arg}") ;;
+ esac
+ done
+
+ set ${saved_xtrace}
+ sudo env "${vars[@]}" "$@"
+}
diff --git a/.travis.yml b/.travis.yml
index 08e40e9..a49b5e8 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,24 +1,89 @@
-sudo: required
-language: generic
+version: ~> 1.0
+language: cpp
+os: linux
+dist: bionic
+arch: amd64
+
env:
- global:
- - WAF_JOBS=2
-matrix:
+ - COMPILER=g++-7
+ - COMPILER=g++-9
+ - COMPILER=clang++-6.0
+ - COMPILER=clang++-9
+
+jobs:
include:
- - os: linux
- dist: xenial
- env:
- - CXX=g++
- - NODE_LABELS="Linux Ubuntu Ubuntu-16.04"
+ # Linux
+ - env: COMPILER=g++-8
+ - env: COMPILER=clang++-5.0
+ - env: COMPILER=clang++-7
+ - env: COMPILER=clang++-8
+ - env: COMPILER=clang++-10
+ - env: COMPILER=clang++-11
+
+ # macOS
- os: osx
- osx_image: xcode10.1
- env:
- - CXX=clang++
- - xcode10.1
- - NODE_LABELS="OSX OSX_VERSION=10.13"
-notifications:
- email:
- on_success: always
- on_failure: always
+ osx_image: xcode11.4
+ env: # default compiler
+
+ allow_failures:
+ - env: COMPILER=clang++-11
+
+ fast_finish: true
+
+before_install:
+ - |
+ : Adding apt repositories
+ case ${COMPILER} in
+ g++-9)
+ # https://launchpad.net/~ubuntu-toolchain-r/+archive/ubuntu/test/+packages
+ travis_retry sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test
+ travis_retry sudo apt-get -qq update
+ ;;
+ clang++-1?)
+ # https://apt.llvm.org/
+ LLVM_REPO=${COMPILER/clang++/llvm-toolchain-${TRAVIS_DIST}}
+ travis_retry wget -nv -O - "https://apt.llvm.org/llvm-snapshot.gpg.key" | sudo apt-key add -
+ travis_retry sudo add-apt-repository -y "deb http://apt.llvm.org/${TRAVIS_DIST}/ ${LLVM_REPO%-11} main"
+ travis_retry sudo apt-get -qq update
+ ;;
+ esac
+
+install:
+ - |
+ : Installing C++ compiler
+ if [[ -n ${COMPILER} ]]; then
+ travis_retry sudo apt-get -qy install ${COMPILER/clang++/clang}
+ fi
+
+before_script:
+ - |
+ : Setting environment variables
+ if [[ -n ${COMPILER} ]]; then
+ export CXX=${COMPILER}
+ fi
+ case ${TRAVIS_OS_NAME} in
+ linux) export NODE_LABELS="Linux Ubuntu Ubuntu-18.04" ;;
+ osx) export NODE_LABELS="OSX OSX-$(sw_vers -productVersion | cut -d . -f -2)" ;;
+ esac
+ export JOB_NAME=limited-build
+ export WAF_JOBS=2
+ - |
+ : Enabling workarounds
+ case "${TRAVIS_CPU_ARCH},${COMPILER}" in
+ arm64,g++*)
+ # Avoid exceeding the per-job time limit
+ export DISABLE_HEADERS_CHECK=yes
+ ;;
+ ppc64le,g++-7)
+ # AddressSanitizer does not seem to be working
+ export DISABLE_ASAN=yes
+ ;;
+ *,clang++-8)
+ # https://bugs.llvm.org/show_bug.cgi?id=40808
+ export DISABLE_ASAN=yes
+ ;;
+ esac
+ - ${CXX:-c++} --version
+
script:
- ./.jenkins
diff --git a/VERSION b/VERSION
deleted file mode 100644
index 227cea2..0000000
--- a/VERSION
+++ /dev/null
@@ -1 +0,0 @@
-2.0.0
diff --git a/docs/source/RELEASE_NOTES.rst b/docs/source/RELEASE_NOTES.rst
index 4e2187d..bd0b38e 100644
--- a/docs/source/RELEASE_NOTES.rst
+++ b/docs/source/RELEASE_NOTES.rst
@@ -5,6 +5,32 @@
All of the ndnSIM documentation is accessible from the `ndnSIM website <https://ndnsim.net>`__.
+Release 2.8
+-----------
+
+- The submodules of NFD and ndn-cxx have been upgraded to version 0.7.0.
+
+ `NFD 0.7.0 release notes <https://named-data.net/doc/NFD/0.7.0/RELEASE_NOTES.html>`__
+
+ `ndn-cxx 0.7.0 release notes <https://named-data.net/doc/ndn-cxx/0.7.0/RELEASE_NOTES.html>`__
+
+ .. note::
+ In order to retrieve the marked versions of ndn-cxx and NFD, use
+ ``--recursive`` option to the git clone command or run ``git
+ submodule update --init`` after clone, pull, or merge.
+
+- With the underlying NFD/ndn-cxx upgrade, ndnSIM now operates with NDN Packet format version 0.3.
+
+- Base NS-3 was rebased to version 3.30.1
+
+- Add Loop-Free In-port Dependent (LFID) route calculation that provides a set of
+ loop-free paths (:issue:`4985`)
+
+- Fix wrong behaviour of default Size in ConsumerWindow
+
+- **Remove** legacy content store implementation. Use content store replacement/placement
+ policies implemented using NFD routines.
+
Release 2.7
-----------
diff --git a/docs/source/_templates/indexcontent.html b/docs/source/_templates/indexcontent.html
index 71289dd..c5810a1 100644
--- a/docs/source/_templates/indexcontent.html
+++ b/docs/source/_templates/indexcontent.html
@@ -59,8 +59,9 @@
<td width="50%" valign="top">
<h2>ndnSIM Versions</h2>
<div class="tile">
- <p class="biglink"><a class="biglink" href="#">ndnSIM 2.7</a><br/>
- <span class="linkdescr">latest version</span></p>
+ <p class="biglink"><a class="biglink" href="#">ndnSIM 2.8</a><br/>
+ <span class="linkdescr">the latest version</span></p>
+ <p class="biglink"><a class="biglink" href="https://ndnsim.net/2.7/">ndnSIM 2.7</a><br/>
<p class="biglink"><a class="biglink" href="https://ndnsim.net/2.6/">ndnSIM 2.6</a><br/>
<p class="biglink"><a class="biglink" href="https://ndnsim.net/2.5/">ndnSIM 2.5</a><br/>
<p class="biglink"><a class="biglink" href="https://ndnsim.net/2.4/">ndnSIM 2.4</a><br/>
diff --git a/docs/source/getting-started.rst b/docs/source/getting-started.rst
index 1749051..b1a42ff 100644
--- a/docs/source/getting-started.rst
+++ b/docs/source/getting-started.rst
@@ -9,9 +9,9 @@
ndnSIM 2.x has been successfully compiled and used on following platforms:
+- Ubuntu Linux 20.04
- Ubuntu Linux 18.04
-- Ubuntu Linux 16.04
-- macOS 10.13
+- macOS 10.15
- macOS 10.14
.. _requirements:
@@ -21,7 +21,7 @@
**1. Core dependencies**
-- ``python`` >= 2.7
+- ``python`` >= 3.5
- ``libsqlite3``
- ``pkg-config``
- ``openssl``
@@ -50,12 +50,18 @@
- Linux
- * Ubuntu Linux
+ * Ubuntu Linux 18.04
.. code-block:: bash
sudo apt install build-essential libsqlite3-dev libboost-all-dev libssl-dev git python-setuptools castxml
+ * Ubuntu Linux 20.04
+
+ .. code-block:: bash
+
+ sudo apt install build-essential libsqlite3-dev libboost-all-dev libssl-dev git python3-setuptools castxml
+
* Fedora Linux
.. code-block:: bash
@@ -87,13 +93,18 @@
- Linux
- * Ubuntu Linux
+ * Ubuntu Linux 18.04
.. code-block:: bash
sudo apt install python-dev python-pygraphviz python-kiwi python-gnome2 ipython libcairo2-dev python3-gi libgirepository1.0-dev python-gi python-gi-cairo gir1.2-gtk-3.0 gir1.2-goocanvas-2.0 python-pip
sudo pip install pygraphviz pycairo PyGObject pygccxml
+ * Ubuntu Linux 20.04
+
+ sudo apt install gir1.2-goocanvas-2.0 gir1.2-gtk-3.0 libgirepository1.0-dev python3-dev python3-gi python3-gi-cairo python3-pip python3-pygraphviz python3-pygccxml
+ sudo pip3 install kiwi
+
.. _visualizer: https://www.nsnam.org/wiki/PyViz
Downloading ndnSIM source
@@ -148,16 +159,6 @@
./waf configure --enable-examples
./waf
-On macOS (with MacPorts), you may need to modify the configure command to use MacPorts
-version of python:
-
-.. code-block:: bash
-
- cd <ns-3-folder>
- ./waf configure --with-python=/opt/local/bin/python2.7 --enable-examples
- # or run ``sudo port select python python27``
- ./waf
-
.. note::
On macOS configuration stage may get :ref:`stuck at detecting gtk module <Problems with
the gtk python module on macOS>`. Make sure you have `XQuartz