Skip to content

Commit d251857

Browse files
committed
Build mesa and its deps
1 parent f6a8cbf commit d251857

File tree

12 files changed

+147
-3
lines changed

12 files changed

+147
-3
lines changed

buildconfig/manylinux-build/docker_base/Dockerfile-aarch64

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ RUN rpm --import /tmp/RPM-GPG-KEY.dag.txt
1111

1212
#RUN rpm -i /tmp/${RPMFORGE_FILE}
1313

14+
# systemd is needed for udev (for SDL and pulse)
1415
# it's okay to install X11 and friends from outdated centos repos because newer
1516
# libs are dynamically loaded at runtime
1617
RUN yum install -y zlib-devel dbus-devel fontconfig xz systemd-devel \
17-
mesa-libGLU-devel libcap-devel libxkbcommon-devel \
18+
libcap-devel libxkbcommon-devel \
1819
libX11-devel libXext-devel libXrandr-devel libXcursor-devel libXfixes-devel \
1920
libXi-devel libXScrnSaver-devel
2021

@@ -62,6 +63,21 @@ RUN ["bash", "/xorg_build/libpciaccess/build-libpciaccess.sh"]
6263
ADD mesa/libdrm /mesa_build/libdrm/
6364
RUN ["bash", "/mesa_build/libdrm/build-libdrm.sh"]
6465

66+
ADD xorg/libxshmfence /xorg_build/libxshmfence/
67+
RUN ["bash", "/xorg_build/libxshmfence/build-libxshmfence.sh"]
68+
69+
ADD mesa/glslang /mesa_build/glslang/
70+
RUN ["bash", "/mesa_build/glslang/build-glslang.sh"]
71+
72+
ADD mesa/mako /mesa_build/mako/
73+
RUN ["bash", "/mesa_build/mako/build-mako.sh"]
74+
75+
ADD mesa/flex /mesa_build/flex/
76+
RUN ["bash", "/mesa_build/flex/build-flex.sh"]
77+
78+
ADD mesa/mesa /mesa_build/mesa/
79+
RUN ["bash", "/mesa_build/mesa/build-mesa.sh"]
80+
6581
#ADD zlib-ng /zlib-ng_build/
6682
#RUN ["bash", "/zlib-ng_build/build-zlib-ng.sh"]
6783

buildconfig/manylinux-build/docker_base/Dockerfile-i686

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ RUN rpm --import /tmp/RPM-GPG-KEY.dag.txt
1111

1212
#RUN rpm -i /tmp/${RPMFORGE_FILE}
1313

14+
# systemd is needed for udev (for SDL and pulse)
1415
# it's okay to install X11 and friends from outdated centos repos because newer
1516
# libs are dynamically loaded at runtime
1617
RUN linux32 yum install -y zlib-devel dbus-devel fontconfig xz systemd-devel \
17-
mesa-libGLU-devel libcap-devel libxkbcommon-devel \
18+
libcap-devel libxkbcommon-devel \
1819
libX11-devel libXext-devel libXrandr-devel libXcursor-devel libXfixes-devel \
1920
libXi-devel libXScrnSaver-devel
2021

@@ -62,6 +63,21 @@ RUN ["linux32", "bash", "/xorg_build/libpciaccess/build-libpciaccess.sh"]
6263
ADD mesa/libdrm /mesa_build/libdrm/
6364
RUN ["linux32", "bash", "/mesa_build/libdrm/build-libdrm.sh"]
6465

66+
ADD xorg/libxshmfence /xorg_build/libxshmfence/
67+
RUN ["linux32", "bash", "/xorg_build/libxshmfence/build-libxshmfence.sh"]
68+
69+
ADD mesa/glslang /mesa_build/glslang/
70+
RUN ["linux32", "bash", "/mesa_build/glslang/build-glslang.sh"]
71+
72+
ADD mesa/mako /mesa_build/mako/
73+
RUN ["linux32", "bash", "/mesa_build/mako/build-mako.sh"]
74+
75+
ADD mesa/flex /mesa_build/flex/
76+
RUN ["linux32", "bash", "/mesa_build/flex/build-flex.sh"]
77+
78+
ADD mesa/mesa /mesa_build/mesa/
79+
RUN ["linux32", "bash", "/mesa_build/mesa/build-mesa.sh"]
80+
6581
#ADD zlib-ng /zlib-ng_build/
6682
#RUN ["linux32", "bash", "/zlib-ng_build/build-zlib-ng.sh"]
6783

buildconfig/manylinux-build/docker_base/Dockerfile-x86_64

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ RUN rpm --import /tmp/RPM-GPG-KEY.dag.txt
1111

1212
#RUN rpm -i /tmp/${RPMFORGE_FILE}
1313

14+
# systemd is needed for udev (for SDL and pulse)
1415
# it's okay to install X11 and friends from outdated centos repos because newer
1516
# libs are dynamically loaded at runtime
1617
RUN yum install -y zlib-devel dbus-devel fontconfig xz systemd-devel \
17-
mesa-libGLU-devel libcap-devel libxkbcommon-devel \
18+
libcap-devel libxkbcommon-devel \
1819
libX11-devel libXext-devel libXrandr-devel libXcursor-devel libXfixes-devel \
1920
libXi-devel libXScrnSaver-devel
2021

@@ -62,6 +63,21 @@ RUN ["bash", "/xorg_build/libpciaccess/build-libpciaccess.sh"]
6263
ADD mesa/libdrm /mesa_build/libdrm/
6364
RUN ["bash", "/mesa_build/libdrm/build-libdrm.sh"]
6465

66+
ADD xorg/libxshmfence /xorg_build/libxshmfence/
67+
RUN ["bash", "/xorg_build/libxshmfence/build-libxshmfence.sh"]
68+
69+
ADD mesa/glslang /mesa_build/glslang/
70+
RUN ["bash", "/mesa_build/glslang/build-glslang.sh"]
71+
72+
ADD mesa/mako /mesa_build/mako/
73+
RUN ["bash", "/mesa_build/mako/build-mako.sh"]
74+
75+
ADD mesa/flex /mesa_build/flex/
76+
RUN ["bash", "/mesa_build/flex/build-flex.sh"]
77+
78+
ADD mesa/mesa /mesa_build/mesa/
79+
RUN ["bash", "/mesa_build/mesa/build-mesa.sh"]
80+
6581
#ADD zlib-ng /zlib-ng_build/
6682
#RUN ["bash", "/zlib-ng_build/build-zlib-ng.sh"]
6783

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/bin/bash
2+
set -e -x
3+
4+
cd $(dirname `readlink -f "$0"`)
5+
6+
FLEX_VER="2.6.4"
7+
FLEX="flex-$FLEX_VER"
8+
9+
curl -sL --retry 10 https://github.com/westes/flex/releases/download/v$FLEX_VER/$FLEX.tar.gz > $FLEX.tar.gz
10+
sha512sum -c flex.sha512sum
11+
12+
tar xzf $FLEX.tar.gz
13+
cd $FLEX
14+
15+
./configure $PG_BASE_CONFIGURE_FLAGS
16+
make
17+
make install
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
e9785f3d620a204b7d20222888917dc065c2036cae28667065bf7862dfa1b25235095a12fd04efdbd09bfd17d3452e6b9ef953a8c1137862ff671c97132a082e flex-2.6.4.tar.gz
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#!/bin/bash
2+
set -e -x
3+
4+
cd $(dirname `readlink -f "$0"`)
5+
6+
GLSLANG_VER=14.0.0
7+
GLSLANG="glslang-$GLSLANG_VER"
8+
curl -sL --retry 10 https://github.com/KhronosGroup/glslang/archive/refs/tags/${GLSLANG_VER}.tar.gz > ${GLSLANG}.tar.gz
9+
10+
sha512sum -c glslang.sha512sum
11+
tar xzf ${GLSLANG}.tar.gz
12+
cd $GLSLANG
13+
14+
mkdir build
15+
cd build
16+
17+
cmake .. $PG_BASE_CMAKE_FLAGS -DENABLE_OPT=0 -DGLSLANG_TESTS=0
18+
make
19+
make install
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
45ec1a23a390319b9270761cf8befb832ac8b4bc215b211c41a543553a97e5ccf17c134c34d8fdbed6efe887a9a7c2f0a955d1bfe1add9e04cc3e95b12e1973a glslang-14.0.0.tar.gz
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/bash
2+
set -e -x
3+
4+
cd $(dirname `readlink -f "$0"`)
5+
6+
# pin for build stability, remember to keep updated
7+
python3 -m pip install mako==1.3.2
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
#!/bin/bash
2+
set -e -x
3+
4+
cd $(dirname `readlink -f "$0"`)
5+
6+
# We need mesa for opengl, gbm (SDL kmsdrm driver needs it), egl (SDL
7+
# wayland driver needs this) and glx (SDL needs it)
8+
# we don't support vulkan yet
9+
10+
MESA_VER="mesa-24.0.1"
11+
MESA="mesa-$MESA_VER" # yes mesa comes twice in the name
12+
13+
curl -sL --retry 10 https://gitlab.freedesktop.org/mesa/mesa/-/archive/$MESA_VER/$MESA.tar.gz > $MESA.tar.gz
14+
sha512sum -c mesa.sha512sum
15+
16+
tar xzf $MESA.tar.gz
17+
cd $MESA
18+
19+
# For now, we don't compile in LLVM because of its weight. Because of this, we
20+
# can't compile in support for the radeonsi driver
21+
if [ `uname -m` == "aarch64" ]; then
22+
# On aarch64 we allow mesa to use all drivers it wants to pick by default
23+
# (because radeonsi is not used on arm platforms)
24+
GALLIUM_DRIVERS="auto"
25+
else
26+
# all default except radeonsi
27+
GALLIUM_DRIVERS="r300,r600,nouveau,virgl,svga,swrast,iris,crocus,i915"
28+
fi
29+
30+
# build with meson+ninja
31+
meson build/ $PG_BASE_MESON_FLAGS -Dgallium-drivers=$GALLIUM_DRIVERS -Dvulkan-drivers=[]
32+
ninja -C build/ install
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
66a6cea1712f3b20744c0865c10523313653be39fc5a75e8201dbf50188cad819bd52a6013d1bd7be3d622de948b750ceb41dc73649cdea2abbaa6bb016cc4a7 mesa-mesa-24.0.1.tar.gz

0 commit comments

Comments
 (0)