summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--docker/Dockerfile25
-rw-r--r--docker/checkout_commits.env1
2 files changed, 18 insertions, 8 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile
index b934a24..7a52ac4 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -16,12 +16,12 @@ RUN apt-get update && apt-get install -y \
     kmod \
     libcap-dev \
     libdbus-1-dev \
-    libdrm-dev \
     libegl1-mesa-dev \
     libfdt-dev \
     libgl1-mesa-dev \
     libgles1-mesa-dev \
     libgles2-mesa-dev \
+    libpciaccess-dev \
     libssl1.0-dev \
     libtool \
     libusb-1.0-0-dev \
@@ -65,6 +65,22 @@ RUN git clone https://android.googlesource.com/platform/external/minijail \
     && make -j$(nproc) \
     && cp libminijail.so /usr/lib/x86_64-linux-gnu/
 
+# New libepoxy and libdrm-dev requires newer meson than is in Debian stretch.
+ARG MESON_COMMIT=master
+RUN git clone https://github.com/mesonbuild/meson \
+    && cd meson \
+    && git checkout $MESON_COMMIT \
+    && ln -s $PWD/meson.py /usr/bin/meson
+
+# The libdrm-dev in distro can be too old to build minigbm,
+# so we build it from upstream.
+ARG DRM_COMMIT=master
+RUN git clone https://gitlab.freedesktop.org/mesa/drm \
+    && cd drm \
+    && git checkout $DRM_COMMIT \
+    && meson build \
+    && ninja -C build/ install
+
 # The gbm used by upstream linux distros is not compatible with crosvm, which must use Chrome OS's
 # minigbm.
 RUN dpkg --force-depends -r libgbm1
@@ -73,13 +89,6 @@ RUN git clone https://chromium.googlesource.com/chromiumos/platform/minigbm \
     && sed 's/-Wall/-Wno-maybe-uninitialized/g' -i Makefile \
     && make install -j$(nproc)
 
-# New libepoxy requires newer meson than is in Debian stretch.
-ARG MESON_COMMIT=master
-RUN git clone https://github.com/mesonbuild/meson \
-    && cd meson \
-    && git checkout $MESON_COMMIT \
-    && ln -s $PWD/meson.py /usr/bin/meson
-
 # New libepoxy has EGL_KHR_DEBUG entry points needed by crosvm.
 ARG LIBEPOXY_COMMIT=master
 RUN git clone https://github.com/anholt/libepoxy.git \
diff --git a/docker/checkout_commits.env b/docker/checkout_commits.env
index 6d77478..312b62a 100644
--- a/docker/checkout_commits.env
+++ b/docker/checkout_commits.env
@@ -3,3 +3,4 @@ LIBEPOXY_COMMIT=d536f78db81853b18ffc733af8a1474e9ca08950
 TPM2_COMMIT=1dba349a7b272071d613869adaaef7bd576ae0c2
 PLATFORM2_COMMIT=c08db1d4dc6d91230fe3820a736b7ebd2c6e901d
 ADHD_COMMIT=40a296cfff7b88f2c14701627cff4c233d94a975
+DRM_COMMIT=0c427545cd931490c760d51cc3c50be75615b26d