-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
104 lines (97 loc) · 2.36 KB
/
Dockerfile
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
FROM ubuntu:20.04
ARG DEBIAN_FRONTEND=noninteractive
ENV TZ=Europe/London
RUN apt update && \
apt upgrade -y
RUN apt update && \
apt install -y \
sudo \
git \
curl \
nano \
wget \
build-essential \
brightnessctl \
autotools-dev \
automake \
libtool \
libtool-bin \
libevdev-dev \
libdrm-dev \
python3 \
python3-pip \
python3-setuptools \
python3-wheel \
ninja-build \
libopenal-dev \
premake4 \
autoconf \
ffmpeg \
libsnappy-dev \
libboost-tools-dev \
magics++ \
libboost-thread-dev \
libboost-all-dev \
pkg-config \
zlib1g-dev \
libpng-dev \
libsdl2-dev \
libsdl1.2-dev \
clang \
cmake \
cmake-data \
libarchive13 \
libcurl4 \
libfreetype6-dev \
libjsoncpp-dev \
librhash0 \
libuv1 \
mercurial \
mercurial-common \
libgbm-dev \
libsdl2-ttf-dev \
libsdl2-image-dev \
libsdl2-mixer-dev \
libsdl-image1.2-dev \
libsdl-mixer1.2-dev \
libsdl-gfx1.2-dev
RUN apt update
RUN ln -s /usr/include/libdrm/ /usr/include/drm
# Install meson
RUN pip3 install meson
WORKDIR /root
RUN git clone https://github.com/mesonbuild/meson.git && \
cd meson && \
ln -s /meson/meson.py /usr/bin/meson
# Install libsdl1.2
WORKDIR /root
RUN git clone https://github.com/libsdl-org/sdl12-compat.git && \
cd sdl12-compat && \
mkdir build && cd build && \
cmake .. && \
make
# Install gl4es
WORKDIR /root
RUN git clone https://github.com/ptitSeb/gl4es.git && \
cd gl4es && \
mkdir build && cd build && \
cmake .. -DNOX11=ON -DGLX_STUBS=ON -DEGL_WRAPPER=ON -DGBM=ON && \
make
# Install more compatible SDL2
ARG TARGETPLATFORM
WORKDIR /root
RUN case ${TARGETPLATFORM} in \
"linux/amd64") ARCHITECTURE=/usr/lib/x86_64-linux-gnu ;; \
"linux/arm64") ARCHITECTURE=/usr/lib/aarch64-linux-gnu ;; \
"linux/arm/v7") ARCHITECTURE=/usr/lib/arm-linux-gnueabihf ;; \
"linux/386") ARCHITEXTURE=/usr/include ;; \
esac \
&& rm $ARCHITECTURE/libSDL2.* \
&& rm -rf $ARCHITECTURE/libSDL2-2.0.so* \
&& wget https://github.com/libsdl-org/SDL/archive/refs/tags/release-2.26.2.tar.gz \
&& tar -xzf release-2.26.2.tar.gz \
&& cd SDL-release-2.26.2 \
&& ./configure --prefix=/usr \
&& make -j8 \
&& make install \
&& /sbin/ldconfig