diff --git a/CMakeLists.txt b/CMakeLists.txt index e9ac967ded..38fe1d190a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -205,7 +205,7 @@ add_custom_target(tests) if(DEVELOPER_MODE) add_flag(-Werror) # XXX: WX for windows - find_program(CLANG_FORMAT NAMES clang-format clang-format-8.0) + find_program(CLANG_FORMAT NAMES clang-format clang-format-8 clang-format-8.0) set(CLANG_FORMAT_REQUIRED "8.0") if(CLANG_FORMAT) get_program_version(${CLANG_FORMAT} CLANG_FORMAT_VERSION) diff --git a/doc/libpmemobj++.Doxyfile.in b/doc/libpmemobj++.Doxyfile.in index db51627e58..bb8de1d952 100644 --- a/doc/libpmemobj++.Doxyfile.in +++ b/doc/libpmemobj++.Doxyfile.in @@ -73,7 +73,12 @@ HIDE_UNDOC_CLASSES = YES # standard output by doxygen. If QUIET is set to YES this implies that the # messages are off. -QUIET = YES +QUIET = NO + +# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns +# in which the alphabetical index list will be split. + +COLS_IN_ALPHA_INDEX = 1 #--------------------------------------------------------------------------- # Configuration options related to the input files diff --git a/travis.yml b/travis.yml index ef7d39221c..dba8b01e63 100644 --- a/travis.yml +++ b/travis.yml @@ -9,16 +9,16 @@ services: env: matrix: - - TYPE=debug OS=fedora OS_VER=30 PUSH_IMAGE=1 AUTO_DOC_UPDATE=1 - - TYPE=debug OS=ubuntu OS_VER=19.04 PUSH_IMAGE=1 - - TYPE=debug OS=ubuntu OS_VER=19.04 COVERAGE=1 - - TYPE=release OS=fedora OS_VER=30 - - TYPE=release OS=ubuntu OS_VER=19.04 - - TYPE=valgrind OS=ubuntu OS_VER=19.04 - - TYPE=memcheck_drd OS=ubuntu OS_VER=19.04 - - TYPE=coverity OS=ubuntu OS_VER=19.04 - - TYPE=package OS=ubuntu OS_VER=19.04 - - TYPE=package OS=fedora OS_VER=30 + - TYPE=debug OS=fedora OS_VER=32 PUSH_IMAGE=1 AUTO_DOC_UPDATE=1 + - TYPE=debug OS=ubuntu OS_VER=20.04 PUSH_IMAGE=1 + - TYPE=debug OS=ubuntu OS_VER=20.04 COVERAGE=1 + - TYPE=release OS=fedora OS_VER=32 + - TYPE=release OS=ubuntu OS_VER=20.04 + - TYPE=valgrind OS=ubuntu OS_VER=20.04 + - TYPE=memcheck_drd OS=ubuntu OS_VER=20.04 + - TYPE=coverity OS=ubuntu OS_VER=20.04 + - TYPE=package OS=ubuntu OS_VER=20.04 + - TYPE=package OS=fedora OS_VER=32 before_install: - echo $TRAVIS_COMMIT_RANGE diff --git a/utils/docker/images/Dockerfile.fedora-30 b/utils/docker/images/Dockerfile.fedora-32 similarity index 95% rename from utils/docker/images/Dockerfile.fedora-30 rename to utils/docker/images/Dockerfile.fedora-32 index 5475f4ae57..c8a16ff02e 100644 --- a/utils/docker/images/Dockerfile.fedora-30 +++ b/utils/docker/images/Dockerfile.fedora-32 @@ -35,7 +35,7 @@ # # Pull base image -FROM fedora:30 +FROM fedora:32 MAINTAINER marcin.slusarz@intel.com # Additional parameters to build docker without building components @@ -51,6 +51,7 @@ RUN dnf update -y \ bash-completion \ clang \ cmake \ + daxctl-devel \ doxygen \ gcc \ gdb \ @@ -65,6 +66,7 @@ RUN dnf update -y \ make \ man \ ncurses-devel \ + ndctl-devel \ open-sans-fonts \ passwd \ perl-Text-Diff \ @@ -80,10 +82,6 @@ RUN dnf update -y \ xmlto \ && dnf clean all -# Install libndctl -COPY install-libndctl.sh install-libndctl.sh -RUN ./install-libndctl.sh fedora - # Install valgrind COPY install-valgrind.sh install-valgrind.sh RUN ./install-valgrind.sh @@ -102,7 +100,7 @@ USER $USER # Set required environment variables ENV OS fedora -ENV OS_VER 30 +ENV OS_VER 32 ENV PACKAGE_MANAGER rpm ENV NOTTY 1 diff --git a/utils/docker/images/Dockerfile.ubuntu-19.04 b/utils/docker/images/Dockerfile.ubuntu-20.04 similarity index 95% rename from utils/docker/images/Dockerfile.ubuntu-19.04 rename to utils/docker/images/Dockerfile.ubuntu-20.04 index b57b8c815e..2c12cf2a80 100644 --- a/utils/docker/images/Dockerfile.ubuntu-19.04 +++ b/utils/docker/images/Dockerfile.ubuntu-20.04 @@ -35,7 +35,7 @@ # # Pull base image -FROM ubuntu:19.04 +FROM ubuntu:20.04 MAINTAINER marcin.slusarz@intel.com # Additional parameters to build docker without building components @@ -50,7 +50,7 @@ RUN apt-get update \ asciidoc \ autoconf \ clang \ - clang-format \ + clang-format-8 \ cmake \ curl \ debhelper \ @@ -60,9 +60,11 @@ RUN apt-get update \ gdb \ git \ graphviz \ + libdaxctl-dev \ libjson-c-dev \ libkmod-dev \ libncurses5-dev \ + libndctl-dev \ libsfml-dev \ libtbb-dev \ libtext-diff-perl \ @@ -78,10 +80,6 @@ RUN apt-get update \ whois \ && rm -rf /var/lib/apt/lists/* -# Install libndctl -COPY install-libndctl.sh install-libndctl.sh -RUN ./install-libndctl.sh - # Install valgrind COPY install-valgrind.sh install-valgrind.sh RUN ./install-valgrind.sh @@ -98,6 +96,6 @@ USER $USER # Set required environment variables ENV OS ubuntu -ENV OS_VER 19.04 +ENV OS_VER 20.04 ENV PACKAGE_MANAGER deb ENV NOTTY 1 diff --git a/utils/docker/images/build-image.sh b/utils/docker/images/build-image.sh index 7c6bec808e..f23155bf31 100755 --- a/utils/docker/images/build-image.sh +++ b/utils/docker/images/build-image.sh @@ -49,20 +49,20 @@ function usage { "current directory." } -# Check if the first and second argument is nonempty -if [[ -z "$1" || -z "$2" ]]; then +echo "Check if the first and second argument are nonempty: \"${1}\", \"${2}\"" +if [[ -z "${1}" || -z "${2}" ]]; then usage exit 1 fi -# Check if the file Dockerfile.OS-VER exists +echo "Check if the file Dockerfile.${1}-${2} exists" if [[ ! -f "Dockerfile.$2" ]]; then echo "ERROR: wrong argument." usage exit 1 fi -# Build a Docker image tagged with ${DOCKERHUB_REPO}:1.8-OS-VER +echo "Build a Docker image tagged with ${DOCKERHUB_REPO}:1.8-${1}-${2}" docker build -t $1:1.8-$2 \ --build-arg http_proxy=$http_proxy \ --build-arg https_proxy=$https_proxy \ diff --git a/utils/docker/images/install-libndctl.sh b/utils/docker/images/install-libndctl.sh deleted file mode 100755 index 5581f8cfab..0000000000 --- a/utils/docker/images/install-libndctl.sh +++ /dev/null @@ -1,92 +0,0 @@ -#!/usr/bin/env bash -# -# Copyright 2018-2019, Intel Corporation -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# -# * Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in -# the documentation and/or other materials provided with the -# distribution. -# -# * Neither the name of the copyright holder nor the names of its -# contributors may be used to endorse or promote products derived -# from this software without specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -# -# install-libndctl.sh - installs libndctl -# - -set -e - -OS=$1 - -echo "==== clone ndctl repo ====" -git clone https://github.com/pmem/ndctl.git -cd ndctl -git checkout tags/v60.1 - -if [ "$OS" = "fedora" ]; then - -echo "==== setup rpmbuild tree ====" -rpmdev-setuptree - -RPMDIR=$HOME/rpmbuild/ -VERSION=$(./git-version) -SPEC=./rhel/ndctl.spec - -echo "==== create source tarball =====" -git archive --format=tar --prefix="ndctl-${VERSION}/" HEAD | gzip > "$RPMDIR/SOURCES/ndctl-${VERSION}.tar.gz" - -echo "==== build ndctl ====" -./autogen.sh -./configure -make -j$(nproc) - -echo "==== update ndctl.spec ====" -# XXX: pre-process ndctl.spec to remove dependency on libpmem -# To be removed once ndctl v60 is available. -sed -i -e "/pkgconfig(libpmem)/d" -e "s/--with-libpmem//g" $SPEC - -echo "==== build ndctl packages ====" -rpmbuild -ba $SPEC - -echo "==== install ndctl packages ====" -rpm -i $RPMDIR/RPMS/x86_64/*.rpm - -echo "==== cleanup ====" -rm -rf $RPMDIR - -else - -echo "==== build ndctl ====" -./autogen.sh -./configure -make -j$(nproc) - -echo "==== install ndctl ====" -make -j$(nproc) install - -echo "==== cleanup ====" - -fi - -cd .. -rm -rf ndctl diff --git a/utils/docker/images/install-valgrind.sh b/utils/docker/images/install-valgrind.sh index b9686c2cea..96124aedce 100755 --- a/utils/docker/images/install-valgrind.sh +++ b/utils/docker/images/install-valgrind.sh @@ -43,11 +43,12 @@ fi git clone --recursive https://github.com/pmem/valgrind.git cd valgrind -# pmem-3.14: fix memcheck failure on Ubuntu-19.04 -git checkout 0965e35d7fd5c7941dc3f2a0c981cb8386c479d3 +# pmem-3.15: Merge pull request #81 from marcinslusarz/pmem-3.15 +git checkout 09f75f69683d862f8456f75484fcdc0dc5508900 + ./autogen.sh ./configure --prefix=/usr make -j$(nproc) -make -j$(nproc) install +sudo make -j$(nproc) install cd .. rm -rf valgrind diff --git a/utils/docker/images/push-image.sh b/utils/docker/images/push-image.sh index a4e63916cd..e4356c233c 100755 --- a/utils/docker/images/push-image.sh +++ b/utils/docker/images/push-image.sh @@ -49,14 +49,15 @@ function usage { "locally." } -# Check if the first argument is nonempty -if [[ -z "$1" ]]; then +OS__OS_VER=${1} +echo "Check if the first argument (OS-VER) is nonempty: \"${OS__OS_VER}\"" +if [[ -z "${OS__OS_VER}" ]]; then usage exit 1 fi -# Check if the image tagged with ${DOCKERHUB_REPO}:1.8-OS-VER exists locally -if [[ ! $(docker images -a | awk -v pattern="^${DOCKERHUB_REPO}:1.8-$1\$" \ +echo "Check if the image tagged with ${DOCKERHUB_REPO}:1.8-${OS__OS_VER} exists locally" +if [[ ! $(docker images -a | awk -v pattern="^${DOCKERHUB_REPO}:1.8-${OS__OS_VER}\$" \ '$1":"$2 ~ pattern') ]] then echo "ERROR: wrong argument." @@ -64,8 +65,8 @@ then exit 1 fi -# Log in to the Docker Hub +echo "Log in to the Docker Hub" docker login -u="$DOCKERHUB_USER" -p="$DOCKERHUB_PASSWORD" -# Push the image to the repository -docker push ${DOCKERHUB_REPO}:1.8-$1 +echo "Push the image to the repository" +docker push ${DOCKERHUB_REPO}:1.8-${OS__OS_VER}