Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mtxclient
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
mtxclient
Commits
6c00148e
Commit
6c00148e
authored
6 years ago
by
Konstantinos Sideris
Browse files
Options
Downloads
Patches
Plain Diff
Update travis script
parent
25ed2674
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.ci/install.sh
+23
-0
23 additions, 0 deletions
.ci/install.sh
.ci/script.sh
+40
-0
40 additions, 0 deletions
.ci/script.sh
.travis.yml
+3
-40
3 additions, 40 deletions
.travis.yml
with
66 additions
and
40 deletions
.ci/install.sh
0 → 100755
+
23
−
0
View file @
6c00148e
#!/bin/bash
set
-ex
if
[
$TRAVIS_OS_NAME
==
osx
]
;
then
brew update
brew upgrade boost cmake
brew
install
libsodium
fi
if
[
$TRAVIS_OS_NAME
==
linux
]
;
then
export
CXX
=
${
CXX_VERSION
}
export
CC
=
${
CC_VERSION
}
sudo
add-apt-repository
-y
ppa:chris-lea/libsodium
sudo
apt-get update
-qq
sudo
apt-get
install
-qq
-y
libsodium-dev
sudo
apt-get remove
-y
cmake
wget https://cmake.org/files/v3.11/cmake-3.11.4-Linux-x86_64.sh
sudo
sh cmake-3.11.4-Linux-x86_64.sh
--skip-license
--prefix
=
/usr/local
export
PATH
=
"/usr/local/bin:
$PATH
"
fi
This diff is collapsed.
Click to expand it.
.ci/script.sh
0 → 100755
+
40
−
0
View file @
6c00148e
#!/bin/bash
if
[
$TRAVIS_OS_NAME
==
linux
]
;
then
sudo
update-alternatives
--remove-all
gcc
sudo
update-alternatives
--remove-all
g++
export
CXX
=
${
CXX_VERSION
}
export
CC
=
${
CC_VERSION
}
sudo
update-alternatives
--install
/usr/bin/gcc gcc /usr/bin/
${
CC_VERSION
}
10
sudo
update-alternatives
--install
/usr/bin/g++ g++ /usr/bin/
${
CXX_VERSION
}
10
sudo
update-alternatives
--set
gcc
"/usr/bin/
${
CC_VERSION
}
"
sudo
update-alternatives
--set
g++
"/usr/bin/
${
CXX_VERSION
}
"
fi
# Build dependencies.
cmake
-Hdeps
-B
.deps
-DCMAKE_BUILD_TYPE
=
Release
\
-DUSE_BUNDLED_BOOST
=
${
USE_BUNDLED_BOOST
}
\
-DUSE_BUNDLED_GTEST
=
${
TESTS
}
cmake
--build
.deps
# Build the library.
cmake
-H
.
-Bbuild
-DOPENSSL_ROOT_DIR
=
${
OPENSLL_ROOT_DIR
}
\
-DBUILD_LIB_TESTS
=
${
TESTS
}
\
-DBUILD_SHARED_LIBS
=
ON
\
-DCMAKE_INSTALL_PREFIX
=
.deps/usr
\
-DCOVERAGE
=
${
COVERAGE
}
||
true
cmake
--build
build
# Unit & Integration tests
if
[
$TESTS
==
ON
]
;
then
make synapse
make
test
fi
# Linting
if
[
$LINT
==
ON
]
;
then
make lint
fi
This diff is collapsed.
Click to expand it.
.travis.yml
+
3
−
40
View file @
6c00148e
...
...
@@ -52,53 +52,16 @@ matrix:
-
"
g++-7"
install
:
-
if [[ "${CXX_VERSION}" != "" ]]; then export CXX=${CXX_VERSION}; fi
-
if [[ "${CC_VERSION}" != "" ]]; then export CC=${CC_VERSION}; fi
-
if [ $TRAVIS_OS_NAME == osx ]; then brew update && brew upgrade boost cmake && brew install libsodium; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then sudo add-apt-repository -y ppa:chris-lea/libsodium; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then sudo apt-get update -qq; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then sudo apt-get install -qq -y libsodium-dev; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then sudo apt-get remove -y cmake; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then wget https://cmake.org/files/v3.11/cmake-3.11.4-Linux-x86_64.sh; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then sudo sh cmake-3.11.4-Linux-x86_64.sh --skip-license --prefix=/usr/local; fi
-
if [ $TRAVIS_OS_NAME == linux ]; then export PATH="/usr/local/bin:$PATH"; fi
-
./.ci/install.sh
script
:
-
if [[ "${CXX_VERSION}" != "" ]]; then export CXX=${CXX_VERSION}; fi
-
if [[ "${CC_VERSION}" != "" ]]; then export CC=${CC_VERSION}; fi
-
$CXX --version
-
cmake --version
# Build dependencies.
-
cmake -Hdeps -B.deps -DCMAKE_BUILD_TYPE=Release
-DUSE_BUNDLED_BOOST=${USE_BUNDLED_BOOST}
-DUSE_BUNDLED_GTEST=${TESTS}
-
cmake --build .deps
# Build the library.
-
cmake -H. -Bbuild -DOPENSSL_ROOT_DIR=${OPENSLL_ROOT_DIR}
-DBUILD_LIB_TESTS=${TESTS}
-DBUILD_SHARED_LIBS=ON
-DCMAKE_INSTALL_PREFIX=.deps/usr
-DCOVERAGE=${COVERAGE} ||
true
-
cmake --build build
# Unit & Integration tests
-
if [ $TESTS == ON ]; then make synapse; fi
-
if [ $TESTS == ON ]; then make test; fi
# Linting
-
if [ $LINT == ON ]; then make lint; fi
-
./script.sh
after_success
:
# Generate coverage report and upload report to CodeCov.
-
if [ $COVERAGE == ON ]; then make -C build matrix_client_coverage; fi
# Generate coverage report.
-
if [ $COVERAGE == ON ]; then ./.ci/coverage.sh; fi
# Upload report to CodeCov.
-
if [ $COVERAGE == ON ]; then bash <(curl -s https://codecov.io/bash) -f "!*tests*" || echo "Codecov failed"; fi
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment