36 lines
1.1 KiB
Docker
36 lines
1.1 KiB
Docker
FROM ubuntu:latest as base
|
|
|
|
ENV TZ=US/Eastern
|
|
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
|
|
RUN apt-get update
|
|
RUN apt-get install -y build-essential curl git
|
|
|
|
FROM base as builder
|
|
|
|
# otfcc depends on premake5
|
|
WORKDIR /tmp
|
|
ENV PREMAKE_VERSION 5.0.0-alpha15
|
|
RUN curl -sL https://github.com/premake/premake-core/releases/download/v${PREMAKE_VERSION}/premake-${PREMAKE_VERSION}-linux.tar.gz | tar -xzC /tmp
|
|
RUN mv /tmp/premake5 /usr/local/bin/premake5
|
|
|
|
# otfcc
|
|
WORKDIR /tmp
|
|
ENV OTFCC_VERSION=0.10.4
|
|
RUN curl -sL https://github.com/caryll/otfcc/archive/v${OTFCC_VERSION}.tar.gz | tar -xzC /tmp
|
|
RUN mv otfcc-${OTFCC_VERSION} otfcc
|
|
WORKDIR /tmp/otfcc
|
|
RUN premake5 gmake && cd build/gmake && make config=release_x64
|
|
|
|
FROM base
|
|
COPY --from=builder /tmp/otfcc/bin/release-x64/otfccbuild /usr/local/bin/otfccbuild
|
|
COPY --from=builder /tmp/otfcc/bin/release-x64/otfccdump /usr/local/bin/otfccdump
|
|
|
|
# NodeJS >= 12.16.0
|
|
RUN curl -sL https://deb.nodesource.com/setup_14.x | bash -
|
|
RUN apt-get install -y nodejs ttfautohint magic-wormhole zstd
|
|
|
|
WORKDIR /
|
|
ADD ./private-build-plans.toml /
|
|
ADD build.sh /
|
|
|
|
CMD ["/build.sh"]
|