Skip to content
Snippets Groups Projects
Commit 1176632b authored by Sulverus's avatar Sulverus
Browse files

Tarantool cloud build

parent 0c2012eb
No related branches found
No related tags found
No related merge requests found
language: cpp sudo: required
services:
- docker
language: cpp
os: os:
- linux - linux
- osx - osx
...@@ -8,26 +11,92 @@ compiler: ...@@ -8,26 +11,92 @@ compiler:
- clang - clang
- gcc - gcc
matrix: env:
exclude: matrix:
- os: osx - OS=el DIST=6 PACK=rpm
compiler: gcc - OS=el DIST=7 PACK=rpm
- OS=fedora DIST=20 PACK=rpm
addons: - OS=fedora DIST=21 PACK=rpm
postgresql: "9.1" - OS=fedora DIST=22 PACK=rpm
- OS=fedora DIST=23 PACK=rpm
before_install: - OS=ubuntu DIST=trusty PACK=deb
- git submodule update --init --recursive - OS=ubuntu DIST=precise PACK=deb
- OS=ubuntu DIST=vivid PACK=deb
- OS=debian DIST=jessie PACK=deb
- OS=debian DIST=wheezy PACK=deb
- OS=debian DIST=stretch PACK=deb
- PACK=none
before_script: matrix:
- export PG='127.0.0.1:5432:tarantool:tarantool:tarantool' allow_failures:
- export MYSQL='127.0.0.1:3306:tarantool:tarantool:tarantool' - env: OS=el DIST=6 PACK=rpm
- env: OS=el DIST=7 PACK=rpm
- env: OS=fedora DIST=20 PACK=rpm
- env: OS=fedora DIST=21 PACK=rpm
- env: OS=fedora DIST=22 PACK=rpm
- env: OS=fedora DIST=23 PACK=rpm
- env: OS=ubuntu DIST=trusty PACK=deb
- env: OS=ubuntu DIST=precise PACK=deb
- env: OS=ubuntu DIST=vivid PACK=deb
- env: OS=debian DIST=jessie PACK=deb
- env: OS=debian DIST=wheezy PACK=deb
- env: OS=debian DIST=stretch PACK=deb
install: exclude:
- sh ./extra/travis/build_$TRAVIS_OS_NAME.sh - env: OS=el DIST=6 PACK=rpm
compiler: clang
- env: OS=el DIST=7 PACK=rpm
compiler: clang
- env: OS=fedora DIST=20 PACK=rpm
compiler: clang
- env: OS=fedora DIST=21 PACK=rpm
compiler: clang
- env: OS=fedora DIST=22 PACK=rpm
compiler: clang
- env: OS=fedora DIST=23 PACK=rpm
compiler: clang
- env: OS=ubuntu DIST=trusty PACK=deb
compiler: clang
- env: OS=ubuntu DIST=precise PACK=deb
compiler: clang
- env: OS=ubuntu DIST=vivid PACK=deb
compiler: clang
- env: OS=debian DIST=jessie PACK=deb
compiler: clang
- env: OS=debian DIST=wheezy PACK=deb
compiler: clang
- env: OS=debian DIST=stretch PACK=deb
compiler: clang
- env: OS=el DIST=6 PACK=rpm
os: osx
- env: OS=el DIST=7 PACK=rpm
os: osx
- env: OS=fedora DIST=20 PACK=rpm
os: osx
- env: OS=fedora DIST=21 PACK=rpm
os: osx
- env: OS=fedora DIST=22 PACK=rpm
os: osx
- env: OS=fedora DIST=23 PACK=rpm
os: osx
- env: OS=ubuntu DIST=trusty PACK=deb
os: osx
- env: OS=ubuntu DIST=precise PACK=deb
os: osx
- env: OS=ubuntu DIST=vivid PACK=deb
os: osx
- env: OS=debian DIST=jessie PACK=deb
os: osx
- env: OS=debian DIST=wheezy PACK=deb
os: osx
- env: OS=debian DIST=stretch PACK=deb
os: osx
- os: osx
compiler: gcc
script: script:
- sh ./extra/travis/test_$TRAVIS_OS_NAME.sh - git clone https://github.com/tarantool/build.git
- bash build/pack/travis.sh
notifications: notifications:
irc: irc:
...@@ -35,7 +104,7 @@ notifications: ...@@ -35,7 +104,7 @@ notifications:
- irc.freenode.net#tarantool - irc.freenode.net#tarantool
on_success: change on_success: change
on_failure: always on_failure: always
email: false email: true
git: git:
depth: 500 depth: 500
...@@ -23,21 +23,21 @@ if (RPMBUILD) ...@@ -23,21 +23,21 @@ if (RPMBUILD)
set (RPM_SOURCE_DIRECTORY_NAME ${CPACK_SOURCE_PACKAGE_FILE_NAME} set (RPM_SOURCE_DIRECTORY_NAME ${CPACK_SOURCE_PACKAGE_FILE_NAME}
CACHE STRING "" FORCE) CACHE STRING "" FORCE)
set (RPM_PACKAGE_SOURCE_FILE_NAME ${CPACK_SOURCE_PACKAGE_FILE_NAME}.tar.gz set (RPM_PACKAGE_SOURCE_FILE_NAME ${VERSION}.tar.gz
CACHE STRING "" FORCE) CACHE STRING "" FORCE)
set (RPM_BUILDROOT "${PROJECT_BINARY_DIR}/RPM/BUILDROOT" CACHE STRING "" FORCE) set (RPM_BUILDROOT "${PROJECT_BINARY_DIR}/RPM/BUILDROOT" CACHE STRING "" FORCE)
add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/${CPACK_SOURCE_PACKAGE_FILE_NAME}.tar.gz add_custom_command(OUTPUT ${PROJECT_BINARY_DIR}/${VERSION}.tar.gz
WORKING_DIRECTORY ${PROJECT_BINARY_DIR} WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
COMMAND $(MAKE) package_source) COMMAND $(MAKE) package_source && mv `ls *.tar.gz | head -n 1` ${VERSION}.tar.gz)
add_custom_command(OUTPUT ${RPM_BUILDROOT} add_custom_command(OUTPUT ${RPM_BUILDROOT}
COMMAND ${MKDIR} -p ${RPM_BUILDROOT}) COMMAND ${MKDIR} -p ${RPM_BUILDROOT})
add_custom_target(rpm_src add_custom_target(rpm_src
DEPENDS ${PROJECT_BINARY_DIR}/${CPACK_SOURCE_PACKAGE_FILE_NAME}.tar.gz DEPENDS ${PROJECT_BINARY_DIR}/${VERSION}.tar.gz
COMMAND ${RPMBUILD} --buildroot ${RPM_BUILDROOT} --define '_sourcedir ./' --define '_srcrpmdir ./' -bs ${PROJECT_SOURCE_DIR}/extra/rpm/tarantool.rpm.spec COMMAND ${RPMBUILD} --buildroot ${RPM_BUILDROOT} --define '_sourcedir ./' --define '_srcrpmdir ./' -bs ${PROJECT_SOURCE_DIR}/rpm/tarantool.spec
WORKING_DIRECTORY ${PROJECT_BINARY_DIR} WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
) )
......
add_subdirectory(dist) add_subdirectory(dist)
configure_file(rpm/tarantool.rpm.spec.in rpm/tarantool.rpm.spec @ONLY)
if (TARGET_OS_DARWIN) if (TARGET_OS_DARWIN)
# NOTE: need add execution 'plutil -lint org.tarantool.tarantool.plist # NOTE: need add execution 'plutil -lint org.tarantool.tarantool.plist
# to check syntax of plist file. # to check syntax of plist file.
......
sudo apt-get update > /dev/null sudo apt-get update > /dev/null
sudo apt-get -q install binutils-dev python-daemon python-yaml sudo apt-get -q -y install binutils-dev python-daemon python-yaml
sudo apt-get -q install libmysqlclient-dev libpq-dev postgresql-server-dev-all sudo apt-get -q -y install libmysqlclient-dev libpq-dev postgresql-server-dev-all
sudo pip install six==1.9.0 sudo pip install six==1.9.0
sudo pip install gevent sudo pip install gevent
sudo pip install geventconnpool sudo pip install geventconnpool
mkdir ./build && cd ./build && cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo cmake . -DCMAKE_BUILD_TYPE=RelWithDebInfo
make -j8 make -j8
cd ./build && make test || echo cd test
/usr/bin/python test-run.py --force
...@@ -13,6 +13,10 @@ ...@@ -13,6 +13,10 @@
%global __debug_install_post %{nil} %global __debug_install_post %{nil}
%global __debug_package %{nil} %global __debug_package %{nil}
%global build_version %(git describe --long | sed "s/[0-9]*\.[0-9]*\.[0-9]*-//" | sed "s/-[a-z 0-9]*//")
%global git_hash %(git describe --long | sed "s/.*-//")
%global prod_version %(git describe --long | sed "s/-[0-9]*-.*//")
%if (0%{?fedora} >= 15 || 0%{?rhel} >= 7) && %{undefined _with_systemd} %if (0%{?fedora} >= 15 || 0%{?rhel} >= 7) && %{undefined _with_systemd}
%global _with_systemd 1 %global _with_systemd 1
%endif %endif
...@@ -54,8 +58,8 @@ Requires(preun): initscripts ...@@ -54,8 +58,8 @@ Requires(preun): initscripts
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Name: %{?scl_prefix}tarantool Name: %{?scl_prefix}tarantool
Version: @RPM_PACKAGE_VERSION@ Version: %{prod_version}
Release: @RPM_PACKAGE_RELEASE@ Release: %{build_version}
Group: Applications/Databases Group: Applications/Databases
Summary: Tarantool - a NoSQL database in a Lua script Summary: Tarantool - a NoSQL database in a Lua script
Vendor: tarantool.org Vendor: tarantool.org
...@@ -65,7 +69,7 @@ Provides: %{?scl_prefix}tarantool-debuginfo ...@@ -65,7 +69,7 @@ Provides: %{?scl_prefix}tarantool-debuginfo
Provides: %{?scl_prefix}tarantool-debug Provides: %{?scl_prefix}tarantool-debug
Requires: %{?scl_prefix}tarantool-common Requires: %{?scl_prefix}tarantool-common
URL: http://tarantool.org URL: http://tarantool.org
Source0: @RPM_PACKAGE_SOURCE_FILE_NAME@ Source0: %{version}.tar.gz
%description %description
Tarantool is a high performance in-memory NoSQL database. It supports Tarantool is a high performance in-memory NoSQL database. It supports
replication, online backup, stored procedures in Lua. replication, online backup, stored procedures in Lua.
...@@ -78,7 +82,7 @@ scripts. ...@@ -78,7 +82,7 @@ scripts.
Summary: Tarantool C connector and header files Summary: Tarantool C connector and header files
Vendor: tarantool.org Vendor: tarantool.org
Group: Applications/Databases Group: Applications/Databases
Requires: %{?scl_prefix}tarantool = @RPM_PACKAGE_VERSION@-@RPM_PACKAGE_RELEASE@ Requires: %{?scl_prefix}tarantool = %{version}-%{release}
%description dev %description dev
Tarantool is a high performance in-memory NoSQL database. Tarantool is a high performance in-memory NoSQL database.
It supports replication, online backup, stored procedures in Lua. It supports replication, online backup, stored procedures in Lua.
...@@ -103,7 +107,7 @@ This package provides common files ...@@ -103,7 +107,7 @@ This package provides common files
################################################################## ##################################################################
%prep %prep
%setup -n @RPM_SOURCE_DIRECTORY_NAME@ %setup -q -c tarantool-%{version}
%build %build
# https://fedoraproject.org/wiki/Packaging:RPMMacros # https://fedoraproject.org/wiki/Packaging:RPMMacros
......
bash ./extra/travis/build_$TRAVIS_OS_NAME.sh
bash ./extra/travis/test_$TRAVIS_OS_NAME.sh
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment