summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoryangwei <[email protected]>2020-11-03 10:36:17 +0800
committeryangwei <[email protected]>2020-11-03 10:36:17 +0800
commit6bbc59264deebfea40e26618e08dd3c0c2b284b6 (patch)
tree73bc3e609be950d3e8edec885d860fc5585910af
parent8fdcb9ac35edfde674b2e6e0a441cb3ebc0ebde6 (diff)
🐎ci(ci): 增加发布testing源逻辑
-rw-r--r--.gitlab-ci.yml51
-rw-r--r--ci/travis.sh10
-rw-r--r--cmake/Version.cmake4
3 files changed, 22 insertions, 43 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 8774886..59b2507 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -48,6 +48,12 @@ develop_build_debug:
variables:
BUILD_TYPE: Debug
PACKAGE: 1
+ UPLOAD: 1
+ TESTING_VERSION_BUILD: 1
+ ENABLE_DEVEL_SWITCH: "ON"
+ ASAN_OPTION: ADDRESS
+ PULP3_REPO_NAME: platform-testing-x86_64.el7
+ PULP3_DIST_NAME: platform-testing-x86_64.el7
artifacts:
name: "tcpdump_mesa-$CI_COMMIT_REF_NAME-debug"
paths:
@@ -63,6 +69,12 @@ develop_build_release:
variables:
BUILD_TYPE: RelWithDebInfo
PACKAGE: 1
+ UPLOAD: 1
+ TESTING_VERSION_BUILD: 1
+ ENABLE_DEVEL_SWITCH: "ON"
+ ASAN_OPTION: "OFF"
+ PULP3_REPO_NAME: platform-testing-x86_64.el7
+ PULP3_DIST_NAME: platform-testing-x86_64.el7
artifacts:
name: "tcpdump_mesa-$CI_COMMIT_REF_NAME-release"
paths:
@@ -88,8 +100,6 @@ release_build_release:
- build/*.rpm
only:
- tags
- except:
- - /^v[0-9].*-testing$/i
release_build_release_devel:
stage: build
@@ -106,39 +116,4 @@ release_build_release_devel:
paths:
- build/*.rpm
only:
- - tags
- except:
- - /^v[0-9].*-testing$/i
-
-testing_build_release:
- stage: build
- variables:
- BUILD_TYPE: RelWithDebInfo
- PACKAGE: 1
- UPLOAD: 1
- PULP3_REPO_NAME: platform-testing-x86_64.el7
- PULP3_DIST_NAME: platform-testing-x86_64.el7
- extends: .build_by_travis
- artifacts:
- name: "tcpdump_mesa-$CI_COMMIT_REF_NAME-release"
- paths:
- - build/*.rpm
- only:
- - /^v[0-9].*-testing$/i
-
-testing_build_release_devel:
- stage: build
- variables:
- BUILD_TYPE: RelWithDebInfo
- ENABLE_DEVEL_SWITCH: "ON"
- PACKAGE: 1
- UPLOAD: 1
- PULP3_REPO_NAME: platform-testing-x86_64.el7
- PULP3_DIST_NAME: platform-testing-x86_64.el7
- extends: .build_by_travis
- artifacts:
- name: "tcpdump_mesa-$CI_COMMIT_REF_NAME-release"
- paths:
- - build/*.rpm
- only:
- - /^v[0-9].*-testing$/i \ No newline at end of file
+ - tags \ No newline at end of file
diff --git a/ci/travis.sh b/ci/travis.sh
index 4f07bdf..4d5f0f0 100644
--- a/ci/travis.sh
+++ b/ci/travis.sh
@@ -37,6 +37,11 @@ if [ -n "${INSTALL_DEPENDENCY_LIBRARY}" ]; then
yum install -y $INSTALL_DEPENDENCY_LIBRARY
source /etc/profile.d/framework.sh
fi
+
+if [ $ASAN_OPTION ];then
+ source /opt/rh/devtoolset-7/enable
+fi
+
mkdir build || true
cd build
@@ -58,8 +63,3 @@ if [ -n "${UPLOAD}" ]; then
python3 rpm_upload_tools.py ${PULP3_REPO_NAME} ${PULP3_DIST_NAME} *.rpm
fi
-#if [ -n "${UPLOAD_SYMBOL_FILES}" ]; then
-# rpm -i tfe*debuginfo*.rpm
-# cp /usr/lib/debug/opt/tsg/tfe/bin/tfe.debug /tmp/tfe.debuginfo.${CI_COMMIT_SHORT_SHA}
-# sentry-cli upload-dif -t elf /tmp/tfe.debuginfo.${CI_COMMIT_SHORT_SHA}
-#fi
diff --git a/cmake/Version.cmake b/cmake/Version.cmake
index 3722d0e..4a765e4 100644
--- a/cmake/Version.cmake
+++ b/cmake/Version.cmake
@@ -20,6 +20,10 @@ string(REGEX REPLACE "^v([0-9]+)\\..*" "\\1" VERSION_MAJOR "${VCS_TAG}")
string(REGEX REPLACE "^v[0-9]+\\.([0-9]+).*" "\\1" VERSION_MINOR "${VCS_TAG}")
string(REGEX REPLACE "^v[0-9]+\\.[0-9]+\\.([0-9]+).*" "\\1" VERSION_PATCH "${VCS_TAG}")
+if(VERSION_DAILY_BUILD)
+ set(VERSION_PATCH ${VERSION_PATCH}.${VERSION_DATE})
+endif()
+
if(NOT VERSION_MAJOR)
set(VERSION_MAJOR 1)
endif()