Commit 5a619123 authored by Anatolii Koval's avatar Anatolii Koval
Browse files

Docker. GCC 8.2.0. C++17

[Description]
- Docker infrastructure for the project;
- Compilation script;
- Build project against C++17 standart;
parent 19899287
......@@ -7,7 +7,7 @@ cmake_minimum_required(VERSION 2.6)
project(ElementaryUtils CXX)
# define c++ standard and issue all the warning demanded by this standard
add_definitions(-std=c++98 -pedantic)
add_definitions(-std=c++17 -pedantic)
# VERSION ==================================================================================
......@@ -28,7 +28,7 @@ configure_file(${CMAKE_SOURCE_DIR}/cmake/Version/ElementaryUtilsVersion.h_in ${C
# tell cmake to run Qt moc when necessary
set(CMAKE_AUTOMOC ON)
# as moc files are generated in the binary dir, tell cmake to always look for includes there
set(CMAKE_INCLUDE_CURRENT_DIR ON)
......@@ -40,7 +40,7 @@ set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
# find libraries: SFML
find_package(SFML COMPONENTS system REQUIRED)
# directories containing headers
# directories containing headers
include_directories(${SFML_INCLUDE_DIR})
include_directories(include)
......@@ -77,8 +77,8 @@ target_link_libraries(
)
# install
install(TARGETS ElementaryUtils
RUNTIME DESTINATION bin/PARTONS
install(TARGETS ElementaryUtils
RUNTIME DESTINATION bin/PARTONS
LIBRARY DESTINATION lib/PARTONS
ARCHIVE DESTINATION lib/static/PARTONS)
install(DIRECTORY include/ DESTINATION include/PARTONS)
FROM gcc:8.2.0
ENV WORKSPACE="/root/workspace/"
WORKDIR ${WORKSPACE}
RUN apt-get update && \
apt-get install -y libeigen3-dev libcln-dev libsfml-dev libqt4-dev libqt4-sql-mysql cmake git
#!/bin/bash
docker-compose run --rm elementary-utils /bin/bash "${@}"
version: '2'
services:
elementary-utils:
build: .
restart: 'no'
volumes:
- "./:/root/workspace/elementary-utils"
command: /bin/bash
#!/bin/bash
docker-compose run --rm elementary-utils /bin/bash -c "cd /root/workspace/elementary-utils/build && cmake -G'Unix Makefiles' ../ -DCMAKE_BUILD_TYPE=Debug && make"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment