-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
109 lines (100 loc) · 3.54 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
image: fedora:latest
cache:
key: dnf-cache
paths:
- dnf-cache/
variables:
EXTRA_REPO_INST_COMMAND: /bin/true
EXTRA_REPO_CONFIGURE_COMMAND: /bin/true
DEPENDENCY_PACKAGES: "pkgconfig(openal) pkgconfig(sdl2) pkgconfig(glu) pkgconfig(libpng) pkgconfig(libjpeg) pkgconfig(vorbis) pkgconfig(vorbisfile) pkgconfig(ogg) pkgconfig(jsoncpp)"
COMMON_PACKAGES: "$COMPILER_PACKAGES cmake make $DEPENDENCY_PACKAGES"
before_script:
- $EXTRA_REPO_INST_COMMAND
- $EXTRA_REPO_CONFIGURE_COMMAND
- dnf --setopt=cachedir=`pwd`/dnf-cache -q -y install $COMMON_PACKAGES
build_oldgcc:
image: almalinux:8
cache:
key: dnf-cache
paths:
- dnf-cache/
variables:
EXTRA_REPO_INST_COMMAND: "dnf --setopt=cachedir=`pwd`/dnf-cache -q -y install epel-release yum-utils"
EXTRA_REPO_CONFIGURE_COMMAND: "dnf config-manager --set-enabled powertools"
COMPILER_PACKAGES: "gcc gcc-c++"
stage: build
script:
- export CC=gcc; export CXX=g++
- mkdir -p x86_64-linux-gnu-oldgcc oldgcc-build; cd x86_64-linux-gnu-oldgcc
- cmake .. -DCMAKE_INSTALL_PREFIX=/builds/${CI_PROJECT_PATH}/oldgcc-build
- make -j4; make install
artifacts:
expire_in: 14d
paths:
- ./oldgcc-build
tags:
- shared
build_gcc:
stage: build
variables:
COMPILER_PACKAGES: "gcc gcc-c++"
script:
- export CC=gcc; export CXX=g++
- mkdir -p x86_64-linux-gnu-gcc gcc-build; cd x86_64-linux-gnu-gcc
- cmake .. -DCMAKE_INSTALL_PREFIX=/builds/${CI_PROJECT_PATH}/gcc-build
- make -j4; make install
artifacts:
expire_in: 14d
paths:
- ./gcc-build
tags:
- shared
build_clang:
stage: build
variables:
COMPILER_PACKAGES: "clang"
script:
- export CC=clang; export CXX=clang++
- mkdir -p x86_64-linux-gnu-clang clang-build; cd x86_64-linux-gnu-clang
- cmake .. -DCMAKE_INSTALL_PREFIX=/builds/${CI_PROJECT_PATH}/clang-build
- make -j4; make install
artifacts:
expire_in: 14d
paths:
- ./clang-build
tags:
- shared
build_mingw32:
stage: build
variables:
COMPILER_PACKAGES: "mingw32-gcc mingw32-gcc-c++ mingw32-binutils mingw32-headers"
DEPENDENCY_PACKAGES: "mingw32-libjpeg-turbo mingw32-libpng mingw32-SDL2 mingw32-libvorbis mingw32-libogg mingw32-openal-soft mingw32-jsoncpp"
script:
- export PKG_CONFIG_LIBDIR="/usr/i686-w64-mingw32/sys-root/mingw/lib/pkgconfig:/usr/i686-w64-mingw32/sys-root/mingw/share/pkgconfig"
- export PATH=/usr/i686-w64-mingw32/bin:$PATH
- mkdir -p i686-w64-mingw32 mingw32-build; cd i686-w64-mingw32
- cmake .. -DCMAKE_TOOLCHAIN_FILE=/usr/share/mingw/toolchain-mingw32.cmake -DCMAKE_INSTALL_PREFIX=/builds/${CI_PROJECT_PATH}/mingw32-build
- make -j4; make install
artifacts:
expire_in: 14d
paths:
- ./mingw32-build
tags:
- shared
build_mingw64:
stage: build
variables:
COMPILER_PACKAGES: "mingw64-gcc mingw64-gcc-c++ mingw64-binutils mingw64-headers"
DEPENDENCY_PACKAGES: "mingw64-libjpeg-turbo mingw64-libpng mingw64-SDL2 mingw64-libvorbis mingw64-libogg mingw64-openal-soft mingw64-jsoncpp"
script:
- export PKG_CONFIG_LIBDIR="/usr/x86_64-w64-mingw32/sys-root/mingw/lib/pkgconfig:/usr/x86_64-w64-mingw32/sys-root/mingw/share/pkgconfig"
- export PATH=/usr/x86_64-w64-mingw32/bin:$PATH
- mkdir -p x86_64-w64-mingw32 mingw64-build; cd x86_64-w64-mingw32
- cmake .. -DCMAKE_TOOLCHAIN_FILE=/usr/share/mingw/toolchain-mingw64.cmake -DCMAKE_INSTALL_PREFIX=/builds/${CI_PROJECT_PATH}/mingw64-build
- make -j4; make install
artifacts:
expire_in: 14d
paths:
- ./mingw64-build
tags:
- shared