Skip to content
Snippets Groups Projects
Commit 27dc41bc authored by Nicolas Werner's avatar Nicolas Werner
Browse files

Bump required c++ version to C++17

parent aa8bb856
No related branches found
No related tags found
No related merge requests found
......@@ -28,11 +28,14 @@
*.app
# Build artifacts
build/
build*/
# Editor
tags
compile_commands.json
.exrc
.ccls-cache/
.clangd/
# Synapse data
data/
......
......@@ -10,7 +10,7 @@ option(IWYU "Check headers with include-what-you-use" OFF)
option(BUILD_SHARED_LIBS "Specifies whether to build mtxclient as a shared library lib or not" ON)
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
......
FROM ubuntu:14.04
FROM ubuntu:16.04
ENV LIBSODIUM_VERSION=1.0.16
ENV SPDLOG_VERSION=1.1.0
......@@ -18,7 +18,7 @@ RUN \
# Toolchains
add-apt-repository -y ppa:ubuntu-toolchain-r/test && \
curl -L https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - && \
apt-add-repository "deb https://apt.llvm.org/trusty/ llvm-toolchain-trusty-6.0 main" && \
apt-add-repository "deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-6.0 main" && \
apt-get update -qq && \
apt-get install -y --no-install-recommends \
ninja-build \
......@@ -57,7 +57,7 @@ RUN \
curl -L https://dl.bintray.com/boostorg/release/1.70.0/source/boost_1_70_0.tar.gz -o boost_1_70_0.tar.gz && \
tar xfz boost_1_70_0.tar.gz && cd /build/boost/boost_1_70_0/ && \
./bootstrap.sh --with-libraries=random,thread,system,iostreams,atomic,chrono,date_time,regex && \
./b2 -d0 cxxstd=14 variant=release link=static threading=multi --layout=system && \
./b2 -d0 cxxstd=17 variant=release link=static threading=multi --layout=system && \
./b2 -d0 install && \
# Gtest
mkdir -p /build/gtest && cd /build/gtest && \
......
......@@ -13,7 +13,7 @@ Client API library for the Matrix protocol, built on top of Boost.Asio.
- Boost 1.70 (includes Boost.Beast and makes the strand interface usable)
- OpenSSL
- C++ 14 compiler
- C++ 17 compiler
- CMake 3.15 or greater (lower versions can work, but they tend to mess up linking the right boost libraries)
- Google Test (for testing)
- libsodium 1.0.14 or greater
......
......@@ -16,7 +16,7 @@ ExternalProject_Add(
CONFIGURE_COMMAND ${DEPS_BUILD_DIR}/boost/bootstrap.sh
--with-libraries=random,thread,system,iostreams,atomic,chrono,date_time,regex
--prefix=${DEPS_INSTALL_DIR}
BUILD_COMMAND ${DEPS_BUILD_DIR}/boost/b2 -d0 cxxstd=14 variant=release link=shared runtime-link=shared threading=multi --layout=system
BUILD_COMMAND ${DEPS_BUILD_DIR}/boost/b2 -d0 cxxstd=17 variant=release link=shared runtime-link=shared threading=multi --layout=system
INSTALL_COMMAND ${DEPS_BUILD_DIR}/boost/b2 -d0 install
)
......
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