genymobile-scrcpy
SUCCESS
17m 41s
History Source
SummaryIterations1Transcript9Dockerfile
Dockerfile40 lines · 1108 chars
FROM ubuntu:22.04

# Build scrcpy from source using Meson on Ubuntu 22.04
# This image installs build tools and dependencies, builds the app from source
# (without building the scrcpy-server), and places the binaries under /usr/local.

ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update \
    && apt-get install -y --no-install-recommends \
        ca-certificates \
        build-essential \
        meson \
        ninja-build \
        nasm \
        ffmpeg \
        libsdl2-2.0-0 \
        libsdl2-dev \
        libavcodec-dev \
        libavformat-dev \
        libavutil-dev \
        libswresample-dev \
        libavdevice-dev \
        libusb-1.0-0-dev \
        libv4l-dev \
        pkg-config \
        && rm -rf /var/lib/apt/lists/*

# Create working directory and copy sources
WORKDIR /src
COPY . /src

# Configure, build and install (only app, skip server)
RUN meson setup build -Dbuildtype=release -Dcompile_app=true -Dcompile_server=false -Dprefix=/usr/local
RUN meson compile -C build
RUN meson install -C build

# Set the entry point to the scrcpy binary
CMD ["/usr/local/bin/scrcpy"]