Tarantool development patches archive
 help / color / mirror / Atom feed
* [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool
@ 2021-01-25 19:14 Igor Munkin via Tarantool-patches
  2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 1/2] github-ci: purge Debian Jessie from CI Igor Munkin via Tarantool-patches
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Igor Munkin via Tarantool-patches @ 2021-01-25 19:14 UTC (permalink / raw)
  To: Alexander V. Tikhonov, Kirill Yukhin; +Cc: tarantool-patches

This series contains auxiliary activities required for this issue[1].

The second and main patch updates Tarantool build infrastructure to use
CMake 3.1 or newer. Since this CMake release[2] the vital for LuaJIT
testing environment feature is introduced: one can use generator
expressions[3] in target DEPENDS section. This CMake feature is used to
pass either Tarantool binary or LuaJIT binary to the newly implemented
testing machinery with no changes in it.

Unfortunately, not all distributions provides CMake 3.1 or newer from their
repositories. Here is the actual list of default packages providing CMake
for the distributions that support Tarantool:
| Distro             | CMake version | Repo                |
|--------------------+---------------+---------------------|
| CentOS 6           | 2.8.12        | base                |
| CentOS 7           | 2.8.12        | base                |
| CentOS 8           | 3.11.4        | appstream           |
| Debian Jessie      | 3.0.2         | jessie/main         |
| Debian Stretch     | 3.7.2         | stretch/main        |
| Debian Buster      | 3.13.4        | buster/main         |
| Fedora 28          | 3.14.4        | updates             |
| Fedora 29          | 3.14.5        | updates             |
| Fedora 30          | 3.17.2        | updates             |
| Fedora 31          | 3.17.4        | updates             |
| Fedora 32          | 3.17.4        | updates             |
| FreeBSD 12         | 3.15.5        | default             |
| OSX 14             | 3.19.3        | brew                |
| OSX 15             | 3.19.3        | brew                |
| Ubuntu 14.04       | 2.8.12        | trusty/main         |
| Ubuntu 16.04       | 3.5.1         | xenial-updates/main |
| Ubuntu 18.04       | 3.10.2        | bionic-updates/main |
| Ubuntu 20.04       | 3.16.3        | focal/main          |
| openSUSE Leap 15.1 | 3.10.2        | Main                |
| openSUSE Leap 15.2 | 3.17.0        | Main                |

As one can see, there are no required packages provided by default for
the following old distributions: CentOS 6, CentOS 7, Debian Jessie and
Ubuntu 14.04. There are alternative packages (i.e. cmake3) providing a
newer CMake than the default one for the old packages:
| Distro             | CMake3 version  | Repo                    |
|--------------------+-----------------+-------------------------|
| CentOS 6           | 3.6.1           | epel*                   |
| CentOS 7           | 3.17.5          | epel*                   |
| Ubuntu 14.04       | 3.5.1           | trusty-updates/universe |

(*) Unfortunately, I failed to find the way to make rpmbuild install and
    enable EPEL repository prior to the build step. However, cmake3
    requirement obligues user to enable EPEL by himself, otherwise this
    dependency is left unmet. If there are any issues with building an
    RPM on CentOS 7 please proceed to the docs:
    https://www.tarantool.io/en/doc/latest/dev_guide/building_from_source/

So the last problem is Debian Jessie: the required CMake toolchain is
provided neither via the default repository nor via the auxiliary one
(e.g. updates like it's done for Ubuntu 14.04). Anyway, Debian Jessie
long term support has reached its EOL[4], so we can freely drop this
distribution from our regular building testing. This is done in the
first patch of this series.

NB: Be careful with updating CMake to 3.1 in CMakeLists. The following
patch breaks Tarantool build.
| diff --git a/CMakeLists.txt b/CMakeLists.txt
| index 4fbd19558..6dc78fa88 100644
| --- a/CMakeLists.txt
| +++ b/CMakeLists.txt
| @@ -1,4 +1,4 @@
| -cmake_minimum_required(VERSION 2.8)
| +cmake_minimum_required(VERSION 3.1)
|  
|  project(tarantool C CXX)
|  

Surprisingly, as a result of this change -Wno-gnu-alignof-expression
flag is removed from CFLAGS and the build fails on OSX with the
following error[5]:
| /tarantool/src/box/field_map.c:69:36: error: '_Alignof' applied to an expression is a GNU extension [-Werror,-Wgnu-alignof-expression]
|                 region_aligned_alloc(region, sz, alignof(*extent));
|                                                  ^
| /Library/Developer/CommandLineTools/usr/lib/clang/12.0.0/include/stdalign.h:15:17: note: expanded from macro 'alignof'
| #define alignof _Alignof
|                 ^
| 1 error generated.

Anyway, I believe this is out of the scope of this series, so I just
leave this for the further CMake upgrade endeavors.

Changes in v2:
  * Adjust the series in accordance with recently merged PRs moving all
    build jobs to GitHub CI[6], removing CentOS 6 CI pipeline[7] and
    introducing Fedora 33 build job to CI[8].
  * Moved some parts of cover letter to commit messages.

[1]: https://github.com/tarantool/tarantool/issues/4862
[2]: https://cmake.org/cmake/help/latest/release/3.1.html#commands
[3]: https://cmake.org/cmake/help/v3.1/manual/cmake-generator-expressions.7.html
[4]: https://www.debian.org/News/2020/20200709
[5]: https://gitlab.com/tarantool/tarantool/-/pipelines/243423841
[6]: https://github.com/tarantool/tarantool/pull/5724
[7]: https://github.com/tarantool/tarantool/pull/5729
[8]: https://github.com/tarantool/tarantool/pull/5707

Branch: https://github.com/tarantool/tarantool/tree/imun/cmake3-toolchain
V1: https://lists.tarantool.org/tarantool-patches/20210120184230.GC5460@tarantool.org/T/#t
Issue: https://github.com/tarantool/tarantool/issues/4862
CI is green but I can't share a single link to it after the changes in
#5724, so please check whether there is a green tick everywhere for the
top commit on the mentioned branch.

@ChangeLog:
| * Updated CMake minimum required version in Tarantool build
|   infrastructure to 3.1.

Igor Munkin (2):
  github-ci: purge Debian Jessie from CI
  build: update CMake minimum version to 3.1

 .github/workflows/debian_8.yml | 58 ----------------------------------
 debian/control                 |  9 +++++-
 rpm/tarantool.spec             | 30 ++++++++++++++++--
 3 files changed, 35 insertions(+), 62 deletions(-)
 delete mode 100644 .github/workflows/debian_8.yml

-- 
2.25.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Tarantool-patches] [PATCH v2 1/2] github-ci: purge Debian Jessie from CI
  2021-01-25 19:14 [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Igor Munkin via Tarantool-patches
@ 2021-01-25 19:14 ` Igor Munkin via Tarantool-patches
  2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 2/2] build: update CMake minimum version to 3.1 Igor Munkin via Tarantool-patches
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Igor Munkin via Tarantool-patches @ 2021-01-25 19:14 UTC (permalink / raw)
  To: Alexander V. Tikhonov, Kirill Yukhin; +Cc: tarantool-patches

CMake 3.1 or newer is essential for implementing LuaJIT self-sufficient
testing environment (see more info in the next patch). Unfortunately,
not all distributions provide the required CMake from the repositories.
Here is the actual list of default packages providing CMake for the
distributions that support Tarantool:
| Distro             | CMake version | Repo                |
|--------------------+---------------+---------------------|
| CentOS 6           | 2.8.12        | base                |
| CentOS 7           | 2.8.12        | base                |
| CentOS 8           | 3.11.4        | appstream           |
| Debian Jessie      | 3.0.2         | jessie/main         |
| Debian Stretch     | 3.7.2         | stretch/main        |
| Debian Buster      | 3.13.4        | buster/main         |
| Fedora 28          | 3.14.4        | updates             |
| Fedora 29          | 3.14.5        | updates             |
| Fedora 30          | 3.17.2        | updates             |
| Fedora 31          | 3.17.4        | updates             |
| Fedora 32          | 3.17.4        | updates             |
| FreeBSD 12         | 3.15.5        | default             |
| OSX 14             | 3.19.3        | brew                |
| OSX 15             | 3.19.3        | brew                |
| Ubuntu 14.04       | 2.8.12        | trusty/main         |
| Ubuntu 16.04       | 3.5.1         | xenial-updates/main |
| Ubuntu 18.04       | 3.10.2        | bionic-updates/main |
| Ubuntu 20.04       | 3.16.3        | focal/main          |
| openSUSE Leap 15.1 | 3.10.2        | Main                |
| openSUSE Leap 15.2 | 3.17.0        | Main                |

As one can see, there are no required packages provided by default for
the following distributions: CentOS 6, CentOS 7, Debian Jessie and
Ubuntu 14.04. There are alternative packages (i.e. cmake3) providing a
newer CMake than the default one for the old packages:
| Distro             | CMake3 version  | Repo                    |
|--------------------+-----------------+-------------------------|
| CentOS 6           | 3.6.1           | epel*                   |
| CentOS 7           | 3.17.5          | epel*                   |
| Ubuntu 14.04       | 3.5.1           | trusty-updates/universe |

(*) Unfortunately, I failed to find the way to make rpmbuild install
    and enable EPEL repository prior to the build step. However,
    cmake3 requirement obligues user to enable EPEL by himself,
    otherwise this dependency is left unmet. If there are any issues
    with building an RPM on CentOS 7 please proceed to the docs[1]

So the last problem is Debian Jessie: the required CMake toolchain is
provided neither via the default repository nor via the auxiliary one
(e.g. kinda updates repository like it's done for Ubuntu 14.04). Anyway,
Debian Jessie long term support has reached its EOL[2], so we can freely
drop this distribution from our regular build testing.

[1]: https://www.tarantool.io/en/doc/latest/dev_guide/building_from_source/
[2]: https://www.debian.org/News/2020/20200709

Relates to #4862

Signed-off-by: Igor Munkin <imun@tarantool.org>
---
 .github/workflows/debian_8.yml | 58 ----------------------------------
 1 file changed, 58 deletions(-)
 delete mode 100644 .github/workflows/debian_8.yml

diff --git a/.github/workflows/debian_8.yml b/.github/workflows/debian_8.yml
deleted file mode 100644
index fe7fdfe6b..000000000
--- a/.github/workflows/debian_8.yml
+++ /dev/null
@@ -1,58 +0,0 @@
-name: debian_8
-
-on: [push, pull_request]
-
-env:
-  CI_MAKE: make -f .gitlab.mk
-
-jobs:
-  debian_8:
-    # We want to run on external PRs, but not on our own internal PRs
-    # as they'll be run by the push to the branch.
-    if: github.event_name == 'push' ||
-        github.event.pull_request.head.repo.full_name != github.repository
-
-    runs-on: ubuntu-latest
-
-    strategy:
-      fail-fast: false
-
-    steps:
-      - uses: actions/checkout@v2.3.4
-        with:
-          fetch-depth: 0
-          submodules: recursive
-      - name: packaging
-        env:
-          # Our testing expects that the init process (PID 1) will
-          # reap orphan processes. At least the following test leans
-          # on it: app-tap/gh-4983-tnt-e-assert-false-hangs.test.lua.
-          PACKPACK_EXTRA_DOCKER_RUN_PARAMS: '--init'
-          AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
-          AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
-          AWS_S3_ENDPOINT_URL: ${{ secrets.AWS_S3_ENDPOINT_URL }}
-          LIVE_REPO_S3_DIR: ${{ secrets.LIVE_REPO_S3_DIR }}
-          RELEASE_REPO_S3_DIR: ${{ secrets.RELEASE_REPO_S3_DIR }}
-          GPG_SECRET_KEY: ${{ secrets.GPG_SECRET_KEY }}
-          GPG_SIGN_KEY: ${{ secrets.GPG_SIGN_KEY }}
-        run: |
-          if ${{ github.event_name == 'push' &&
-              ( github.ref == 'refs/heads/master' ||
-                github.ref == 'refs/heads/1.10' ||
-                startsWith(github.ref, 'refs/heads/2.') ||
-                startsWith(github.ref, 'refs/tags') ) }} ; then
-            sudo apt-get -y update
-            sudo apt-get install -y procmail createrepo awscli reprepro
-            mkdir -p ~/.gnupg
-            echo 'digest-algo sha256' >> ~/.gnupg/gpg.conf
-            OS=debian DIST=jessie ${CI_MAKE} deploy
-          else
-            OS=debian DIST=jessie ${CI_MAKE} package
-          fi
-      - name: artifacts
-        uses: actions/upload-artifact@v2
-        if: failure()
-        with:
-          name: debian-jessie
-          retention-days: 21
-          path: test/var/artifacts
-- 
2.25.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Tarantool-patches] [PATCH v2 2/2] build: update CMake minimum version to 3.1
  2021-01-25 19:14 [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Igor Munkin via Tarantool-patches
  2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 1/2] github-ci: purge Debian Jessie from CI Igor Munkin via Tarantool-patches
@ 2021-01-25 19:14 ` Igor Munkin via Tarantool-patches
  2021-01-25 19:47 ` [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Alexander V. Tikhonov via Tarantool-patches
  2021-01-27 13:09 ` Kirill Yukhin via Tarantool-patches
  3 siblings, 0 replies; 6+ messages in thread
From: Igor Munkin via Tarantool-patches @ 2021-01-25 19:14 UTC (permalink / raw)
  To: Alexander V. Tikhonov, Kirill Yukhin; +Cc: tarantool-patches

In scope of implementing self-sufficient testing environment LuaJIT
build system is partially ported to CMake. While integrating the new
build system with Tarantool it was found (on practice of course) that
using generator expressions[1] in target DEPENDS section is introduced
only in CMake 3.1[2]. This CMake feature is used to pass so called
"LuaJIT binary" to be used in LuaJIT tests, so one can run the same
testing machinery with both Tarantool and LuaJIT with no changes in it.

[1]: https://cmake.org/cmake/help/v3.1/manual/cmake-generator-expressions.7.html
[2]: https://cmake.org/cmake/help/latest/release/3.1.html#commands

Relates to #4862

Signed-off-by: Igor Munkin <imun@tarantool.org>

@TarantoolBot document
Title: Update CMake minimum required version in build documentation

This commit updates the CMake minimum required version to be used in
Tarantool build infrastructure. However, one can build Tarantool from
sources and the required toolchain list should be updated. CMake minimum
required version is 3.1 since this commit. See the commit message for
more info.

Signed-off-by: Igor Munkin <imun@tarantool.org>
---
 debian/control     |  9 ++++++++-
 rpm/tarantool.spec | 30 +++++++++++++++++++++++++++---
 2 files changed, 35 insertions(+), 4 deletions(-)

diff --git a/debian/control b/debian/control
index 8be2e9d01..ce810ee67 100644
--- a/debian/control
+++ b/debian/control
@@ -5,7 +5,14 @@ Uploaders: Dmitry E. Oboukhov <unera@debian.org>
 Build-Depends: cdbs (>= 0.4.100), debhelper (>= 9), dpkg-dev (>= 1.16.1~),
 # Enable systemd for Debian Jessie+ and Ubuntu Wily+
  debhelper (>= 9.20160709) | dh-systemd (>= 1.22) | sysvinit (<< 2.88dsf-59) | upstart (<< 1.13),
- cmake,
+# XXX: This is a tiny hack to support Tarantool build on the old
+# distributions (e.g. Ubuntu Trusty Tahr) providing CMake 3+ via
+# cmake3 package that conflicts and replaces cmake package (that
+# provides CMake 2.18). Alternatives resolution order allows to
+# make package manager seek for cmake3 package at first and use it
+# if found or fallback to cmake package (that provides CMake 3+
+# for modern distributions) otherwise.
+ cmake3 (>= 3.1) | cmake (>= 3.1),
  libreadline-dev,
  libncurses5-dev,
  libssl-dev,
diff --git a/rpm/tarantool.spec b/rpm/tarantool.spec
index 8ba14d4d0..ffd161862 100644
--- a/rpm/tarantool.spec
+++ b/rpm/tarantool.spec
@@ -5,7 +5,24 @@
 %bcond_with systemd
 %endif
 
-BuildRequires: cmake >= 2.8
+# XXX: There is an old CMake (2.8.12) provided by cmake package in
+# main CentOS 7 repositories. At the same time, there is a newer
+# package cmake3 providing CMake 3+ from EPEL repository. So, one
+# need to use cmake3 package to build Tarantool on old systems.
+%define use_cmake3 0%{?rhel} == 7
+
+%if %use_cmake3
+# XXX: Unfortunately there is no way to make rpmbuild install and
+# enable EPEL repository prior to the build step. However, the
+# requirement below obligues user to enable EPEL by himself,
+# otherwise this dependency is left unmet. If there are any issues
+# with building an RPM package on RHEL/CentOS 7 read the docs:
+# https://www.tarantool.io/en/doc/latest/dev_guide/building_from_source/
+BuildRequires: cmake3 >= 3.1
+%else
+BuildRequires: cmake >= 3.1
+%endif
+
 BuildRequires: make
 %if (0%{?fedora} >= 22 || 0%{?rhel} >= 7 || 0%{?sle_version} >= 1500)
 BuildRequires: gcc >= 4.5
@@ -115,7 +132,7 @@ Requires: openssl
 # RHEL <= 7 doesn't support Recommends:
 Recommends: tarantool-devel
 Recommends: git-core
-Recommends: cmake >= 2.8
+Recommends: cmake >= 3.1
 Recommends: make
 Recommends: gcc >= 4.5
 Recommends: gcc-c++ >= 4.5
@@ -154,7 +171,14 @@ C and Lua/C modules.
 # 2. -DENABLE_LTO=ON
 #    because for now LTO flags are set in CC/LD flags by default:
 #      '-flto=auto -ffat-lto-objects'
-%cmake -B . \
+# XXX: KISS, please. I can play with RPM macros to redefine cmake
+# macro for cmake3 usage, but it totally doesn't worth it.
+%if %use_cmake3
+%cmake3 \
+%else
+%cmake \
+%endif
+       -B . \
          -DCMAKE_BUILD_TYPE=RelWithDebInfo \
          -DCMAKE_INSTALL_LOCALSTATEDIR:PATH=%{_localstatedir} \
          -DCMAKE_INSTALL_SYSCONFDIR:PATH=%{_sysconfdir} \
-- 
2.25.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool
  2021-01-25 19:14 [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Igor Munkin via Tarantool-patches
  2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 1/2] github-ci: purge Debian Jessie from CI Igor Munkin via Tarantool-patches
  2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 2/2] build: update CMake minimum version to 3.1 Igor Munkin via Tarantool-patches
@ 2021-01-25 19:47 ` Alexander V. Tikhonov via Tarantool-patches
  2021-01-25 20:23   ` Igor Munkin via Tarantool-patches
  2021-01-27 13:09 ` Kirill Yukhin via Tarantool-patches
  3 siblings, 1 reply; 6+ messages in thread
From: Alexander V. Tikhonov via Tarantool-patches @ 2021-01-25 19:47 UTC (permalink / raw)
  To: Igor Munkin; +Cc: tarantool-patches

Hi Igor, thanks for the patch set. It looks great with lots of
information, it LTGM.

On Mon, Jan 25, 2021 at 10:14:41PM +0300, Igor Munkin wrote:
> This series contains auxiliary activities required for this issue[1].
> 
> The second and main patch updates Tarantool build infrastructure to use
> CMake 3.1 or newer. Since this CMake release[2] the vital for LuaJIT
> testing environment feature is introduced: one can use generator
> expressions[3] in target DEPENDS section. This CMake feature is used to
> pass either Tarantool binary or LuaJIT binary to the newly implemented
> testing machinery with no changes in it.
> 
> Unfortunately, not all distributions provides CMake 3.1 or newer from their
> repositories. Here is the actual list of default packages providing CMake
> for the distributions that support Tarantool:
> | Distro             | CMake version | Repo                |
> |--------------------+---------------+---------------------|
> | CentOS 6           | 2.8.12        | base                |
> | CentOS 7           | 2.8.12        | base                |
> | CentOS 8           | 3.11.4        | appstream           |
> | Debian Jessie      | 3.0.2         | jessie/main         |
> | Debian Stretch     | 3.7.2         | stretch/main        |
> | Debian Buster      | 3.13.4        | buster/main         |
> | Fedora 28          | 3.14.4        | updates             |
> | Fedora 29          | 3.14.5        | updates             |
> | Fedora 30          | 3.17.2        | updates             |
> | Fedora 31          | 3.17.4        | updates             |
> | Fedora 32          | 3.17.4        | updates             |
> | FreeBSD 12         | 3.15.5        | default             |
> | OSX 14             | 3.19.3        | brew                |
> | OSX 15             | 3.19.3        | brew                |
> | Ubuntu 14.04       | 2.8.12        | trusty/main         |
> | Ubuntu 16.04       | 3.5.1         | xenial-updates/main |
> | Ubuntu 18.04       | 3.10.2        | bionic-updates/main |
> | Ubuntu 20.04       | 3.16.3        | focal/main          |
> | openSUSE Leap 15.1 | 3.10.2        | Main                |
> | openSUSE Leap 15.2 | 3.17.0        | Main                |
> 
> As one can see, there are no required packages provided by default for
> the following old distributions: CentOS 6, CentOS 7, Debian Jessie and
> Ubuntu 14.04. There are alternative packages (i.e. cmake3) providing a
> newer CMake than the default one for the old packages:
> | Distro             | CMake3 version  | Repo                    |
> |--------------------+-----------------+-------------------------|
> | CentOS 6           | 3.6.1           | epel*                   |
> | CentOS 7           | 3.17.5          | epel*                   |
> | Ubuntu 14.04       | 3.5.1           | trusty-updates/universe |
> 
> (*) Unfortunately, I failed to find the way to make rpmbuild install and
>     enable EPEL repository prior to the build step. However, cmake3
>     requirement obligues user to enable EPEL by himself, otherwise this
>     dependency is left unmet. If there are any issues with building an
>     RPM on CentOS 7 please proceed to the docs:
>     https://www.tarantool.io/en/doc/latest/dev_guide/building_from_source/
> 
> So the last problem is Debian Jessie: the required CMake toolchain is
> provided neither via the default repository nor via the auxiliary one
> (e.g. updates like it's done for Ubuntu 14.04). Anyway, Debian Jessie
> long term support has reached its EOL[4], so we can freely drop this
> distribution from our regular building testing. This is done in the
> first patch of this series.
> 
> NB: Be careful with updating CMake to 3.1 in CMakeLists. The following
> patch breaks Tarantool build.
> | diff --git a/CMakeLists.txt b/CMakeLists.txt
> | index 4fbd19558..6dc78fa88 100644
> | --- a/CMakeLists.txt
> | +++ b/CMakeLists.txt
> | @@ -1,4 +1,4 @@
> | -cmake_minimum_required(VERSION 2.8)
> | +cmake_minimum_required(VERSION 3.1)
> |  
> |  project(tarantool C CXX)
> |  
> 
> Surprisingly, as a result of this change -Wno-gnu-alignof-expression
> flag is removed from CFLAGS and the build fails on OSX with the
> following error[5]:
> | /tarantool/src/box/field_map.c:69:36: error: '_Alignof' applied to an expression is a GNU extension [-Werror,-Wgnu-alignof-expression]
> |                 region_aligned_alloc(region, sz, alignof(*extent));
> |                                                  ^
> | /Library/Developer/CommandLineTools/usr/lib/clang/12.0.0/include/stdalign.h:15:17: note: expanded from macro 'alignof'
> | #define alignof _Alignof
> |                 ^
> | 1 error generated.
> 
> Anyway, I believe this is out of the scope of this series, so I just
> leave this for the further CMake upgrade endeavors.
> 
> Changes in v2:
>   * Adjust the series in accordance with recently merged PRs moving all
>     build jobs to GitHub CI[6], removing CentOS 6 CI pipeline[7] and
>     introducing Fedora 33 build job to CI[8].
>   * Moved some parts of cover letter to commit messages.
> 
> [1]: https://github.com/tarantool/tarantool/issues/4862
> [2]: https://cmake.org/cmake/help/latest/release/3.1.html#commands
> [3]: https://cmake.org/cmake/help/v3.1/manual/cmake-generator-expressions.7.html
> [4]: https://www.debian.org/News/2020/20200709
> [5]: https://gitlab.com/tarantool/tarantool/-/pipelines/243423841
> [6]: https://github.com/tarantool/tarantool/pull/5724
> [7]: https://github.com/tarantool/tarantool/pull/5729
> [8]: https://github.com/tarantool/tarantool/pull/5707
> 
> Branch: https://github.com/tarantool/tarantool/tree/imun/cmake3-toolchain
> V1: https://lists.tarantool.org/tarantool-patches/20210120184230.GC5460@tarantool.org/T/#t
> Issue: https://github.com/tarantool/tarantool/issues/4862
> CI is green but I can't share a single link to it after the changes in
> #5724, so please check whether there is a green tick everywhere for the
> top commit on the mentioned branch.
> 
> @ChangeLog:
> | * Updated CMake minimum required version in Tarantool build
> |   infrastructure to 3.1.
> 
> Igor Munkin (2):
>   github-ci: purge Debian Jessie from CI
>   build: update CMake minimum version to 3.1
> 
>  .github/workflows/debian_8.yml | 58 ----------------------------------
>  debian/control                 |  9 +++++-
>  rpm/tarantool.spec             | 30 ++++++++++++++++--
>  3 files changed, 35 insertions(+), 62 deletions(-)
>  delete mode 100644 .github/workflows/debian_8.yml
> 
> -- 
> 2.25.0
> 

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool
  2021-01-25 19:47 ` [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Alexander V. Tikhonov via Tarantool-patches
@ 2021-01-25 20:23   ` Igor Munkin via Tarantool-patches
  0 siblings, 0 replies; 6+ messages in thread
From: Igor Munkin via Tarantool-patches @ 2021-01-25 20:23 UTC (permalink / raw)
  To: Alexander V. Tikhonov; +Cc: tarantool-patches

Sasha,

Thanks for your review!

On 25.01.21, Alexander V. Tikhonov wrote:
> Hi Igor, thanks for the patch set. It looks great with lots of
> information, it LTGM.

Added your tag:
| Reviewed-by: Alexander V. Tikhonov <avtikhon@tarantool.org>

> 

<snipped>

-- 
Best regards,
IM

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool
  2021-01-25 19:14 [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Igor Munkin via Tarantool-patches
                   ` (2 preceding siblings ...)
  2021-01-25 19:47 ` [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Alexander V. Tikhonov via Tarantool-patches
@ 2021-01-27 13:09 ` Kirill Yukhin via Tarantool-patches
  3 siblings, 0 replies; 6+ messages in thread
From: Kirill Yukhin via Tarantool-patches @ 2021-01-27 13:09 UTC (permalink / raw)
  To: Igor Munkin; +Cc: tarantool-patches

Hello,


On 25 янв 22:14, Igor Munkin wrote:
> This series contains auxiliary activities required for this issue[1].
> 
> The second and main patch updates Tarantool build infrastructure to use
> CMake 3.1 or newer. Since this CMake release[2] the vital for LuaJIT
> testing environment feature is introduced: one can use generator
> expressions[3] in target DEPENDS section. This CMake feature is used to
> pass either Tarantool binary or LuaJIT binary to the newly implemented
> testing machinery with no changes in it.
> 
> Unfortunately, not all distributions provides CMake 3.1 or newer from their
> repositories. Here is the actual list of default packages providing CMake
> for the distributions that support Tarantool:
> | Distro             | CMake version | Repo                |
> |--------------------+---------------+---------------------|
> | CentOS 6           | 2.8.12        | base                |
> | CentOS 7           | 2.8.12        | base                |
> | CentOS 8           | 3.11.4        | appstream           |
> | Debian Jessie      | 3.0.2         | jessie/main         |
> | Debian Stretch     | 3.7.2         | stretch/main        |
> | Debian Buster      | 3.13.4        | buster/main         |
> | Fedora 28          | 3.14.4        | updates             |
> | Fedora 29          | 3.14.5        | updates             |
> | Fedora 30          | 3.17.2        | updates             |
> | Fedora 31          | 3.17.4        | updates             |
> | Fedora 32          | 3.17.4        | updates             |
> | FreeBSD 12         | 3.15.5        | default             |
> | OSX 14             | 3.19.3        | brew                |
> | OSX 15             | 3.19.3        | brew                |
> | Ubuntu 14.04       | 2.8.12        | trusty/main         |
> | Ubuntu 16.04       | 3.5.1         | xenial-updates/main |
> | Ubuntu 18.04       | 3.10.2        | bionic-updates/main |
> | Ubuntu 20.04       | 3.16.3        | focal/main          |
> | openSUSE Leap 15.1 | 3.10.2        | Main                |
> | openSUSE Leap 15.2 | 3.17.0        | Main                |
> 
> As one can see, there are no required packages provided by default for
> the following old distributions: CentOS 6, CentOS 7, Debian Jessie and
> Ubuntu 14.04. There are alternative packages (i.e. cmake3) providing a
> newer CMake than the default one for the old packages:
> | Distro             | CMake3 version  | Repo                    |
> |--------------------+-----------------+-------------------------|
> | CentOS 6           | 3.6.1           | epel*                   |
> | CentOS 7           | 3.17.5          | epel*                   |
> | Ubuntu 14.04       | 3.5.1           | trusty-updates/universe |
> 
> (*) Unfortunately, I failed to find the way to make rpmbuild install and
>     enable EPEL repository prior to the build step. However, cmake3
>     requirement obligues user to enable EPEL by himself, otherwise this
>     dependency is left unmet. If there are any issues with building an
>     RPM on CentOS 7 please proceed to the docs:
>     https://www.tarantool.io/en/doc/latest/dev_guide/building_from_source/
> 
> So the last problem is Debian Jessie: the required CMake toolchain is
> provided neither via the default repository nor via the auxiliary one
> (e.g. updates like it's done for Ubuntu 14.04). Anyway, Debian Jessie
> long term support has reached its EOL[4], so we can freely drop this
> distribution from our regular building testing. This is done in the
> first patch of this series.
> 
> NB: Be careful with updating CMake to 3.1 in CMakeLists. The following
> patch breaks Tarantool build.
> | diff --git a/CMakeLists.txt b/CMakeLists.txt
> | index 4fbd19558..6dc78fa88 100644
> | --- a/CMakeLists.txt
> | +++ b/CMakeLists.txt
> | @@ -1,4 +1,4 @@
> | -cmake_minimum_required(VERSION 2.8)
> | +cmake_minimum_required(VERSION 3.1)
> |  
> |  project(tarantool C CXX)
> |  
> 
> Surprisingly, as a result of this change -Wno-gnu-alignof-expression
> flag is removed from CFLAGS and the build fails on OSX with the
> following error[5]:
> | /tarantool/src/box/field_map.c:69:36: error: '_Alignof' applied to an expression is a GNU extension [-Werror,-Wgnu-alignof-expression]
> |                 region_aligned_alloc(region, sz, alignof(*extent));
> |                                                  ^
> | /Library/Developer/CommandLineTools/usr/lib/clang/12.0.0/include/stdalign.h:15:17: note: expanded from macro 'alignof'
> | #define alignof _Alignof
> |                 ^
> | 1 error generated.
> 
> Anyway, I believe this is out of the scope of this series, so I just
> leave this for the further CMake upgrade endeavors.
> 
> Changes in v2:
>   * Adjust the series in accordance with recently merged PRs moving all
>     build jobs to GitHub CI[6], removing CentOS 6 CI pipeline[7] and
>     introducing Fedora 33 build job to CI[8].
>   * Moved some parts of cover letter to commit messages.
> 
> [1]: https://github.com/tarantool/tarantool/issues/4862
> [2]: https://cmake.org/cmake/help/latest/release/3.1.html#commands
> [3]: https://cmake.org/cmake/help/v3.1/manual/cmake-generator-expressions.7.html
> [4]: https://www.debian.org/News/2020/20200709
> [5]: https://gitlab.com/tarantool/tarantool/-/pipelines/243423841
> [6]: https://github.com/tarantool/tarantool/pull/5724
> [7]: https://github.com/tarantool/tarantool/pull/5729
> [8]: https://github.com/tarantool/tarantool/pull/5707
> 
> Branch: https://github.com/tarantool/tarantool/tree/imun/cmake3-toolchain
> V1: https://lists.tarantool.org/tarantool-patches/20210120184230.GC5460@tarantool.org/T/#t
> Issue: https://github.com/tarantool/tarantool/issues/4862
> CI is green but I can't share a single link to it after the changes in
> #5724, so please check whether there is a green tick everywhere for the
> top commit on the mentioned branch.

I've checked your patchset into 1.10, 2.6, 2.7 andd master.

--
Regards, Kirill Yukhin

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-01-27 13:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-25 19:14 [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Igor Munkin via Tarantool-patches
2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 1/2] github-ci: purge Debian Jessie from CI Igor Munkin via Tarantool-patches
2021-01-25 19:14 ` [Tarantool-patches] [PATCH v2 2/2] build: update CMake minimum version to 3.1 Igor Munkin via Tarantool-patches
2021-01-25 19:47 ` [Tarantool-patches] [PATCH v2 0/2] Update CMake minimum version in Tarantool Alexander V. Tikhonov via Tarantool-patches
2021-01-25 20:23   ` Igor Munkin via Tarantool-patches
2021-01-27 13:09 ` Kirill Yukhin via Tarantool-patches

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox