Skip to content
Rui Lopes edited this page Jan 17, 2019 · 5 revisions

This page has Dockerfiles for building libtpms in a Docker container. Please adapt them for your needs.

Ubuntu 18.04 (from Rui Lopes):

# usage:
# docker build -t build-libtpms-ubuntu-18.04 -f Dockerfile.ubuntu-18.04 .
# docker run --rm build-libtpms-ubuntu-18.04 | tar --extract --verbose
# docker rmi build-libtpms-ubuntu-18.04
# find build -name '*.deb' | xargs -L1 -i% bash -c 'echo %; dpkg -c %'
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get -y update && \
    apt-get -y install build-essential fakeroot devscripts equivs
ADD . /build/src
WORKDIR /build/src
RUN mk-build-deps \
    --install \
    --build-dep \
    '--tool=apt-get --no-install-recommends -y' \
    debian/control
RUN dpkg-buildpackage -b -us -uc -j$(nproc)
ENTRYPOINT tar --create --to-stdout /build/*.deb