custom doker image for conan-mingw

This commit is contained in:
lukas 2021-03-15 20:03:26 +01:00
parent 9d91779f15
commit 5f65ca528f
4 changed files with 61 additions and 3 deletions

View File

@ -1,4 +1,4 @@
include: '/Docker/Linux_Conan/.gitlab-ci.yml'
include: '/Docker/Windows_Conan/.gitlab-ci.yml'
image: conanio/gcc10
@ -31,8 +31,6 @@ conan_windows:
stage: build
image: luki42/dynuiprefresher_build:conanbuild
before_script:
- conan profile new default --detect --force # Generates default profile detecting GCC and sets old ABI
- conan profile update settings.compiler.libcxx=libstdc++11 default # Sets libcxx to C++11 ABI
- mkdir -p build # create build folder
- CONAN_SYSREQUIRES_MODE=enabled CONAN_SYSREQUIRES_SUDO=0 conan install . --build=missing -g cmake -if build --profile ../mingw64.profile
script:

View File

@ -0,0 +1,23 @@
# trigger docker rebuild if changes where made
docker_linux:
stage: docker
image: docker:latest
tags:
- dind
services:
- name: docker:dind
entrypoint: ["env", "-u", "DOCKER_HOST"]
command: ["dockerd-entrypoint.sh"]
variables:
DOCKER_HOST: tcp://docker:2375/
DOCKER_DRIVER: overlay2
# See https://github.com/docker-library/docker/pull/166
DOCKER_TLS_CERTDIR: ""
script:
- docker build -t luki42/dynuiprefresher_build:conanbuild Docker/Linux_Conan
- docker login -p $DockerPWD -u luki42
- docker push luki42/dynuiprefresher_build:conanbuild
only:
changes:
- Docker/Linux_Conan/*

View File

@ -0,0 +1,10 @@
FROM fedora:33
MAINTAINER luki42
COPY ./build.sh /tmp/
RUN bash /tmp/build.sh
# Expose /home as workin dir
WORKDIR /home
VOLUME ["/home"]

View File

@ -0,0 +1,27 @@
#!/bin/bash
# Install texlive
echo "instaling cmake" && \
dnf install -y mingw64-gcc-c++ wget cmake make tar xz mingw32-nsis gtest gtest-devel python3 python3-pip
#cleanup
dnf clean dbcache && dnf clean packages
# install conan
pip3 install conan
git clone https://gitlab.heili.eu/lukas/dynuiprefresher.git
cd dynuiprefresher || exit
git checkout conansupport
conan profile new default --detect --force # Generates default profile detecting GCC and sets old ABI
conan profile update settings.compiler.libcxx=libstdc++11 default # Sets libcxx to C++11 ABI
mkdir -p build # create build folder
CONAN_SYSREQUIRES_MODE=enabled CONAN_SYSREQUIRES_SUDO=0 conan install . --build=missing
# cleanup
conan remove "*" -s -b -f
cd ..
rm -Rf ./dynuiprefresher
rm /tmp/build.sh