diff --git a/clibcni.spec b/clibcni.spec index 381b59bc62f052edea9a4fa0820c9b7081e23e22..90767dbba5f15b54ffe70d5bd711652a07e620eb 100644 --- a/clibcni.spec +++ b/clibcni.spec @@ -1,5 +1,5 @@ -%global _version 2.0.4 -%global _release 20201230.152647.gitf9277cd7 +%global _version 2.0.6 +%global _release 2 Name: clibcni Version: %{_version} Release: %{_release} @@ -10,9 +10,10 @@ URL: https://gitee.com/openeuler/clibcni Source0: https://gitee.com/openeuler/clibcni/repository/archive/v%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version} -BuildRequires: gcc + +BuildRequires: gcc git gcc-c++ BuildRequires: cmake -BuildRequires: lcr-devel yajl-devel +BuildRequires: lcr-devel yajl-devel gtest-devel Requires: lcr @@ -43,9 +44,13 @@ the %{name}-libs package contains libraries for running %{name} applications. %build mkdir -p build cd build -%cmake -DDEBUG=ON -DLIB_INSTALL_DIR=%{_libdir} ../ +%cmake -DDEBUG=ON -DENABLE_UT=ON -DLIB_INSTALL_DIR=%{_libdir} ../ %make_build +pushd tests +ctest -V +popd + %install rm -rf %{buildroot} cd build @@ -85,6 +90,36 @@ rm -rf %{buildroot} %{_libdir}/pkgconfig/%{name}.pc %changelog +* Thu Nov 16 2021 wujing - 2.0.6-2 +- Type: enhancement +- ID: NA +- SUG: NA +- DESC: remove build platform restrictions + +* Thu Nov 09 2021 haozi007 - 2.0.6-1 +- Type: upgrade version +- ID: NA +- SUG: NA +- DESC: upgrade to v2.0.6 + +* Mon Jun 28 2021 haozi007 - 2.0.4-20210628.190359.git14c104bc +- Type: add g++ to build require +- ID: NA +- SUG: NA +- DESC: add g++ to build require + +* Mon Jun 28 2021 haozi007 - 2.0.4-20210628.151504.git61ae9f6b +- Type: add git to build require +- ID: NA +- SUG: NA +- DESC: add git to build require + +* Sat May 8 2021 zhangxiaoyu - 2.0.4-20210508.150021.git73679d5d +- Type: sync from upstream +- ID: NA +- SUG: NA +- DESC: update from master + * Wed Dec 30 2020 lifeng - 2.0.4-20201230.152647.gitf9277cd7 - Type: update version to v2.0.4 - ID:NA diff --git a/update-version.bash b/update-version.sh similarity index 78% rename from update-version.bash rename to update-version.sh index df25f52e036da9c2b98ab9ac35c3fd0f3d6717be..87e68a0c2939345e6c508c302b196f2ae988a926 100755 --- a/update-version.bash +++ b/update-version.sh @@ -1,3 +1,7 @@ +#!/bin/bash +# +# usage +# ./update-version.bash ####################################################################### ##- @Copyright (C) Huawei Technologies Co., Ltd. 2019. All rights reserved. # - clibcni licensed under the Mulan PSL v2. @@ -12,18 +16,13 @@ ##- @Author: wujing ##- @Create: 2019-04-25 ####################################################################### -#!/bin/bash -# -# usage -# ./update-version.bash topDir=$(git rev-parse --show-toplevel) specfile="${topDir}/clibcni.spec" -CMakefile="${topDir}/CMakeLists.txt" old_version=$(cat ${specfile} | grep "%global" | grep "_version" | awk {'print $3'}) first_old_version=$(cat ${specfile} | grep "%global" | grep "_version" | awk {'print $3'} | awk -F "." {'print $1'}) second_old_version=$(cat ${specfile} | grep "%global" | grep "_version" | awk {'print $3'} | awk -F "." {'print $2'}) third_old_version=$(cat ${specfile} | grep "%global" | grep "_version" | awk {'print $3'} | awk -F "." {'print $3'}) -read -p "Which level version do you want to upgrade?[1/2/3/d/N](default:N) select:" choice +read -p "Which level version do you want to upgrade?[1/2/3/r/N](default:N) select:" choice if [[ ! -n "${choice}" || ${choice} == "N" ]]; then echo "The version number has not been modified, it is still ${old_version}" exit 0 @@ -42,15 +41,9 @@ fi new_version=${first_old_version}.${second_old_version}.${third_old_version} -echo "The version number has been modified: ${old_version} => ${new_version}" - old_release=$(cat ${specfile} | grep "%global" | grep "_release" | awk {'print $3'}) -commit_id_long=`git log --pretty=oneline -1 | awk {'print $1'}` -commit_id=${commit_id_long:0:8} -new_release=`date "+%Y%m%d"`.`date "+%H%M%S"`.git$commit_id -echo "The relase version has been modified, it is ${new_release}" -sed -i "s/set(CLIBCNI_VERSION \"${old_version}\")/set(CLIBCNI_VERSION \"${new_version}\")/g" ${CMakefile} +new_release=$(($old_release+1)) sed -i "s/^\%global _version ${old_version}$/\%global _version ${new_version}/g" ${specfile} sed -i "s/^\%global _release ${old_release}$/\%global _release ${new_release}/g" ${specfile} -echo "The release number has been modified: ${old_release} => ${new_release}" +echo "The release version has been modified: ${old_version}-${old_release} => ${new_version}-${new_release}" diff --git a/v2.0.4.tar.gz b/v2.0.4.tar.gz deleted file mode 100644 index 1bb723309bfb51b3b14e3494cb046cfef11fff57..0000000000000000000000000000000000000000 Binary files a/v2.0.4.tar.gz and /dev/null differ diff --git a/v2.0.6.tar.gz b/v2.0.6.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..ff9a6766ac3063974ca69e3d23fc18a3ec07b99d Binary files /dev/null and b/v2.0.6.tar.gz differ